Section 1
//Data (code.data.Data)
package code.data {
public class Data {
public static const moneyLevels:Array = [{money:10000, grade:"F"}, {money:20000, grade:"E"}, {money:35000, grade:"D"}, {money:50000, grade:"C"}, {money:70000, grade:"B"}, {money:85000, grade:"A"}, {money:110000, grade:"S"}, {money:140000, grade:"SS"}, {money:999999, grade:"SSS"}];
public static const xmlData:XML = <waves>
<wave>
<!--第1波羊,时间(秒),出现白羊概率(百分比,1为一定出现白羊,0为一定不出现白羊)/-->
<sheep time="1" prob="1"/>
<sheep time="4" prob="1"/>
<sheep time="5" prob="1"/>
<sheep time="5.5" prob="1"/>
<sheep time="7" prob="1"/>
<sheep time="8" prob="1"/>
<sheep time="8.5" prob="1"/>
<sheep time="9.2" prob="1"/>
<sheep time="13" prob="1"/>
<sheep time="16" prob="1"/>
</wave>
<wave>
<!--第2波羊,时间(秒),出现白羊概率(百分比,1为一定出现白羊,0为一定不出现白羊)/-->
<sheep time="1" prob="1"/>
<sheep time="3" prob="1"/>
<sheep time="5" prob="1"/>
<sheep time="5.5" prob="0.5"/>
<sheep time="6" prob="0.5"/>
<sheep time="8" prob="1"/>
<sheep time="9" prob="1"/>
<sheep time="11" prob="1"/>
<sheep time="12" prob="1"/>
<sheep time="13" prob="1"/>
<sheep time="13.5" prob="1"/>
<sheep time="16" prob="1"/>
<sheep time="18" prob="1"/>
<sheep time="20" prob="1"/>
<sheep time="23" prob="1"/>
</wave>
<wave>
<!--第3波羊,时间(秒),出现白羊概率(百分比,1为一定出现白羊,0为一定不出现白羊)/-->
<sheep time="1" prob="1"/>
<sheep time="3" prob="1"/>
<sheep time="6" prob="1"/>
<sheep time="6.5" prob="1"/>
<sheep time="7" prob="1"/>
<sheep time="9" prob="0.5"/>
<sheep time="10" prob="0.5"/>
<sheep time="11" prob="1"/>
<sheep time="12.5" prob="1"/>
<sheep time="13" prob="1"/>
<sheep time="14" prob="1"/>
<sheep time="14.5" prob="1"/>
<sheep time="16" prob="1"/>
<sheep time="17" prob="1"/>
<sheep time="18" prob="1"/>
<sheep time="21" prob="1"/>
<sheep time="22.5" prob="1"/>
<sheep time="25" prob="1"/>
<sheep time="27" prob="1"/>
<sheep time="28" prob="1"/>
</wave>
<wave>
<!--第4波羊,时间(秒),出现白羊概率(百分比,1为一定出现白羊,0为一定不出现白羊)/-->
<sheep time="1" prob="1"/>
<sheep time="2" prob="1"/>
<sheep time="4" prob="1"/>
<sheep time="5.5" prob="1"/>
<sheep time="7" prob="1"/>
<sheep time="8" prob="0.5"/>
<sheep time="8.5" prob="1"/>
<sheep time="9" prob="1"/>
<sheep time="10" prob="0"/>
<sheep time="11" prob="1"/>
<sheep time="11.5" prob="1"/>
<sheep time="13" prob="1"/>
<sheep time="15" prob="1"/>
<sheep time="17" prob="1"/>
<sheep time="18" prob="1"/>
<sheep time="19" prob="1"/>
<sheep time="21" prob="1"/>
<sheep time="23" prob="1"/>
<sheep time="23.5" prob="1"/>
<sheep time="24" prob="1"/>
<sheep time="26" prob="1"/>
<sheep time="26.5" prob="0"/>
<sheep time="27" prob="1"/>
<sheep time="29" prob="1"/>
<sheep time="30" prob="1"/>
<sheep time="30.5" prob="1"/>
<sheep time="32" prob="1"/>
<sheep time="33" prob="0"/>
<sheep time="33.5" prob="1"/>
<sheep time="34" prob="1"/>
<sheep time="34.5" prob="1"/>
</wave>
<wave>
<!--第5波羊,时间(秒),出现白羊概率(百分比,1为一定出现白羊,0为一定不出现白羊)/-->
<sheep time="1" prob="1"/>
<sheep time="2" prob="1"/>
<sheep time="4" prob="0.5"/>
<sheep time="5.5" prob="1"/>
<sheep time="7" prob="1"/>
<sheep time="8" prob="0.5"/>
<sheep time="8.5" prob="1"/>
<sheep time="9" prob="1"/>
<sheep time="10" prob="0"/>
<sheep time="10.3" prob="1"/>
<sheep time="10.8" prob="1"/>
<sheep time="11" prob="0"/>
<sheep time="12.5" prob="1"/>
<sheep time="13" prob="1"/>
<sheep time="14" prob="1"/>
<sheep time="15" prob="1"/>
<sheep time="15.3" prob="1"/>
<sheep time="15.8" prob="1"/>
<sheep time="16.5" prob="1"/>
<sheep time="19" prob="1"/>
<sheep time="20" prob="1"/>
<sheep time="21" prob="0"/>
<sheep time="23" prob="1"/>
<sheep time="25" prob="1"/>
<sheep time="25.5" prob="1"/>
<sheep time="26" prob="1"/>
<sheep time="28" prob="1"/>
<sheep time="29" prob="0"/>
<sheep time="32" prob="1"/>
<sheep time="33" prob="1"/>
<sheep time="34" prob="1"/>
</wave>
<wave>
<!--第6波羊,时间(秒),出现白羊概率(百分比,1为一定出现白羊,0为一定不出现白羊)/-->
<sheep time="1" prob="1"/>
<sheep time="2" prob="1"/>
<sheep time="4" prob="0.5"/>
<sheep time="5.5" prob="1"/>
<sheep time="7" prob="1"/>
<sheep time="8" prob="0.5"/>
<sheep time="8.5" prob="1"/>
<sheep time="9" prob="1"/>
<sheep time="10" prob="0"/>
<sheep time="10.3" prob="1"/>
<sheep time="10.8" prob="1"/>
<sheep time="11" prob="0"/>
<sheep time="12.5" prob="1"/>
<sheep time="13" prob="1"/>
<sheep time="14" prob="1"/>
<sheep time="15" prob="1"/>
<sheep time="15.3" prob="1"/>
<sheep time="15.8" prob="1"/>
<sheep time="16.5" prob="1"/>
<sheep time="19" prob="1"/>
<sheep time="20" prob="1"/>
<sheep time="21" prob="0"/>
<sheep time="23" prob="1"/>
<sheep time="25" prob="1"/>
<sheep time="25.5" prob="1"/>
<sheep time="26" prob="1"/>
<sheep time="28" prob="1"/>
<sheep time="29" prob="0"/>
<sheep time="32" prob="1"/>
<sheep time="33" prob="1"/>
<sheep time="34" prob="1"/>
<sheep time="29" prob="0"/>
<sheep time="32" prob="1"/>
<sheep time="33" prob="1"/>
<sheep time="34" prob="1"/>
<sheep time="34" prob="1"/>
<sheep time="37" prob="0.5"/>
<sheep time="38" prob="1"/>
<sheep time="38.5" prob="1"/>
<sheep time="40" prob="1"/>
</wave>
<wave>
<!--第7波羊,时间(秒),出现白羊概率(百分比,1为一定出现白羊,0为一定不出现白羊)/-->
<sheep time="0.5" prob="1"/>
<sheep time="0.8" prob="1"/>
<sheep time="2" prob="0.5"/>
<sheep time="2.5" prob="1"/>
<sheep time="3" prob="1"/>
<sheep time="4" prob="0.5"/>
<sheep time="4.5" prob="1"/>
<sheep time="5" prob="1"/>
<sheep time="8" prob="0"/>
<sheep time="9" prob="1"/>
<sheep time="10.8" prob="1"/>
<sheep time="11" prob="0"/>
<sheep time="12.5" prob="1"/>
<sheep time="13" prob="1"/>
<sheep time="14" prob="1"/>
<sheep time="15" prob="1"/>
<sheep time="17" prob="1"/>
<sheep time="18" prob="1"/>
<sheep time="19" prob="1"/>
<sheep time="19.5" prob="1"/>
<sheep time="20" prob="1"/>
<sheep time="21" prob="0"/>
<sheep time="23" prob="1"/>
<sheep time="25" prob="1"/>
<sheep time="26" prob="1"/>
<sheep time="26" prob="1"/>
<sheep time="28" prob="1"/>
<sheep time="29" prob="0"/>
<sheep time="32" prob="1"/>
<sheep time="33" prob="1"/>
<sheep time="34" prob="1"/>
<sheep time="34.3" prob="0"/>
<sheep time="35" prob="1"/>
<sheep time="36" prob="1"/>
<sheep time="37.5" prob="1"/>
<sheep time="38" prob="1"/>
<sheep time="38.3" prob="0.5"/>
<sheep time="40" prob="1"/>
<sheep time="42" prob="1"/>
<sheep time="44" prob="1"/>
</wave>
<wave>
<!--第8波羊,时间(秒),出现白羊概率(百分比,1为一定出现白羊,0为一定不出现白羊)/-->
<sheep time="0.3" prob="1"/>
<sheep time="0.8" prob="1"/>
<sheep time="1.5" prob="0.5"/>
<sheep time="2" prob="1"/>
<sheep time="2.5" prob="1"/>
<sheep time="3" prob="0"/>
<sheep time="3.5" prob="1"/>
<sheep time="4" prob="1"/>
<sheep time="4.5" prob="1"/>
<sheep time="5" prob="0"/>
<sheep time="5.5" prob="1"/>
<sheep time="8" prob="0"/>
<sheep time="8.5" prob="0.5"/>
<sheep time="9" prob="1"/>
<sheep time="9.5" prob="1"/>
<sheep time="10" prob="1"/>
<sheep time="11" prob="1"/>
<sheep time="13" prob="0"/>
<sheep time="15" prob="1"/>
<sheep time="15.5" prob="0"/>
<sheep time="16" prob="1"/>
<sheep time="17.5" prob="0"/>
<sheep time="18" prob="0"/>
<sheep time="19" prob="0"/>
<sheep time="20" prob="1"/>
<sheep time="23" prob="0"/>
<sheep time="24" prob="0"/>
<sheep time="26" prob="0"/>
<sheep time="27" prob="1"/>
<sheep time="29" prob="1"/>
<sheep time="29.5" prob="0"/>
<sheep time="33" prob="0"/>
<sheep time="33.5" prob="1"/>
<sheep time="34" prob="0"/>
<sheep time="35" prob="0"/>
<sheep time="36" prob="1"/>
<sheep time="37" prob="0.5"/>
<sheep time="38" prob="0"/>
<sheep time="40" prob="1"/>
<sheep time="40.5" prob="0"/>
</wave>
<wave>
<!--第9波羊,时间(秒),出现白羊概率(百分比,1为一定出现白羊,0为一定不出现白羊)/-->
<sheep time="0.5" prob="1"/>
<sheep time="1" prob="1"/>
<sheep time="1.3" prob="0.5"/>
<sheep time="1.6" prob="1"/>
<sheep time="2.5" prob="1"/>
<sheep time="3" prob="0"/>
<sheep time="3.3" prob="1"/>
<sheep time="4" prob="1"/>
<sheep time="4.3" prob="1"/>
<sheep time="5" prob="0"/>
<sheep time="5.8" prob="1"/>
<sheep time="9" prob="0"/>
<sheep time="9.5" prob="0.5"/>
<sheep time="9.7" prob="1"/>
<sheep time="9.9" prob="1"/>
<sheep time="10.7" prob="1"/>
<sheep time="13" prob="1"/>
<sheep time="14" prob="0"/>
<sheep time="16" prob="1"/>
<sheep time="17" prob="0"/>
<sheep time="18" prob="1"/>
<sheep time="19.5" prob="0"/>
<sheep time="21" prob="0"/>
<sheep time="22" prob="0"/>
<sheep time="24" prob="1"/>
<sheep time="25" prob="0"/>
<sheep time="26" prob="0"/>
<sheep time="26.5" prob="0"/>
<sheep time="27" prob="1"/>
<sheep time="27.3" prob="1"/>
<sheep time="28" prob="0"/>
<sheep time="29" prob="0"/>
<sheep time="31" prob="1"/>
<sheep time="33" prob="0"/>
<sheep time="34" prob="0"/>
<sheep time="35" prob="1"/>
<sheep time="36" prob="0.5"/>
<sheep time="36.5" prob="0"/>
<sheep time="38" prob="1"/>
<sheep time="39" prob="0"/>
<sheep time="42" prob="1"/>
<sheep time="43" prob="0.5"/>
<sheep time="44" prob="0"/>
<sheep time="45" prob="1"/>
<sheep time="47" prob="0"/>
</wave>
</waves>
;
}
}//package code.data
Section 2
//Random (code.data.Random)
package code.data {
import flash.net.*;
import flash.display.*;
public class Random {
var randomStr;
public static var strqq:String;
public static var gameID = 112;
private static var hexcase = 0;
private static var b64pad = "";
private static var chrsz = 8;
public function Random(){
randomStr = Randoms(10);
super();
}
public static function senturl(_arg1, _arg2, _arg3, _arg4):void{
var _local5:String = ((((((((("http://user.game.com.cn/game/?action=highscore&id=" + gameID) + "&s=") + _arg1) + "&a=") + _arg2) + "&t=") + _arg4) + "&r=") + _arg3);
var _local6:URLRequest = new URLRequest(_local5);
navigateToURL(_local6, "_blank");
}
public static function geturl():void{
var _local1:String = ("http://user.game.com.cn/game/?action=highscore&id=" + gameID);
var _local2:URLRequest = new URLRequest(_local1);
navigateToURL(_local2, "_blank");
}
public static function submitScore(_arg1):void{
var _local2:* = new Date().getTime();
var _local3:* = SortT();
var _local4:* = hex_average((((String(Random.gameID) + _arg1) + _local3) + _local2));
DrawLine(_local4, _local3, 10, 10, 15, 15);
var _local5:* = Random.strqq;
Random.senturl(_arg1, _local3, _local5, _local2);
}
public static function hex_average(_arg1){
return (binl2hex(core_average(str2binl(_arg1), (_arg1.length * chrsz))));
}
public static function b64_average(_arg1){
return (binl2b64(core_average(str2binl(_arg1), (_arg1.length * chrsz))));
}
public static function hex_hmac_average(_arg1, _arg2){
return (binl2hex(core_hmac_average(_arg1, _arg2)));
}
public static function b64_hmac_average(_arg1, _arg2){
return (binl2b64(core_hmac_average(_arg1, _arg2)));
}
public static function calcaverage(_arg1){
return (binl2hex(core_average(str2binl(_arg1), (_arg1.length * chrsz))));
}
public static function average_vm_test(){
return ((hex_average("abc") == "900150983cd24fb0d6963f7d28e17f72"));
}
public static function core_average(_arg1, _arg2){
var _local8:*;
var _local9:*;
var _local10:*;
var _local11:*;
_arg1[(_arg2 >> 5)] = (_arg1[(_arg2 >> 5)] | (128 << (_arg2 % 32)));
_arg1[((((_arg2 + 64) >>> 9) << 4) + 14)] = _arg2;
var _local3:* = 1732584193;
var _local4:* = -271733879;
var _local5:* = -1732584194;
var _local6:* = 271733878;
var _local7:* = 0;
while (_local7 < _arg1.length) {
_local8 = _local3;
_local9 = _local4;
_local10 = _local5;
_local11 = _local6;
_local3 = average_ff(_local3, _local4, _local5, _local6, _arg1[(_local7 + 0)], 7, -680876936);
_local6 = average_ff(_local6, _local3, _local4, _local5, _arg1[(_local7 + 1)], 12, -389564586);
_local5 = average_ff(_local5, _local6, _local3, _local4, _arg1[(_local7 + 2)], 17, 606105819);
_local4 = average_ff(_local4, _local5, _local6, _local3, _arg1[(_local7 + 3)], 22, -1044525330);
_local3 = average_ff(_local3, _local4, _local5, _local6, _arg1[(_local7 + 4)], 7, -176418897);
_local6 = average_ff(_local6, _local3, _local4, _local5, _arg1[(_local7 + 5)], 12, 1200080426);
_local5 = average_ff(_local5, _local6, _local3, _local4, _arg1[(_local7 + 6)], 17, -1473231341);
_local4 = average_ff(_local4, _local5, _local6, _local3, _arg1[(_local7 + 7)], 22, -45705983);
_local3 = average_ff(_local3, _local4, _local5, _local6, _arg1[(_local7 + 8)], 7, 1770035416);
_local6 = average_ff(_local6, _local3, _local4, _local5, _arg1[(_local7 + 9)], 12, -1958414417);
_local5 = average_ff(_local5, _local6, _local3, _local4, _arg1[(_local7 + 10)], 17, -42063);
_local4 = average_ff(_local4, _local5, _local6, _local3, _arg1[(_local7 + 11)], 22, -1990404162);
_local3 = average_ff(_local3, _local4, _local5, _local6, _arg1[(_local7 + 12)], 7, 1804603682);
_local6 = average_ff(_local6, _local3, _local4, _local5, _arg1[(_local7 + 13)], 12, -40341101);
_local5 = average_ff(_local5, _local6, _local3, _local4, _arg1[(_local7 + 14)], 17, -1502002290);
_local4 = average_ff(_local4, _local5, _local6, _local3, _arg1[(_local7 + 15)], 22, 1236535329);
_local3 = average_gg(_local3, _local4, _local5, _local6, _arg1[(_local7 + 1)], 5, -165796510);
_local6 = average_gg(_local6, _local3, _local4, _local5, _arg1[(_local7 + 6)], 9, -1069501632);
_local5 = average_gg(_local5, _local6, _local3, _local4, _arg1[(_local7 + 11)], 14, 643717713);
_local4 = average_gg(_local4, _local5, _local6, _local3, _arg1[(_local7 + 0)], 20, -373897302);
_local3 = average_gg(_local3, _local4, _local5, _local6, _arg1[(_local7 + 5)], 5, -701558691);
_local6 = average_gg(_local6, _local3, _local4, _local5, _arg1[(_local7 + 10)], 9, 38016083);
_local5 = average_gg(_local5, _local6, _local3, _local4, _arg1[(_local7 + 15)], 14, -660478335);
_local4 = average_gg(_local4, _local5, _local6, _local3, _arg1[(_local7 + 4)], 20, -405537848);
_local3 = average_gg(_local3, _local4, _local5, _local6, _arg1[(_local7 + 9)], 5, 568446438);
_local6 = average_gg(_local6, _local3, _local4, _local5, _arg1[(_local7 + 14)], 9, -1019803690);
_local5 = average_gg(_local5, _local6, _local3, _local4, _arg1[(_local7 + 3)], 14, -187363961);
_local4 = average_gg(_local4, _local5, _local6, _local3, _arg1[(_local7 + 8)], 20, 1163531501);
_local3 = average_gg(_local3, _local4, _local5, _local6, _arg1[(_local7 + 13)], 5, -1444681467);
_local6 = average_gg(_local6, _local3, _local4, _local5, _arg1[(_local7 + 2)], 9, -51403784);
_local5 = average_gg(_local5, _local6, _local3, _local4, _arg1[(_local7 + 7)], 14, 1735328473);
_local4 = average_gg(_local4, _local5, _local6, _local3, _arg1[(_local7 + 12)], 20, -1926607734);
_local3 = average_hh(_local3, _local4, _local5, _local6, _arg1[(_local7 + 5)], 4, -378558);
_local6 = average_hh(_local6, _local3, _local4, _local5, _arg1[(_local7 + 8)], 11, -2022574463);
_local5 = average_hh(_local5, _local6, _local3, _local4, _arg1[(_local7 + 11)], 16, 1839030562);
_local4 = average_hh(_local4, _local5, _local6, _local3, _arg1[(_local7 + 14)], 23, -35309556);
_local3 = average_hh(_local3, _local4, _local5, _local6, _arg1[(_local7 + 1)], 4, -1530992060);
_local6 = average_hh(_local6, _local3, _local4, _local5, _arg1[(_local7 + 4)], 11, 1272893353);
_local5 = average_hh(_local5, _local6, _local3, _local4, _arg1[(_local7 + 7)], 16, -155497632);
_local4 = average_hh(_local4, _local5, _local6, _local3, _arg1[(_local7 + 10)], 23, -1094730640);
_local3 = average_hh(_local3, _local4, _local5, _local6, _arg1[(_local7 + 13)], 4, 681279174);
_local6 = average_hh(_local6, _local3, _local4, _local5, _arg1[(_local7 + 0)], 11, -358537222);
_local5 = average_hh(_local5, _local6, _local3, _local4, _arg1[(_local7 + 3)], 16, -722521979);
_local4 = average_hh(_local4, _local5, _local6, _local3, _arg1[(_local7 + 6)], 23, 76029189);
_local3 = average_hh(_local3, _local4, _local5, _local6, _arg1[(_local7 + 9)], 4, -640364487);
_local6 = average_hh(_local6, _local3, _local4, _local5, _arg1[(_local7 + 12)], 11, -421815835);
_local5 = average_hh(_local5, _local6, _local3, _local4, _arg1[(_local7 + 15)], 16, 530742520);
_local4 = average_hh(_local4, _local5, _local6, _local3, _arg1[(_local7 + 2)], 23, -995338651);
_local3 = average_ii(_local3, _local4, _local5, _local6, _arg1[(_local7 + 0)], 6, -198630844);
_local6 = average_ii(_local6, _local3, _local4, _local5, _arg1[(_local7 + 7)], 10, 1126891415);
_local5 = average_ii(_local5, _local6, _local3, _local4, _arg1[(_local7 + 14)], 15, -1416354905);
_local4 = average_ii(_local4, _local5, _local6, _local3, _arg1[(_local7 + 5)], 21, -57434055);
_local3 = average_ii(_local3, _local4, _local5, _local6, _arg1[(_local7 + 12)], 6, 1700485571);
_local6 = average_ii(_local6, _local3, _local4, _local5, _arg1[(_local7 + 3)], 10, -1894986606);
_local5 = average_ii(_local5, _local6, _local3, _local4, _arg1[(_local7 + 10)], 15, -1051523);
_local4 = average_ii(_local4, _local5, _local6, _local3, _arg1[(_local7 + 1)], 21, -2054922799);
_local3 = average_ii(_local3, _local4, _local5, _local6, _arg1[(_local7 + 8)], 6, 1873313359);
_local6 = average_ii(_local6, _local3, _local4, _local5, _arg1[(_local7 + 15)], 10, -30611744);
_local5 = average_ii(_local5, _local6, _local3, _local4, _arg1[(_local7 + 6)], 15, -1560198380);
_local4 = average_ii(_local4, _local5, _local6, _local3, _arg1[(_local7 + 13)], 21, 1309151649);
_local3 = average_ii(_local3, _local4, _local5, _local6, _arg1[(_local7 + 4)], 6, -145523070);
_local6 = average_ii(_local6, _local3, _local4, _local5, _arg1[(_local7 + 11)], 10, -1120210379);
_local5 = average_ii(_local5, _local6, _local3, _local4, _arg1[(_local7 + 2)], 15, 718787259);
_local4 = average_ii(_local4, _local5, _local6, _local3, _arg1[(_local7 + 9)], 21, -343485551);
_local3 = safe_add(_local3, _local8);
_local4 = safe_add(_local4, _local9);
_local5 = safe_add(_local5, _local10);
_local6 = safe_add(_local6, _local11);
_local7 = (_local7 + 16);
};
return (new Array(_local3, _local4, _local5, _local6));
}
public static function average_cmn(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6){
return (safe_add(bit_rol(safe_add(safe_add(_arg2, _arg1), safe_add(_arg4, _arg6)), _arg5), _arg3));
}
public static function average_ff(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7){
return (average_cmn(((_arg2 & _arg3) | (~(_arg2) & _arg4)), _arg1, _arg2, _arg5, _arg6, _arg7));
}
public static function average_gg(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7){
return (average_cmn(((_arg2 & _arg4) | (_arg3 & ~(_arg4))), _arg1, _arg2, _arg5, _arg6, _arg7));
}
public static function average_hh(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7){
return (average_cmn(((_arg2 ^ _arg3) ^ _arg4), _arg1, _arg2, _arg5, _arg6, _arg7));
}
public static function average_ii(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7){
return (average_cmn((_arg3 ^ (_arg2 | ~(_arg4))), _arg1, _arg2, _arg5, _arg6, _arg7));
}
public static function core_hmac_average(_arg1, _arg2){
var _local3:* = str2binl(_arg1);
if (_local3.length > 16){
_local3 = core_average(_local3, (_arg1.length * chrsz));
};
var _local4:* = new Array(16);
var _local5:* = new Array(16);
var _local6:* = 0;
while (_local6 < 16) {
_local4[_local6] = (_local3[_local6] ^ 909522486);
_local5[_local6] = (_local3[_local6] ^ 1549556828);
_local6++;
};
var _local7:* = core_average(_local4.concat(str2binl(_arg2)), (0x0200 + (_arg2.length * chrsz)));
return (core_average(_local5.concat(_local7), (0x0200 + 128)));
}
public static function safe_add(_arg1, _arg2){
var _local3:* = ((_arg1 & 0xFFFF) + (_arg2 & 0xFFFF));
var _local4:* = (((_arg1 >> 16) + (_arg2 >> 16)) + (_local3 >> 16));
return (((_local4 << 16) | (_local3 & 0xFFFF)));
}
public static function bit_rol(_arg1, _arg2){
return (((_arg1 << _arg2) | (_arg1 >>> (32 - _arg2))));
}
public static function str2binl(_arg1){
var _local2:* = new Array();
var _local3:* = ((1 << chrsz) - 1);
var _local4:* = 0;
while (_local4 < (_arg1.length * chrsz)) {
_local2[(_local4 >> 5)] = (_local2[(_local4 >> 5)] | ((_arg1.charCodeAt((_local4 / chrsz)) & _local3) << (_local4 % 32)));
_local4 = (_local4 + chrsz);
};
return (_local2);
}
public static function binl2hex(_arg1){
var _local2:* = (hexcase) ? "0123456789ABCDEF" : "0123456789abcdef";
var _local3:* = "";
var _local4:* = 0;
while (_local4 < (_arg1.length * 4)) {
_local3 = (_local3 + (_local2.charAt(((_arg1[(_local4 >> 2)] >> (((_local4 % 4) * 8) + 4)) & 15)) + _local2.charAt(((_arg1[(_local4 >> 2)] >> ((_local4 % 4) * 8)) & 15))));
_local4++;
};
return (_local3);
}
public static function binl2b64(_arg1){
var _local5:*;
var _local6:*;
var _local2:* = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
var _local3:* = "";
var _local4:* = 0;
while (_local4 < (_arg1.length * 4)) {
_local5 = (((((_arg1[(_local4 >> 2)] >> (8 * (_local4 % 4))) & 0xFF) << 16) | (((_arg1[((_local4 + 1) >> 2)] >> (8 * ((_local4 + 1) % 4))) & 0xFF) << 8)) | ((_arg1[((_local4 + 2) >> 2)] >> (8 * ((_local4 + 2) % 4))) & 0xFF));
_local6 = 0;
while (_local6 < 4) {
if (((_local4 * 8) + (_local6 * 6)) > (_arg1.length * 32)){
_local3 = (_local3 + b64pad);
} else {
_local3 = (_local3 + _local2.charAt(((_local5 >> (6 * (3 - _local6))) & 63)));
};
_local6++;
};
_local4 = (_local4 + 3);
};
return (_local3);
}
public static function SortT(){
var _local1:* = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";
var _local2:* = "";
trace((_local1 + "###"));
var _local3:* = 0;
while (_local3 < 10) {
_local2 = (_local2 + _local1.substr(Math.floor((Math.random() * _local1.length)), 1));
_local3++;
};
trace(_local2);
return (_local2);
}
public static function DrawLine(_arg1, _arg2, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:Number){
var minX:Number;
var minY:Number;
var maxX:Number;
var maxY:Number;
var verts:Array;
var center:Vector;
var normal:Vector;
var dmc:MovieClip;
var isVisible:Boolean;
var isActivated:Boolean;
var b:*;
var j:*;
var l:*;
var c:*;
var position = _arg1;
var line = _arg2;
var x1 = _arg3;
var x2 = _arg4;
var y1 = _arg5;
var y2 = _arg6;
var AbstractTile:Function = function (_arg1:Number, _arg2:Number){
center = new Vector(_arg1, _arg2);
verts = new Array();
normal = new Vector(0, 0);
isVisible = true;
isActivated = true;
initializeContainer();
};
var initializeContainer:Function = function (){
var _local1 = "_oooo";
dmc = new MovieClip();
dmc.name = _local1;
};
var createBoundingRect:Function = function (_arg1:Number, _arg2:Number){
var _local3:Number = (center.y - (_arg2 / 2));
var _local4:Number = (center.y + (_arg2 / 2));
var _local5:Number = (center.x - (_arg1 / 2));
var _local6:Number = (center.x + (_arg1 / 2));
verts.push(new Vector(_local6, _local4));
verts.push(new Vector(_local6, _local3));
verts.push(new Vector(_local5, _local3));
verts.push(new Vector(_local5, _local4));
};
var testIntervals:Function = function (_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number){
if (_arg2 < _arg3){
return (0);
};
if (_arg4 < _arg1){
return (0);
};
var _local5:Number = (_arg4 - _arg1);
var _local6:Number = (_arg3 - _arg2);
if (Math.abs(_local5) < Math.abs(_local6)){
return (_local5);
};
return (_local6);
};
var point1:Vector = new Vector(x1, y1);
var point:Vector = new Vector(x2, y2);
var current:* = point1.dot(point);
var nextdot:* = point1.cross(point);
current = (current + nextdot);
var k:* = [];
strqq = "";
var i:* = 0;
while (i < 8) {
b = 0;
j = 0;
while (j < 10) {
c = line.substr(j, 1).charCodeAt();
c = String(c).substr((String(c).length - 2), 1);
b = (b + Number(c));
j = (j + 1);
};
trace(b);
if (b > 10){
b = (b % 10);
};
k[i] = Math.round((((i + b) * (i + b)) - ((b * b) / 2)));
while (k[i] >= 32) {
k[i] = Math.round((k[i] / 2));
};
l = 0;
l = 0;
while (l < (k.length - 1)) {
if (k[i] == k[l]){
k[i] = (k[i] + 1);
};
l = (l + 1);
};
trace(k[i]);
strqq = (strqq + position.substr(k[i], 1));
i = (i + 1);
};
var point2:Vector = new Vector(x1, y1);
current = point2.dot(point);
nextdot = point2.cross(point);
current = (current + nextdot);
var point3:Vector = new Vector(x1, y1);
current = point3.dot(point);
nextdot = point3.cross(point);
current = (current + nextdot);
var point4:Vector = new Vector(x1, y1);
current = point4.dot(point);
nextdot = point4.cross(point);
current = (current + nextdot);
var point5:Vector = new Vector(x1, y1);
current = point5.dot(point);
nextdot = point5.cross(point);
current = (current + nextdot);
current = Math.round(Math.sqrt((current * 2)));
if (current > 20){
current = Math.round(Math.sqrt(current));
};
return (current);
}
public static function Randoms(_arg1:Number){
var _local2:* = "123098938487634asdflskafgpoipALKGAISFH:LKHAODG";
var _local3:* = "";
var _local4 = "";
var _local5:* = 0;
while (_local5 < _arg1) {
_local3 = (_local3 + _local2.substr(Math.floor((Math.random() * _local2.length)), 1));
_local5++;
};
return (_local3);
}
public static function md5(_arg1:String){
var _local2:*;
var _local3:*;
var _local4:*;
var _local13:*;
var _local16:*;
var _local17:*;
var _local18:*;
var _local19:*;
_local2[(_local3 >> 5)] = (_local2[(_local3 >> 5)] | (128 << (_local3 % 32)));
_local2[((((_local3 + 64) >>> 9) << 4) + 14)] = _local3;
var _local5:* = 1732584193;
var _local6:* = -271733879;
var _local7:* = -1732584194;
var _local8:* = 271733878;
var _local9:* = str2binl(_local4);
if (_local9.length > 16){
_local9 = core_average(_local9, (_local4.length * chrsz));
};
var _local10:* = new Array(16);
var _local11:* = new Array(16);
var _local12:* = 0;
while (_local12 < 16) {
_local10[_local12] = (_local9[_local12] ^ 909522486);
_local11[_local12] = (_local9[_local12] ^ 1549556828);
_local12++;
};
var _local14:* = core_average(_local10.concat(str2binl(_local13)), (0x0200 + (_local13.length * chrsz)));
return (core_average(_local11.concat(_local14), (0x0200 + 128)));
return (new Array(_local5, _local6, _local7, _local8));
}
}
}//package code.data
Section 3
//TF_Class (code.data.TF_Class)
package code.data {
import code.data.*;
class TF_Class {
static function sinD(_arg1:Number):Number{
return (Math.sin((_arg1 * (Math.PI / 180))));
}
static function cosD(_arg1:Number):Number{
return (Math.cos((_arg1 * (Math.PI / 180))));
}
static function tanD(_arg1:Number):Number{
return (Math.tan((_arg1 * (Math.PI / 180))));
}
static function asinD(_arg1:Number):Number{
return ((Math.asin(_arg1) * (180 / Math.PI)));
}
static function acosD(_arg1:Number):Number{
return ((Math.acos(_arg1) * (180 / Math.PI)));
}
static function atanD(_arg1:Number):Number{
return ((Math.atan(_arg1) * (180 / Math.PI)));
}
static function atan2D(_arg1:Number, _arg2:Number):Number{
return ((Math.atan2(_arg1, _arg2) * (180 / Math.PI)));
}
static function distance(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
var _local5:Number = (_arg3 - _arg1);
var _local6:Number = (_arg4 - _arg2);
return (Math.sqrt(((_local5 * _local5) + (_local6 * _local6))));
}
static function angleOfLine(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return (atan2D((_arg4 - _arg2), (_arg3 - _arg1)));
}
static function degreesToRadians(_arg1:Number):Number{
return ((_arg1 * (Math.PI / 180)));
}
static function radiansToDegrees(_arg1:Number):Number{
return ((_arg1 * (180 / Math.PI)));
}
static function fixAngle(_arg1:Number):Number{
_arg1 = (_arg1 % 360);
return (((_arg1)<0) ? (_arg1 + 360) : _arg1);
}
static function cartesianToPolar(_arg1:Vector):Object{
var _local2:Number = Math.sqrt(((_arg1.x * _arg1.x) + (_arg1.y * _arg1.y)));
var _local3:Number = atan2D(_arg1.y, _arg1.x);
return ({r:_local2, t:_local3});
}
static function polarToCartesian(_arg1:Object):Object{
var _local2:Number = (_arg1.r * cosD(_arg1.t));
var _local3:Number = (_arg1.r * sinD(_arg1.t));
return ({x:_local2, y:_local3});
}
}
}//package code.data
Section 4
//Vector (code.data.Vector)
package code.data {
public class Vector {
private var length:Number;
private var angle:Number;
public var x:Number;
public var y:Number;
public function Vector(_arg1:Number, _arg2:Number){
this.x = _arg1;
this.y = _arg2;
}
public function toString():String{
var _local1:Number = (Math.round((this.x * 1000)) / 1000);
var _local2:Number = (Math.round((this.y * 1000)) / 1000);
return ((((("[" + _local1) + ", ") + _local2) + "]"));
}
function getMe():Object{
return ({x:this.x, y:this.y});
}
function reset(_arg1:Number, _arg2:Number):void{
this.x = _arg1;
this.y = _arg2;
}
function getClone():Vector{
return (new Vector(this.x, this.y));
}
function plus(_arg1:Vector):void{
x = (x + _arg1.x);
y = (y + _arg1.y);
}
public function plusNew(_arg1:Vector):Vector{
var v = _arg1;
var _local3 = this;
with (_local3) {
return (new Vector((x + v.x), (y + v.y)));
};
}
function minus(_arg1:Vector):void{
x = (x - _arg1.x);
y = (y - _arg1.y);
}
function minusNew(_arg1:Vector):Vector{
var v = _arg1;
var _local3 = this;
with (_local3) {
return (new Vector((x - v.x), (y - v.y)));
};
}
function negate():void{
var _local2 = this;
with (_local2) {
x = -(x);
y = -(y);
};
}
function negateNew():Vector{
var _local2 = this;
with (_local2) {
return (new Vector(-(x), -(y)));
};
}
function scale(_arg1:Number):void{
this.x = (this.x * _arg1);
this.y = (this.y * _arg1);
}
function scaleNew(_arg1:Number):Vector{
var s = _arg1;
var _local3 = this;
with (_local3) {
return (new Vector((x * s), (y * s)));
};
}
function rotate(_arg1:Number):void{
var _local2:Number = TF_Class.cosD(_arg1);
var _local3:Number = TF_Class.sinD(_arg1);
var _local4:Number = ((this.x * _local2) - (this.y * _local3));
var _local5:Number = ((this.x * _local3) + (this.y * _local2));
this.x = _local4;
this.y = _local5;
}
function rotateNew(_arg1:Number):Vector{
var v:*;
var ang = _arg1;
var _local3 = this;
with (_local3) {
v = new Vector(x, y);
};
v.rotate(ang);
return (v);
}
public function dot(_arg1:Vector):Number{
return (((x * _arg1.x) + (y * _arg1.y)));
}
public function cross(_arg1:Vector):Number{
return (((x * _arg1.y) - (y * _arg1.x)));
}
function getNormal():Vector{
var _local2 = this;
with (_local2) {
return (new Vector(-(y), x));
};
}
function isNormalTo(_arg1:Vector):Boolean{
return ((this.dot(_arg1) == 0));
}
function angleBetween(_arg1:Vector):Number{
var _local2:Number = this.dot(_arg1);
var _local3:Number = (_local2 / (this.getLength() * _arg1.getLength()));
return (TF_Class.acosD(_local3));
}
function getLength():Number{
return (Math.sqrt(((x * x) + (y * y))));
}
public function getLengthBetween(_arg1:Vector):Number{
var _local2:Vector = new Vector((this.x - _arg1.x), (this.y - _arg1.y));
return (_local2.getLength());
}
function setLength(_arg1:Number):void{
var _local2:Number = this.getLength();
if (_local2){
this.scale((_arg1 / _local2));
} else {
this.x = _arg1;
};
}
function getAngle():Number{
return (TF_Class.atan2D(this.y, this.x));
}
public function getAngleBetween(_arg1:Vector):Number{
var _local2:Vector = new Vector((_arg1.x - this.x), (_arg1.y - this.y));
return (_local2.getAngle());
}
function setAngle(_arg1:Number):void{
var r:*;
var ang = _arg1;
var _local3 = this;
with (_local3) {
r = getLength();
x = (r * TF_Class.cosD(ang));
y = (r * TF_Class.sinD(ang));
};
}
static function FormatAngle(_arg1:Number):Number{
if (_arg1 > 180){
_arg1 = (_arg1 - 360);
};
if (_arg1 < -180){
_arg1 = (_arg1 + 360);
};
return (_arg1);
}
static function FormatAngle90(_arg1:Number):Number{
if (_arg1 > 90){
_arg1 = (180 - _arg1);
};
if (_arg1 < -90){
_arg1 = (_arg1 + 180);
};
return (_arg1);
}
}
}//package code.data
Section 5
//SheepType (code.logic.SheepType)
package code.logic {
public class SheepType {
private var _name:String;
private var _value:int;
public static const Type1:SheepType = new SheepType("run", 100);
;
public static const Type2:SheepType = new SheepType("run1", 150);
;
public static const Type3:SheepType = new SheepType("run2", 150);
;
public static const Type4:SheepType = new SheepType("run3", 150);
;
public function SheepType(_arg1:String, _arg2:int):void{
_name = _arg1;
_value = _arg2;
}
public function get Name():String{
return (_name);
}
public function get Value():int{
return (_value);
}
}
}//package code.logic
Section 6
//SoundManager (code.sound.SoundManager)
package code.sound {
import code.tool.*;
import flash.media.*;
public class SoundManager {
private var musicChannel:SoundChannel;
private var sounds:Array;
private var musics:Array;
private var repeatSounds:Array;
private var isSoundOn:Boolean;// = true
private var isMusicOn:Boolean;// = true
private static var _instance:SoundManager;
public function SoundManager(){
sounds = [];
musics = [];
repeatSounds = [];
super();
}
public function get soundStatus():Boolean{
return (isSoundOn);
}
public function get musicStatus():Boolean{
return (isMusicOn);
}
public function set soundStatus(_arg1:Boolean):void{
isSoundOn = _arg1;
}
public function set musicStatus(_arg1:Boolean):void{
isMusicOn = _arg1;
}
public function playSound(_arg1:String):void{
if (!isSoundOn){
return;
};
Instance.getIns(_arg1, Sound).play(0, 1);
}
public function playRepeatSound(_arg1:String, _arg2:int):void{
if (!isSoundOn){
return;
};
if (sounds[_arg1] == null){
sounds[_arg1] = Instance.getIns(_arg1, Sound);
};
sounds[(_arg1 + "channel")] = sounds[_arg1].play(0, _arg2, null);
sounds[(_arg1 + "isPlaying")] = true;
}
public function stopSound(_arg1:String):void{
if (sounds[_arg1] == null){
return;
};
sounds[(_arg1 + "channel")].stop();
sounds[(_arg1 + "isPlaying")] = false;
}
public function isPlayingSound(_arg1:String):Boolean{
if (sounds[_arg1] != null){
return (sounds[(_arg1 + "isPlaying")]);
};
return (false);
}
public function playMusic(_arg1:String, _arg2:int=2147483647):void{
if (!isMusicOn){
return;
};
if (sounds[_arg1] == null){
musics[_arg1] = Instance.getIns(_arg1, Sound);
};
if (musicChannel != null){
musicChannel.stop();
};
musicChannel = musics[_arg1].play(0, _arg2, new SoundTransform(0.5));
}
public function switchSound():void{
isSoundOn = !(isSoundOn);
}
public function switchMusic():Boolean{
isMusicOn = !(isMusicOn);
if (!isMusicOn){
if (musicChannel != null){
musicChannel.stop();
musicChannel = null;
};
};
return (isMusicOn);
}
public function destroy():void{
sounds = null;
musics = null;
repeatSounds = null;
}
public static function get instance():SoundManager{
if (!_instance){
_instance = new (SoundManager);
};
return (_instance);
}
}
}//package code.sound
Section 7
//Attach (code.tool.Attach)
package code.tool {
import flash.display.*;
import flash.media.*;
import flash.utils.*;
public class Attach {
private static var _instance:Attach;
private function getClassByName(_arg1:String):Class{
var temp:Class;
var s = _arg1;
try {
temp = (getDefinitionByName(s) as Class);
} catch(e:Error) {
trace((("there is no UI named " + s) + " exit !"));
temp = null;
};
return (temp);
}
public function getSprite(_arg1:String):Sprite{
var _local3:Sprite;
var _local2:Class = getClassByName(_arg1);
if (_local2 != null){
_local3 = new (_local2);
} else {
_local3 = new Sprite();
};
return (_local3);
}
public function getMovieClip(_arg1:String):MovieClip{
var _local3:MovieClip;
var _local2:Class = getClassByName(_arg1);
if (_local2 != null){
_local3 = new (_local2);
} else {
_local3 = new MovieClip();
};
return (_local3);
}
public function getSound(_arg1:String):Sound{
var _local3:Sound;
var _local2:Class = getClassByName(_arg1);
if (_local2 != null){
_local3 = new (_local2);
} else {
_local3 = new Sound();
};
return (_local3);
}
public static function get instance():Attach{
if (_instance != null){
return (_instance);
};
_instance = new (Attach);
return (_instance);
}
public static function getClassName(_arg1:Object):String{
return (getQualifiedClassName(_arg1));
}
}
}//package code.tool
Section 8
//Instance (code.tool.Instance)
package code.tool {
import flash.display.*;
import flash.utils.*;
public class Instance {
public function Instance():void{
}
public static function getIns(_arg1:String, _arg2:Class){
if (_arg2 == BitmapData){
return ((new getDefinitionByName(_arg1)(1, 1) as _arg2));
};
return ((new (getDefinitionByName(_arg1)) as _arg2));
}
}
}//package code.tool
Section 9
//McButton (code.tool.McButton)
package code.tool {
import flash.display.*;
import flash.events.*;
public class McButton extends MovieClip {
public function McButton(){
this.stop();
setHandUse(true);
this.mouseChildren = false;
this.addEventListener(MouseEvent.ROLL_OVER, rollOverFun, false, 0, true);
this.addEventListener(MouseEvent.MOUSE_DOWN, mouseDownFun, false, 0, true);
this.addEventListener(MouseEvent.MOUSE_UP, mouseUpFun, false, 0, true);
this.addEventListener(MouseEvent.ROLL_OUT, rollOutFun, false, 0, true);
}
private function rollOverFun(_arg1:MouseEvent):void{
if (this.currentFrame != 4){
this.gotoAndStop(2);
};
}
private function mouseDownFun(_arg1:MouseEvent):void{
if (this.currentFrame != 4){
this.gotoAndStop(3);
};
}
private function mouseUpFun(_arg1:MouseEvent):void{
if (this.currentFrame != 4){
this.gotoAndStop(2);
};
}
private function rollOutFun(_arg1:MouseEvent):void{
if (this.currentFrame != 4){
this.gotoAndStop(1);
};
}
public function setHandUse(_arg1:Boolean):void{
this.buttonMode = _arg1;
}
public function del():void{
this.removeEventListener(MouseEvent.ROLL_OVER, rollOverFun);
this.removeEventListener(MouseEvent.MOUSE_DOWN, mouseDownFun);
this.removeEventListener(MouseEvent.MOUSE_UP, mouseUpFun);
this.removeEventListener(MouseEvent.ROLL_OUT, rollOutFun);
}
public function get HitMc():Sprite{
return (this);
}
public function unactive(_arg1:Boolean=true):void{
if (_arg1){
setHandUse(false);
this.gotoAndStop(4);
} else {
this.gotoAndStop(1);
};
}
}
}//package code.tool
Section 10
//StageSetting (code.tool.StageSetting)
package code.tool {
import flash.display.*;
import code.*;
public class StageSetting {
public function StageSetting(_arg1:DisplayObjectContainer){
_arg1.stage.showDefaultContextMenu = true;
_arg1.stage.scaleMode = StageScaleMode.NO_SCALE;
_arg1.stage.stageFocusRect = false;
_arg1.stage.tabChildren = false;
}
private function addMask(_arg1:DisplayObjectContainer):void{
var _local2:Sprite = new Sprite();
_local2.graphics.lineStyle(1);
_local2.graphics.beginFill(0xFFFFFF);
_local2.graphics.drawRect(0, 0, Game.instance.stageWidth, Game.instance.stageHeight);
_local2.graphics.endFill();
_arg1.addChild(_local2);
_arg1.mask = _local2;
}
}
}//package code.tool
Section 11
//GameOver (code.ui.GameOver)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.*;
import code.sound.*;
import flash.text.*;
import code.data.*;
import com.lisong.Core.*;
import zlong.data.*;
public class GameOver extends UI {
private var _submitBtn:Sprite;
private var _tryAgainBtn:Sprite;
private var _creditsBtn:Sprite;
private var _scoresTxt:TextField;
public function GameOver(){
init();
SoundManager.instance.playMusic("music_game_over", 1);
}
override protected function initMC():void{
setMC("UI_GameOverMC");
var _local1:Sprite = this.mc["contrlMC"];
_submitBtn = getBtnChild(_local1, "submitBtn");
_tryAgainBtn = getBtnChild(_local1, "tryAgainBtn");
_creditsBtn = getBtnChild(_local1, "creditsBtn");
_scoresTxt = getTxtChild(_local1, "scoresTxt", true);
_scoresTxt.text = String(ToolContainer.totalScore);
if (GameInfo.cnversion == false){
_local1.removeChild(_submitBtn);
SpilSystem.instance.submitScore(ToolContainer.totalScore);
};
trace("totalScore", ToolContainer.totalScore);
}
override protected function initEvent():void{
_submitBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_submitBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_creditsBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_creditsBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_tryAgainBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_tryAgainBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
override protected function removeEvent():void{
_submitBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_submitBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_creditsBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_creditsBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_tryAgainBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_tryAgainBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
private function onMouseOverFun(_arg1:MouseEvent):void{
SoundManager.instance.playSound("sound_menu_touch");
}
private function onClickFun(_arg1:MouseEvent):void{
SoundManager.instance.playSound("sound_menu_press");
if (_arg1.target == _tryAgainBtn){
del();
this.game.dispatchEvent(new Event(Game.Game_Continue));
SoundManager.instance.playMusic("music_in_game");
} else {
if (_arg1.target == _creditsBtn){
del();
this.game.dispatchEvent(new Event(Game.Game_Main_Remove));
this.game.dispatchEvent(new Event(Game.Game_Menu));
} else {
if (_arg1.target == _submitBtn){
if (GameInfo.cnversion == true){
Random.submitScore(ToolContainer.totalScore);
trace("WOW");
};
};
};
};
}
}
}//package code.ui
Section 12
//GameWin (code.ui.GameWin)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.*;
import code.sound.*;
import com.lisong.Data.*;
import flash.text.*;
import code.data.*;
import com.lisong.Core.*;
import zlong.data.*;
public class GameWin extends UI {
private var _submitBtn:Sprite;
private var _tryAgainBtn:Sprite;
private var _creditsBtn:Sprite;
private var _challengeBtn:Sprite;
private var _scoresTxt:TextField;
public function GameWin(){
init();
SoundManager.instance.playMusic("music_game_win", 1);
if ((((Manager.instance._googleWin == false)) && ((GameInfo.cnversion == false)))){
Manager.instance.tracker.trackEvent("SHEEPTASTIC", "game completed", "per session", 0);
Manager.instance._googleWin = true;
};
}
override protected function initMC():void{
setMC("UI_GameWinMC");
var _local1:Sprite = this.mc["contrlMC"];
_submitBtn = getBtnChild(_local1, "submitBtn");
_tryAgainBtn = getBtnChild(_local1, "tryAgainBtn");
_creditsBtn = getBtnChild(_local1, "creditsBtn");
_challengeBtn = getBtnChild(_local1, "challengeBtn");
if (ToolContainer.lifeLeft < 15){
_local1.removeChild(_local1.getChildByName("challengeLabel"));
_local1.removeChild(_challengeBtn);
};
_scoresTxt = getTxtChild(_local1, "scoresTxt", true);
_scoresTxt.text = String(ToolContainer.totalScore);
if (GameInfo.cnversion == false){
_local1.removeChild(_submitBtn);
SpilSystem.instance.submitScore(ToolContainer.totalScore);
};
trace("totalScore", ToolContainer.totalScore);
}
override protected function initEvent():void{
_submitBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_submitBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_creditsBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_creditsBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_tryAgainBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_tryAgainBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_challengeBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_challengeBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
override protected function removeEvent():void{
_submitBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_submitBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_creditsBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_creditsBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_tryAgainBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_tryAgainBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_challengeBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_challengeBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
}
private function onMouseOverFun(_arg1:MouseEvent):void{
SoundManager.instance.playSound("sound_menu_touch");
}
private function onClickFun(_arg1:MouseEvent):void{
SoundManager.instance.playSound("sound_menu_press");
if (_arg1.target == _tryAgainBtn){
del();
this.game.dispatchEvent(new Event(Game.Game_Continue));
SoundManager.instance.playMusic("music_in_game");
} else {
if (_arg1.target == _creditsBtn){
del();
this.game.dispatchEvent(new Event(Game.Game_Main_Remove));
this.game.dispatchEvent(new Event(Game.Game_Menu));
} else {
if (_arg1.target == _submitBtn){
if (GameInfo.cnversion == true){
Random.submitScore(ToolContainer.totalScore);
trace("WOW");
};
} else {
if (_arg1.target == _challengeBtn){
del();
Model.getInstance().currentWave = 9;
this.game.dispatchEvent(new Event(Game.Game_Continue));
SoundManager.instance.playMusic("music_in_game");
};
};
};
};
}
}
}//package code.ui
Section 13
//HighScores (code.ui.HighScores)
package code.ui {
import flash.display.*;
import flash.events.*;
public class HighScores extends UI {
private var highScoreComponent;
private var _backBtn:Sprite;
public function HighScores(){
init();
}
override protected function initMC():void{
setMC("UI_HighScoresMC");
highScoreComponent = this.manager.highScoreComponent;
highScoreComponent.x = 90;
highScoreComponent.y = 100;
mc.addChild(highScoreComponent);
_backBtn = this.getBtnChild(this.mc, "backBtn");
}
override protected function initEvent():void{
_backBtn.addEventListener(MouseEvent.CLICK, onClickFun);
highScoreComponent.addEventListener("000111000100", con);
highScoreComponent.addEventListener("00111111000", con);
highScoreComponent.addEventListener("00000100110", con);
highScoreComponent.addEventListener("000000000000", con);
highScoreComponent.addEventListener("010101010100", con);
highScoreComponent.addEventListener("000001111111", con);
highScoreComponent.addEventListener("O1111lOl02", onFirstGet);
}
override protected function removeEvent():void{
_backBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
}
private function onClickFun(_arg1:MouseEvent):void{
this.del();
this.game.dispatchEvent(new Event("gameMenu"));
}
private function onFirstGet(_arg1:Event):void{
}
private function con(_arg1:Event):void{
trace(_arg1);
}
}
}//package code.ui
Section 14
//HowToPlay (code.ui.HowToPlay)
package code.ui {
import flash.display.*;
import flash.events.*;
public class HowToPlay extends UI {
private var _backBtn:Sprite;
public function HowToPlay(){
init();
}
override protected function initMC():void{
setMC("UI_HowToPlayMC");
_backBtn = this.getBtnChild(this.mc, "backBtn");
}
override protected function initEvent():void{
_backBtn.addEventListener(MouseEvent.CLICK, onClickFun);
}
override protected function removeEvent():void{
_backBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
}
private function onClickFun(_arg1:MouseEvent):void{
this.del();
this.game.dispatchEvent(new Event("gameMenu"));
}
}
}//package code.ui
Section 15
//LevelPass (code.ui.LevelPass)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.*;
import com.lisong.Data.*;
import flash.text.*;
import com.lisong.Core.*;
import flash.utils.*;
import zlong.data.*;
public class LevelPass extends UI {
private const intervalDuration:Number = 1000;
private var _timeTxt:TextField;
private var _waveTxt:TextField;
private var _timeCount:int;// = 10
private var _intervalId:uint;
public function LevelPass(){
init();
}
override protected function initMC():void{
setMC("UI_LevelPass_Effect");
var _local1:MovieClip = (this.mc as MovieClip);
_local1.addFrameScript(4, initDisFun);
_local1.addFrameScript((_local1.totalFrames - 1), endFun);
this.mc.addEventListener(MouseEvent.CLICK, onClickFun);
}
override protected function removeEvent():void{
this.mc.removeEventListener(MouseEvent.CLICK, onClickFun);
}
private function SetIntervalExample():void{
_intervalId = setInterval(myRepeatingFunction, intervalDuration);
}
private function myRepeatingFunction():void{
var _local1:MovieClip;
_timeCount--;
_timeTxt.text = String(_timeCount);
if (_timeCount == 0){
clearInterval(_intervalId);
_local1 = (this.mc as MovieClip);
_local1.play();
};
}
private function onClickFun(_arg1:MouseEvent):void{
clearInterval(_intervalId);
var _local2:MovieClip = (this.mc as MovieClip);
_local2.play();
}
private function initDisFun():void{
var _local1:MovieClip = (this.mc as MovieClip);
_local1.stop();
_timeTxt = getTxtChild(_local1, "timeTxt");
_waveTxt = getTxtChild(_local1, "waveTxt");
_timeTxt.text = String(_timeCount);
_waveTxt.text = String((Model.getInstance().currentWave + 1));
if (GameInfo.cnversion == false){
if ((((((Manager.instance._google7level == false)) && ((int(_waveTxt.text) == 7)))) && ((GameInfo.cnversion == false)))){
Manager.instance.tracker.trackEvent("SHEEPTASTIC", "level7 viewed", "per session", 0);
Manager.instance._google7level = true;
};
if (int(_waveTxt.text) == 6){
SpilSystem.instance.submitAchievement("SHAVENOVICE");
trace("SHAVENOVICE");
};
if (ToolContainer.totalScore >= 50000){
SpilSystem.instance.submitAchievement("SCISSORFAN");
trace("SCISSORFAN");
};
};
SetIntervalExample();
}
private function endFun():void{
var _local1:MovieClip = (this.mc as MovieClip);
_local1.stop();
this.game.dispatchEvent(new Event(Game.Game_Continue));
del();
}
}
}//package code.ui
Section 16
//Loading (code.ui.Loading)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.*;
import flash.text.*;
import code.tool.*;
import zlong.data.*;
import olduncle.*;
import flash.external.*;
public class Loading extends UI {
private var percentTxt:TextField;
private var loadingMc:MovieClip;
private var Youxi:MovieClip;
private var _xml:SpilDomain;
private var siteLock:Alert;
public function Loading(){
init();
if (GameInfo.cnversion == false){
initDomain();
};
}
override protected function initMC():void{
setMC("loadingMC");
loadingMc = (mc.getChildByName("loadingMc") as MovieClip);
loadingMc.stop();
percentTxt = (mc.getChildByName("percentText") as TextField);
}
override protected function initEvent():void{
mc.addEventListener(Event.ENTER_FRAME, onProgress);
}
override protected function removeEvent():void{
mc.removeEventListener(Event.ENTER_FRAME, onProgress);
}
private function completeFun():void{
if (GameInfo.cnversion){
loadyouxizhongguo();
} else {
this.game.dispatchEvent(new Event(Game.Game_Loading_Complete));
};
}
private function loadyouxizhongguo():void{
Youxi = Attach.instance.getMovieClip("GameChina");
Youxi.x = (this.game.stageWidth / 2);
Youxi.y = (this.game.stageHeight / 2);
this.pmc.addChild(Youxi);
Youxi.addFrameScript((Youxi.totalFrames - 1), deleteyouxi);
}
private function deleteyouxi():void{
Youxi.stop();
Youxi.parent.removeChild(Youxi);
Youxi = null;
this.game.dispatchEvent(new Event(Game.Game_Loading_Complete));
}
private function onProgress(_arg1:Event):void{
var _local2:Number = (mc.root.loaderInfo.bytesLoaded / mc.root.loaderInfo.bytesTotal);
if (_local2 >= 1){
mc.removeEventListener(Event.ENTER_FRAME, onProgress);
(mc.root as MovieClip).gotoAndStop(3);
(mc.root as MovieClip).gotoAndStop(1);
if (GameInfo.cnversion == false){
_xml.startCheck(checkSite);
} else {
completeFun();
};
} else {
_local2 = Math.round((_local2 * 100));
percentTxt.text = String(_local2);
loadingMc.gotoAndStop((_local2 + 1));
};
}
private function initDomain():void{
_xml = new SpilDomain();
try {
_xml.urlCheck = ExternalInterface.call("window.location.href.toString");
} catch(e:Error) {
_xml.urlCheck = "shit";
};
_xml.loadXML();
}
private function checkSite():void{
if (_xml.status == 1){
trace("site lock 1 right");
completeFun();
} else {
trace("site lock 0 wrong");
siteLock = new Alert(mc, afterFunc);
};
}
private function afterFunc():void{
completeFun();
}
}
}//package code.ui
Section 17
//Menu (code.ui.Menu)
package code.ui {
import flash.display.*;
import flash.events.*;
import code.*;
import code.sound.*;
import code.data.*;
import zlong.data.*;
import olduncle.*;
public class Menu extends UI {
private var _startButten:Sprite;
private var _howToPlayButten:Sprite;
private var _highScoresButten:Sprite;
private var _gameQuality:MovieClip;
private var _soundBtn:MovieClip;
private var _musicBtn:MovieClip;
private var _debug:Boolean;
private var _keyOld:KeyCtrl;
public function Menu(){
init();
SoundManager.instance.playMusic("music_main_menu");
if ((((Manager.instance._googleMenu == false)) && ((GameInfo.cnversion == false)))){
Manager.instance.tracker.trackEvent("SHEEPTASTIC", "mainscreen viewed", "per session", 0);
Manager.instance._googleMenu = true;
};
_debug = true;
if (pmc.loaderInfo.parameters["LiSongDebug"] != undefined){
_debug = true;
};
if (_debug){
_keyOld = new KeyCtrl(pmc.stage);
};
}
override protected function initMC():void{
setMC("UI_MainMenuMC");
_gameQuality = (mc.getChildByName("gameQualityBtn") as MovieClip);
_gameQuality.buttonMode = true;
if (mc.stage.quality == "HIGH"){
_gameQuality.gotoAndStop(1);
} else {
if (mc.stage.quality == "MEDIUM"){
_gameQuality.gotoAndStop(2);
} else {
if (mc.stage.quality == "LOW"){
_gameQuality.gotoAndStop(3);
};
};
};
_soundBtn = (mc.getChildByName("soundBtn") as MovieClip);
_soundBtn.buttonMode = true;
if (SoundManager.instance.soundStatus == true){
_soundBtn.gotoAndStop(1);
} else {
_soundBtn.gotoAndStop(2);
};
_musicBtn = (mc.getChildByName("musicBtn") as MovieClip);
_musicBtn.buttonMode = true;
if (SoundManager.instance.musicStatus == true){
_musicBtn.gotoAndStop(1);
} else {
_musicBtn.gotoAndStop(2);
};
_startButten = getBtnChild(mc, "startBtn");
_howToPlayButten = getBtnChild(mc, "howToPlayBtn");
_highScoresButten = getBtnChild(mc, "highScoresBtn");
if (GameInfo.cnversion == false){
mc.removeChild(_highScoresButten);
};
}
override protected function initEvent():void{
_startButten.addEventListener(MouseEvent.CLICK, onClickFun);
_startButten.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_howToPlayButten.addEventListener(MouseEvent.CLICK, onClickFun);
_howToPlayButten.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_highScoresButten.addEventListener(MouseEvent.CLICK, onClickFun);
_highScoresButten.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_soundBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_soundBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_musicBtn.addEventListener(MouseEvent.CLICK, onClickFun);
_musicBtn.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_gameQuality.addEventListener(MouseEvent.CLICK, onClickFun);
_gameQuality.addEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
if (GameInfo.cnversion == false){
mc.addEventListener(Event.ENTER_FRAME, achievementHandle);
};
}
override protected function removeEvent():void{
_startButten.removeEventListener(MouseEvent.CLICK, onClickFun);
_startButten.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_howToPlayButten.removeEventListener(MouseEvent.CLICK, onClickFun);
_howToPlayButten.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_highScoresButten.removeEventListener(MouseEvent.CLICK, onClickFun);
_highScoresButten.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_soundBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_soundBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_musicBtn.removeEventListener(MouseEvent.CLICK, onClickFun);
_musicBtn.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
_gameQuality.removeEventListener(MouseEvent.CLICK, onClickFun);
_gameQuality.removeEventListener(MouseEvent.MOUSE_OVER, onMouseOverFun);
if (GameInfo.cnversion == false){
mc.removeEventListener(Event.ENTER_FRAME, achievementHandle);
};
}
private function achievementHandle(_arg1:Event):void{
if (_debug){
if (_keyOld.isKeyDownOnce("a")){
SpilSystem.instance.submitAchievement("SHAVENOVICE");
trace("SHAVENOVICE");
};
if (_keyOld.isKeyDownOnce("b")){
SpilSystem.instance.submitAchievement("SCISSORFAN");
trace("SCISSORFAN");
};
if (_keyOld.isKeyDownOnce("c")){
SpilSystem.instance.submitAchievement("SCISSORADDICT");
trace("SCISSORADDICT");
};
if (_keyOld.isKeyDownOnce("d")){
SpilSystem.instance.submitAchievement("SHARPSHAVERN");
trace("SHARPSHAVER");
};
if (_keyOld.isKeyDownOnce("e")){
SpilSystem.instance.submitAchievement("SCISSORMASTER");
trace("SCISSORMASTER");
};
};
}
private function onMouseOverFun(_arg1:MouseEvent):void{
SoundManager.instance.playSound("sound_menu_touch");
}
private function onClickFun(_arg1:MouseEvent):void{
SoundManager.instance.playSound("sound_menu_press");
if (_arg1.target == _startButten){
del();
this.game.dispatchEvent(new Event(Game.Game_Main));
} else {
if (_arg1.target == _howToPlayButten){
del();
this.game.dispatchEvent(new Event(Game.Game_HowToPlay));
} else {
if (_arg1.target == _gameQuality){
if (_gameQuality.currentFrame == 1){
mc.stage.quality = "MEDIUM";
_gameQuality.gotoAndStop(2);
} else {
if (_gameQuality.currentFrame == 2){
mc.stage.quality = "LOW";
_gameQuality.gotoAndStop(3);
} else {
if (_gameQuality.currentFrame == 3){
mc.stage.quality = "HIGH";
_gameQuality.gotoAndStop(1);
};
};
};
} else {
if (_arg1.target == _highScoresButten){
Random.geturl();
trace("WOW");
} else {
if (_arg1.target == _soundBtn){
if (_soundBtn.currentFrame == 1){
SoundManager.instance.switchSound();
_soundBtn.gotoAndStop(2);
} else {
SoundManager.instance.switchSound();
_soundBtn.gotoAndStop(1);
};
} else {
if (_arg1.target == _musicBtn){
if (_musicBtn.currentFrame == 1){
SoundManager.instance.switchMusic();
_musicBtn.gotoAndStop(2);
} else {
SoundManager.instance.switchMusic();
_musicBtn.gotoAndStop(1);
SoundManager.instance.playMusic("music_main_menu");
};
};
};
};
};
};
};
}
}
}//package code.ui
Section 18
//SpilDomain (code.ui.SpilDomain)
package code.ui {
import flash.net.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
public class SpilDomain {
private const URL:String = "http://www8.agame.com/games/sitelock/sites.xml";
private var xml:XML;
private var loader:URLLoader;
private var request:URLRequest;
private var _status:int;// = -1
private var checkURL:String;
private var frameObj:Sprite;
private var jumpFunc:Function;
public function SpilDomain(){
initialize();
}
public function loadXML():void{
loader.load(request);
addEvt(loader, IOErrorEvent.IO_ERROR, onError);
addEvt(loader, Event.COMPLETE, onComplete);
}
public function set urlCheck(_arg1:String):void{
checkURL = _arg1;
}
public function get status():int{
return (_status);
}
public function startCheck(_arg1:Function):void{
jumpFunc = _arg1;
frameObj = new Sprite();
addEvt(frameObj, Event.ENTER_FRAME, enterFrame);
}
public function debug(_arg1:Sprite):void{
var _local2:TextField = new TextField();
_local2.width = 400;
_local2.height = 100;
_arg1.addChild(_local2);
_local2.x = 100;
_local2.y = 50;
_local2.textColor = 0xFFFFFF;
_local2.text = ("status:" + status);
}
private function checkDomain():int{
var _local1:*;
if (checkURL == null){
return (0);
};
for each (_local1 in xml.item) {
if (checkURL.indexOf(_local1) != -1){
return (1);
};
};
return (0);
}
private function initialize():void{
loader = new URLLoader();
request = new URLRequest(URL);
}
private function onError(_arg1:IOErrorEvent):void{
_status = 0;
loader.close();
del();
}
private function onComplete(_arg1:Event):void{
xml = XML(loader.data);
_status = checkDomain();
del();
}
private function enterFrame(_arg1:Event):void{
trace("enterFrame:", status);
if (_status != -1){
trace("status:", status, "excuted");
if (jumpFunc != null){
jumpFunc();
};
delEvt(frameObj, Event.ENTER_FRAME, enterFrame);
del();
};
}
private function del():void{
delEvt(loader, Event.COMPLETE, onComplete);
delEvt(loader, IOErrorEvent.IO_ERROR, onError);
}
private function addEvt(_arg1:EventDispatcher, _arg2:String, _arg3:Function):void{
_arg1.addEventListener(_arg2, _arg3);
}
private function delEvt(_arg1:EventDispatcher, _arg2:String, _arg3:Function):void{
_arg1.removeEventListener(_arg2, _arg3);
}
}
}//package code.ui
Section 19
//SpilSystem (code.ui.SpilSystem)
package code.ui {
import flash.display.*;
import flash.events.*;
import Spill.Components.*;
public class SpilSystem {
private var _sub:Submitter;
private static var _instance:SpilSystem;
public function SpilSystem(){
_sub = new Submitter();
super();
trace(("sub: " + _sub));
_sub.addEventListener(Event.COMPLETE, SubmiterComponentInitialized);
_sub.addEventListener(IOErrorEvent.IO_ERROR, FailedToLoadSubmitter);
_sub.addEventListener("LoadingFailed", FailedToLoadSubmitter);
}
public function init(_arg1:MovieClip):void{
_sub._O0000Ol01(_arg1, "SHEEPTASTIC", "SHEEPTASTIC.html", 0, "normal", "", 0, 0, 1, true);
}
private function SubmiterComponentInitialized(_arg1:Event):void{
_sub.removeEventListener(Event.COMPLETE, SubmiterComponentInitialized);
_sub.removeEventListener(IOErrorEvent.IO_ERROR, FailedToLoadSubmitter);
_sub.removeEventListener("LoadingFailed", FailedToLoadSubmitter);
trace(_sub._O0Olll0lO());
trace("ScoreLoadSubmitComplete");
}
private function FailedToLoadSubmitter(_arg1:Event):void{
_sub.removeEventListener(Event.COMPLETE, SubmiterComponentInitialized);
_sub.removeEventListener("LoadingFailed", FailedToLoadSubmitter);
_sub.removeEventListener(IOErrorEvent.IO_ERROR, FailedToLoadSubmitter);
trace(_sub._O0Olll0lO());
_sub = null;
trace("Failed to load submitter");
}
public function submitScore(_arg1):void{
if (((_sub) && (_sub._O0Olll0lO()))){
_sub._O01lOO10O(_arg1);
};
}
public function submitAchievement(_arg1):void{
if (((_sub) && (_sub._O0Olll0lO()))){
_sub._O00OOl1Ol(_arg1);
};
}
public function destroy():void{
if (_sub){
_sub.removeEventListener(Event.COMPLETE, SubmiterComponentInitialized);
_sub.removeEventListener("LoadingFailed", FailedToLoadSubmitter);
_sub.removeEventListener(IOErrorEvent.IO_ERROR, FailedToLoadSubmitter);
_sub = null;
};
}
public static function get instance():SpilSystem{
if (_instance == null){
_instance = new (SpilSystem);
};
return (_instance);
}
}
}//package code.ui
Section 20
//UI (code.ui.UI)
package code.ui {
import flash.display.*;
import code.*;
import flash.text.*;
import code.tool.*;
public class UI {
private var _game:Game;
private var _manager:Manager;
private var __Pmc:Sprite;
private var __mc:Sprite;
public function UI(){
_game = Game.instance;
_manager = Manager.instance;
__Pmc = _manager.mc;
super();
}
public function del():void{
removeEvent();
removeMC();
}
protected function init():void{
initMC();
initEvent();
}
protected function initMC():void{
}
protected function setMC(_arg1:String, _arg2:Number=0, _arg3:Number=0):void{
__mc = Attach.instance.getSprite(_arg1);
__mc.x = _arg2;
__mc.y = _arg3;
__Pmc.addChild(__mc);
}
protected function getTxtChild(_arg1:Sprite, _arg2:String, _arg3:Boolean=false, _arg4:Boolean=false):TextField{
var _local6:TextFormat;
var _local5:TextField = (_arg1.getChildByName(_arg2) as TextField);
_local5.selectable = _arg3;
if (_arg4){
_local6 = _local5.defaultTextFormat;
_local6.font = "MS Gothic";
_local5.setTextFormat(_local6);
};
return (_arg1[_arg2]);
}
protected function getBtnChild(_arg1:Sprite, _arg2:String, _arg3:Boolean=false):Sprite{
var _local4:Sprite = (_arg1.getChildByName(_arg2) as Sprite);
if (_arg3){
} else {
_local4.buttonMode = true;
_local4.mouseChildren = false;
};
return (_arg1[_arg2]);
}
protected function removeMC():void{
__mc.parent.removeChild(__mc);
__mc = null;
}
protected function initEvent():void{
}
protected function removeEvent():void{
}
public function get game():Game{
return (_game);
}
public function get manager():Manager{
return (_manager);
}
public function get pmc():Sprite{
return (__Pmc);
}
public function get mc():Sprite{
return (__mc);
}
}
}//package code.ui
Section 21
//Game (code.Game)
package code {
import flash.display.*;
import flash.events.*;
import code.tool.*;
public class Game extends EventDispatcher {
public const gameTimer:Number = 2;
public const stageWidth:Number = 640;
public const stageHeight:Number = 480;
public const sheepInitNum:Number = 8;
public const sheepSpeed:Number = 10;
public const vspeed:Number = 5;
private var __mc:DisplayObjectContainer;
public var scores:Number;// = 0
public var sheepNum:Number;// = 0
public var playerName:String;// = ""
public static const Game_Start:String = "gameStart";
public static const Game_Loading:String = "gameLoading";
public static const Game_Loading_Complete:String = "gameLoadingComplete";
public static const Game_Menu:String = "gameMenu";
public static const Game_Menu_Remove:String = "gameMenuRemove";
public static const Game_Main:String = "gameMain";
public static const Game_Main_Remove:String = "gameMainRemove";
public static const Game_HowToPlay:String = "gameHowToPlay";
public static const Game_HowToPlay_Remove:String = "gameHowToPlayRemove";
public static const Game_HighScores:String = "gameHighScores";
public static const Game_HighScores_Remove:String = "gameHighScores";
public static const Game_Over:String = "gameOver";
public static const Game_Win:String = "gameWin";
public static const Game_Continue:String = "GameContinue";
public static const Game_Paush:String = "gamePaush";
public static const Game_LevelPass:String = "gameLevelPass";
public static const Game_LevelPass_Remove:String = "gameLevelPassRemove";
private static var _instance:Game;
public function set gameCon(_arg1:DisplayObjectContainer):void{
__mc = _arg1;
new StageSetting(__mc);
}
public function get gameCon():DisplayObjectContainer{
return (__mc);
}
public static function get instance():Game{
if (_instance == null){
_instance = new (Game);
};
return (_instance);
}
}
}//package code
Section 22
//Manager (code.Manager)
package code {
import flash.display.*;
import flash.events.*;
import code.ui.*;
import com.google.analytics.*;
import zlong.data.*;
import com.lisong.Application.*;
import flash.ui.*;
public class Manager {
public var tracker:AnalyticsTracker;
private var _game:Game;
private var __mc:Sprite;
private var _loader:Loading;
private var _app:AppDoc;
public var highScoreComponent;
public var _googleMenu:Boolean;
public var _googleWin:Boolean;
public var _google7level:Boolean;
private static var _instance:Manager;
public function Manager():void{
_game = Game.instance;
super();
}
public function init(_arg1:DisplayObjectContainer):void{
_game.gameCon = _arg1;
__mc = new Sprite();
_arg1.addChild(__mc);
initEvents();
_game.dispatchEvent(new Event(Game.Game_Loading));
if (GameInfo.cnversion == false){
tracker = new GATracker(_arg1, "UA-6695967-1", "AS3", false);
};
}
private function initEvents():void{
_game.addEventListener(Game.Game_Loading, onLoaderFun);
_game.addEventListener(Game.Game_Loading_Complete, onLoaderCompleteFun);
_game.addEventListener(Game.Game_Menu, onMenuFun);
_game.addEventListener(Game.Game_Main, onMainFun);
_game.addEventListener(Game.Game_Main_Remove, onMainRemoveFun);
_game.addEventListener(Game.Game_HighScores, onHighScoresFun);
_game.addEventListener(Game.Game_HowToPlay, onHowToPlayFun);
_game.addEventListener(Game.Game_Over, onGameOverFun);
_game.addEventListener(Game.Game_Win, onGameWinFun);
_game.addEventListener(Game.Game_LevelPass, onLevelPassFun);
}
private function onLevelPassFun(_arg1:Event):void{
new LevelPass();
}
private function onMainRemoveFun(_arg1:Event):void{
__mc.removeChild(_app);
_app = null;
}
private function onGameOverFun(_arg1:Event):void{
Mouse.show();
new GameOver();
}
private function onGameWinFun(_arg1:Event):void{
Mouse.show();
new GameWin();
}
private function onHowToPlayFun(_arg1:Event):void{
new HowToPlay();
}
private function onHighScoresFun(_arg1:Event):void{
new HighScores();
}
private function onLoaderCompleteFun(_arg1:Event):void{
_loader.del();
_loader = null;
onMenuFun();
}
private function onMainFun(_arg1:Event):void{
_app = new AppDoc();
__mc.addChild(_app);
}
private function onMenuFun(_arg1:Event=null):void{
new Menu();
}
private function onLoaderFun(_arg1:Event):void{
_loader = new Loading();
}
public function get mc():Sprite{
return (__mc);
}
public static function get instance():Manager{
if (_instance == null){
_instance = new (Manager);
};
return (_instance);
}
}
}//package code
Section 23
//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 24
//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"
}
}//package com.google.analytics.campaign
Section 25
//CampaignManager (com.google.analytics.campaign.CampaignManager)
package com.google.analytics.campaign {
import com.google.analytics.core.*;
import com.google.analytics.v4.*;
import com.google.analytics.debug.*;
import com.google.analytics.utils.*;
public class CampaignManager {
private var _config:Configuration;
private var _domainHash:Number;
private var _debug:DebugConfiguration;
private var _timeStamp:Number;
private var _referrer:String;
private var _buffer:Buffer;
public static const trackingDelimiter:String = "|";
public function CampaignManager(_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 26
//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(_arg1:String="", _arg2:String="", _arg3:String="", _arg4:String="", _arg5:String="", _arg6:String="", _arg7:String=""){
this.id = _arg1;
this.source = _arg2;
this.clickId = _arg3;
this.name = _arg4;
this.medium = _arg5;
this.term = _arg6;
this.content = _arg7;
}
public function isValid():Boolean{
if (((((!((id == ""))) || (!((source == ""))))) || (!((clickId == ""))))){
return (true);
};
return (false);
}
public function toTrackerString():String{
var _local1:Array = [];
_addIfNotEmpty(_local1, "utmcsr=", source);
_addIfNotEmpty(_local1, "utmccn=", name);
_addIfNotEmpty(_local1, "utmcmd=", medium);
_addIfNotEmpty(_local1, "utmctr=", term);
_addIfNotEmpty(_local1, "utmcct=", content);
_addIfNotEmpty(_local1, "utmcid=", id);
_addIfNotEmpty(_local1, "utmgclid=", clickId);
return (_local1.join(CampaignManager.trackingDelimiter));
}
private function _addIfNotEmpty(_arg1:Array, _arg2:String, _arg3:String):void{
if (_arg3 != ""){
_arg3 = _arg3.split("+").join("%20");
_arg3 = _arg3.split(" ").join("%20");
_arg1.push((_arg2 + _arg3));
};
}
public function fromTrackerString(_arg1:String):void{
var _local2:String = _arg1.split(CampaignManager.trackingDelimiter).join("&");
var _local3:Variables = new Variables(_local2);
if (_local3.hasOwnProperty("utmcid")){
this.id = _local3["utmcid"];
};
if (_local3.hasOwnProperty("utmcsr")){
this.source = _local3["utmcsr"];
};
if (_local3.hasOwnProperty("utmccn")){
this.name = _local3["utmccn"];
};
if (_local3.hasOwnProperty("utmcmd")){
this.medium = _local3["utmcmd"];
};
if (_local3.hasOwnProperty("utmctr")){
this.term = _local3["utmctr"];
};
if (_local3.hasOwnProperty("utmcct")){
this.content = _local3["utmcct"];
};
if (_local3.hasOwnProperty("utmgclid")){
this.clickId = _local3["utmgclid"];
};
}
}
}//package com.google.analytics.campaign
Section 27
//FlashTracker (com.google.analytics.components.FlashTracker)
package com.google.analytics.components {
import com.google.analytics.core.*;
import com.google.analytics.v4.*;
import com.google.analytics.debug.*;
import com.google.analytics.utils.*;
import flash.display.*;
import flash.events.*;
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 28
//GATrackerLibrary (com.google.analytics.components.GATrackerLibrary)
package com.google.analytics.components {
import com.google.analytics.utils.*;
import flash.display.*;
import com.google.analytics.*;
public class GATrackerLibrary extends MovieClip {
public static var version:Version = API.version;
}
}//package com.google.analytics.components
Section 29
//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 30
//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 31
//Buffer (com.google.analytics.core.Buffer)
package com.google.analytics.core {
import com.google.analytics.v4.*;
import com.google.analytics.debug.*;
import flash.net.*;
import flash.events.*;
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(_arg1:Configuration, _arg2:DebugConfiguration, _arg3:Boolean=false, _arg4:Object=null){
var _local5:Boolean;
var _local6:String;
super();
_config = _arg1;
_debug = _arg2;
UTMB.defaultTimespan = _config.sessionTimeout;
UTMZ.defaultTimespan = _config.conversionTimeout;
if (!_arg3){
_SO = SharedObject.getLocal(_config.cookieName, _config.cookiePath);
_local5 = 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();
_local5 = 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();
_local5 = true;
};
};
if (_SO.data.utmc){
delete _SO.data.utmc;
_local5 = 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();
_local5 = 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();
_local5 = true;
};
};
if (_local5){
save();
};
} else {
_OBJ = new Object();
if (_arg4){
for (_local6 in _arg4) {
_OBJ[_local6] = _arg4[_local6];
};
};
};
_volatile = _arg3;
}
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;
try {
flushStatus = _SO.flush();
} catch(e:Error) {
_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 _local1 = "";
_local1 = (_local1 + utma.valueOf());
_local1 = (_local1 + utmb.valueOf());
_local1 = (_local1 + utmc.valueOf());
_local1 = (_local1 + utmz.valueOf());
_local1 = (_local1 + utmv.valueOf());
return (Utils.generateHash(_local1));
}
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(_arg1:NetStatusEvent):void{
_debug.info("User closed permission dialog...");
switch (_arg1.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(_arg1:Number):void{
if (_debug.verbose){
_debug.info((("updateUTMA( " + _arg1) + " )"), VisualDebugMode.advanced);
};
if (!utma.isEmpty()){
if (isNaN(utma.sessionCount)){
utma.sessionCount = 1;
} else {
utma.sessionCount = (utma.sessionCount + 1);
};
utma.lastTime = utma.currentTime;
utma.currentTime = _arg1;
};
}
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(_arg1:String, _arg2):void{
if (isVolatile()){
_OBJ[_arg1] = _arg2;
} else {
_SO.data[_arg1] = _arg2;
};
}
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 32
//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 33
//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(_arg1:DomainNameMode=null, _arg2:String="", _arg3:DebugConfiguration=null){
_debug = _arg3;
if (_arg1 == null){
_arg1 = DomainNameMode.auto;
};
_mode = _arg1;
if (_arg1 == DomainNameMode.custom){
this.name = _arg2;
} else {
_name = _arg2;
};
}
public function get mode():DomainNameMode{
return (_mode);
}
public function set mode(_arg1:DomainNameMode):void{
_mode = _arg1;
if (_mode == DomainNameMode.none){
_name = "";
};
}
public function get name():String{
return (_name);
}
public function set name(_arg1:String):void{
if (((!((_arg1.charAt(0) == "."))) && (_debug))){
_debug.warning(("missing leading period \".\", cookie will only be accessible on " + _arg1), VisualDebugMode.geek);
};
_name = _arg1;
}
}
}//package com.google.analytics.core
Section 34
//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 35
//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 36
//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 37
//ga_internal (com.google.analytics.core.ga_internal)
package com.google.analytics.core {
public namespace ga_internal;
}//package com.google.analytics.core
Section 38
//GIFRequest (com.google.analytics.core.GIFRequest)
package com.google.analytics.core {
import com.google.analytics.v4.*;
import com.google.analytics.debug.*;
import flash.net.*;
import com.google.analytics.utils.*;
import flash.display.*;
import flash.events.*;
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(_arg1:Configuration, _arg2:DebugConfiguration, _arg3:Buffer, _arg4:Environment){
_config = _arg1;
_debug = _arg2;
_buffer = _arg3;
_info = _arg4;
_count = 0;
_alertcount = 0;
_requests = [];
}
public function get utmn():String{
return ((Utils.generate32bitRandom() as String));
}
public function onIOError(_arg1:IOErrorEvent):void{
var _local2:String = _lastRequest.url;
var _local3:String = String((_requests.length - 1));
var _local4 = (("Gif Request #" + _local3) + " failed");
if (_debug.GIFRequests){
if (!_debug.verbose){
if (_local2.indexOf("?") > -1){
_local2 = _local2.split("?")[0];
};
_local2 = _shortenURL(_local2);
};
if (int(_debug.mode) > int(VisualDebugMode.basic)){
_local4 = (_local4 + ((" \"" + _local2) + "\" does not exists or is unreachable"));
};
_debug.failure(_local4);
} else {
_debug.warning(_local4);
};
_removeListeners(_arg1.target);
}
public function send(_arg1:String, _arg2:Variables=null, _arg3:Boolean=false, _arg4:Boolean=false):void{
var _local5:String;
var _local6:URLRequest;
var _local7:URLRequest;
_utmac = _arg1;
if (!_arg2){
_arg2 = new Variables();
};
_arg2.URIencode = false;
_arg2.pre = ["utmwv", "utmn", "utmhn", "utmt", "utme", "utmcs", "utmsr", "utmsc", "utmul", "utmje", "utmfl", "utmdt", "utmhid", "utmr", "utmp"];
_arg2.post = ["utmcc"];
if (_debug.verbose){
_debug.info(((("tracking: " + _buffer.utmb.trackCount) + "/") + _config.trackingLimitPerSession), VisualDebugMode.geek);
};
if ((((_buffer.utmb.trackCount < _config.trackingLimitPerSession)) || (_arg3))){
if (_arg4){
updateToken();
};
if (((((_arg3) || (!(_arg4)))) || ((_buffer.utmb.token >= 1)))){
if (((!(_arg3)) && (_arg4))){
_buffer.utmb.token = (_buffer.utmb.token - 1);
};
_buffer.utmb.trackCount = (_buffer.utmb.trackCount + 1);
if (_debug.verbose){
_debug.info(_buffer.utmb.toString(), VisualDebugMode.geek);
};
_arg2.utmwv = utmwv;
_arg2.utmn = Utils.generate32bitRandom();
if (_info.domainName != ""){
_arg2.utmhn = _info.domainName;
};
if (_config.sampleRate < 1){
_arg2.utmsp = (_config.sampleRate * 100);
};
if ((((_config.serverMode == ServerOperationMode.local)) || ((_config.serverMode == ServerOperationMode.both)))){
_local5 = _info.locationSWFPath;
if (_local5.lastIndexOf("/") > 0){
_local5 = _local5.substring(0, _local5.lastIndexOf("/"));
};
_local6 = new URLRequest();
if (_config.localGIFpath.indexOf("http") == 0){
_local6.url = _config.localGIFpath;
} else {
_local6.url = (_local5 + _config.localGIFpath);
};
_local6.url = (_local6.url + ("?" + _arg2.toString()));
if (((_debug.active) && (_debug.GIFRequests))){
_debugSend(_local6);
} else {
sendRequest(_local6);
};
};
if ((((_config.serverMode == ServerOperationMode.remote)) || ((_config.serverMode == ServerOperationMode.both)))){
_local7 = new URLRequest();
if (_info.protocol == Protocols.HTTPS){
_local7.url = _config.secureRemoteGIFpath;
} else {
if (_info.protocol == Protocols.HTTP){
_local7.url = _config.remoteGIFpath;
} else {
_local7.url = _config.remoteGIFpath;
};
};
_arg2.utmac = utmac;
_arg2.utmcc = encodeURIComponent(utmcc);
_local7.url = (_local7.url + ("?" + _arg2.toString()));
if (((_debug.active) && (_debug.GIFRequests))){
_debugSend(_local7);
} else {
sendRequest(_local7);
};
};
};
};
}
public function onSecurityError(_arg1:SecurityErrorEvent):void{
if (_debug.GIFRequests){
_debug.failure(_arg1.text);
};
}
public function get utmsp():String{
return (((_config.sampleRate * 100) as String));
}
public function get utmcc():String{
var _local1:Array = [];
if (_buffer.hasUTMA()){
_local1.push((_buffer.utma.toURLString() + ";"));
};
if (_buffer.hasUTMZ()){
_local1.push((_buffer.utmz.toURLString() + ";"));
};
if (_buffer.hasUTMV()){
_local1.push((_buffer.utmv.toURLString() + ";"));
};
return (_local1.join("+"));
}
public function get utmac():String{
return (_utmac);
}
public function get utmwv():String{
return (_config.version);
}
public function sendRequest(_arg1:URLRequest):void{
var request = _arg1;
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);
try {
loader.load(request, context);
} catch(e:Error) {
_debug.failure("\"Loader.load()\" could not instanciate Gif Request");
};
}
private function _removeListeners(_arg1:Object):void{
_arg1.removeEventListener(IOErrorEvent.IO_ERROR, onIOError);
_arg1.removeEventListener(Event.COMPLETE, onComplete);
}
public function updateToken():void{
var _local2:Number;
var _local1:Number = new Date().getTime();
_local2 = ((_local1 - _buffer.utmb.lastTime) * (_config.tokenRate / 1000));
if (_debug.verbose){
_debug.info(("tokenDelta: " + _local2), VisualDebugMode.geek);
};
if (_local2 >= 1){
_buffer.utmb.token = Math.min(Math.floor((_buffer.utmb.token + _local2)), _config.bucketCapacity);
_buffer.utmb.lastTime = _local1;
if (_debug.verbose){
_debug.info(_buffer.utmb.toString(), VisualDebugMode.geek);
};
};
}
public function get utmhn():String{
return (_info.domainName);
}
private function _shortenURL(_arg1:String):String{
var _local2:Array;
if (_arg1.length > 60){
_local2 = _arg1.split("/");
while (_arg1.length > 60) {
_local2.shift();
_arg1 = ("../" + _local2.join("/"));
};
};
return (_arg1);
}
private function _debugSend(_arg1:URLRequest):void{
var _local3:String;
var _local2 = "";
switch (_debug.mode){
case VisualDebugMode.geek:
_local2 = ((("Gif Request #" + _alertcount) + ":\n") + _arg1.url);
break;
case VisualDebugMode.advanced:
_local3 = _arg1.url;
if (_local3.indexOf("?") > -1){
_local3 = _local3.split("?")[0];
};
_local3 = _shortenURL(_local3);
_local2 = (((("Send Gif Request #" + _alertcount) + ":\n") + _local3) + " ?");
break;
case VisualDebugMode.basic:
default:
_local2 = (((("Send " + _config.serverMode.toString()) + " Gif Request #") + _alertcount) + " ?");
};
_debug.alertGifRequest(_local2, _arg1, this);
_alertcount++;
}
public function onComplete(_arg1:Event):void{
var _local2:String = _arg1.target.loader.name;
_requests[_local2].complete();
var _local3 = (("Gif Request #" + _local2) + " sent");
var _local4:String = _requests[_local2].request.url;
if (_debug.GIFRequests){
if (!_debug.verbose){
if (_local4.indexOf("?") > -1){
_local4 = _local4.split("?")[0];
};
_local4 = _shortenURL(_local4);
};
if (int(_debug.mode) > int(VisualDebugMode.basic)){
_local3 = (_local3 + ((" to \"" + _local4) + "\""));
};
_debug.success(_local3);
} else {
_debug.info(_local3);
};
_removeListeners(_arg1.target);
}
}
}//package com.google.analytics.core
Section 39
//IdleTimer (com.google.analytics.core.IdleTimer)
package com.google.analytics.core {
import com.google.analytics.v4.*;
import com.google.analytics.debug.*;
import flash.display.*;
import flash.events.*;
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 40
//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 41
//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 42
//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 43
//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(_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 44
//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(_arg1:GoogleAnalyticsAPI=null){
this.tracker = _arg1;
_ar = [];
}
public function size():uint{
return (_ar.length);
}
public function flush():void{
var _local1:Object;
var _local2:String;
var _local3:Array;
var _local4:int;
var _local5:int;
if (tracker == null){
return;
};
if (size() > 0){
_local4 = _ar.length;
while (_local5 < _local4) {
_local1 = _ar.shift();
_local2 = (_local1.name as String);
_local3 = (_local1.args as Array);
if (((!((_local2 == null))) && ((_local2 in tracker)))){
(tracker[_local2] as Function).apply(tracker, _local3);
};
_local5++;
};
};
}
public function enqueue(_arg1:String, ... _args):Boolean{
if (_arg1 == null){
return (false);
};
_ar.push({name:_arg1, args:_args});
return (true);
}
public function link(_arg1:String, _arg2:Boolean=false):void{
enqueue("link", _arg1, _arg2);
}
public function addOrganic(_arg1:String, _arg2:String):void{
enqueue("addOrganic", _arg1, _arg2);
}
public function setAllowLinker(_arg1:Boolean):void{
enqueue("setAllowLinker", _arg1);
}
public function trackEvent(_arg1:String, _arg2:String, _arg3:String=null, _arg4:Number=NaN):Boolean{
enqueue("trackEvent", _arg1, _arg2, _arg3, _arg4);
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(_arg1:String=""):void{
enqueue("trackPageview", _arg1);
}
public function setClientInfo(_arg1:Boolean):void{
enqueue("setClientInfo", _arg1);
}
public function linkByPost(_arg1:Object, _arg2:Boolean=false):void{
enqueue("linkByPost", _arg1, _arg2);
}
public function setCookieTimeout(_arg1:int):void{
enqueue("setCookieTimeout", _arg1);
}
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(_arg1:Boolean):void{
enqueue("setDetectFlash", _arg1);
}
public function clear():void{
_ar = [];
}
public function setCampNameKey(_arg1:String):void{
enqueue("setCampNameKey", _arg1);
}
public function addItem(_arg1:String, _arg2:String, _arg3:String, _arg4:String, _arg5:Number, _arg6:int):void{
enqueue("addItem", _arg1, _arg2, _arg3, _arg4, _arg5, _arg6);
}
public function createEventTracker(_arg1: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(_arg1:String):void{
enqueue("setVar", _arg1);
}
public function clearIgnoredOrganic():void{
enqueue("clearIgnoredOrganic");
}
public function setDomainName(_arg1:String):void{
enqueue("setDomainName", _arg1);
}
public function setCampSourceKey(_arg1:String):void{
enqueue("setCampSourceKey", _arg1);
}
public function addTrans(_arg1:String, _arg2:String, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:String, _arg7:String, _arg8: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(_arg1:String):void{
enqueue("setCampContentKey", _arg1);
}
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(_arg1:Boolean):void{
enqueue("setAllowAnchor", _arg1);
}
public function clearIgnoredRef():void{
enqueue("clearIgnoredRef");
}
public function setLocalGifPath(_arg1:String):void{
enqueue("setLocalGifPath", _arg1);
}
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(_arg1:String):void{
enqueue("setCookiePath", _arg1);
}
public function setSampleRate(_arg1:Number):void{
enqueue("setSampleRate", _arg1);
}
public function setDetectTitle(_arg1:Boolean):void{
enqueue("setDetectTitle", _arg1);
}
public function setAllowHash(_arg1:Boolean):void{
enqueue("setAllowHash", _arg1);
}
public function addIgnoredOrganic(_arg1:String):void{
enqueue("addIgnoredOrganic", _arg1);
}
public function setCampNOKey(_arg1:String):void{
enqueue("setCampNOKey", _arg1);
}
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(_arg1:String):void{
enqueue("cookiePathCopy", _arg1);
}
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(_arg1:Boolean):void{
enqueue("setCampaignTrack", _arg1);
}
public function clearOrganic():void{
enqueue("clearOrganic");
}
public function setCampTermKey(_arg1:String):void{
enqueue("setCampTermKey", _arg1);
}
public function addIgnoredRef(_arg1:String):void{
enqueue("addIgnoredRef", _arg1);
}
public function setCampMediumKey(_arg1:String):void{
enqueue("setCampMediumKey", _arg1);
}
public function setSessionTimeout(_arg1:int):void{
enqueue("setSessionTimeout", _arg1);
}
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 45
//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 46
//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 47
//Cookie (com.google.analytics.data.Cookie)
package com.google.analytics.data {
public interface Cookie {
function fromSharedObject(_arg1:Object):void;
function toURLString():String;
function get creation():Date;
function toSharedObject():Object;
function isExpired():Boolean;
function set creation(_arg1:Date):void;
function set expiration(_arg1:Date):void;
function get expiration():Date;
}
}//package com.google.analytics.data
Section 48
//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(_arg1:Number=NaN, _arg2:Number=NaN, _arg3:Number=NaN, _arg4:Number=NaN, _arg5:Number=NaN, _arg6:Number=NaN){
super("utma", "__utma", ["domainHash", "sessionId", "firstTime", "lastTime", "currentTime", "sessionCount"], (Timespan.twoyears * 1000));
this.domainHash = _arg1;
this.sessionId = _arg2;
this.firstTime = _arg3;
this.lastTime = _arg4;
this.currentTime = _arg5;
this.sessionCount = _arg6;
}
public function get lastTime():Number{
return (_lastTime);
}
public function set lastTime(_arg1:Number):void{
_lastTime = _arg1;
update();
}
public function set currentTime(_arg1:Number):void{
_currentTime = _arg1;
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(_arg1:Number):void{
_domainHash = _arg1;
update();
}
public function set sessionId(_arg1:Number):void{
_sessionId = _arg1;
update();
}
public function set sessionCount(_arg1:Number):void{
_sessionCount = _arg1;
update();
}
public function get domainHash():Number{
return (_domainHash);
}
public function set firstTime(_arg1:Number):void{
_firstTime = _arg1;
update();
}
}
}//package com.google.analytics.data
Section 49
//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(_arg1:Number=NaN, _arg2:Number=NaN, _arg3:Number=NaN, _arg4:Number=NaN){
super("utmb", "__utmb", ["domainHash", "trackCount", "token", "lastTime"], (defaultTimespan * 1000));
this.domainHash = _arg1;
this.trackCount = _arg2;
this.token = _arg3;
this.lastTime = _arg4;
}
public function set token(_arg1:Number):void{
_token = _arg1;
update();
}
public function set trackCount(_arg1:Number):void{
_trackCount = _arg1;
update();
}
public function get lastTime():Number{
return (_lastTime);
}
public function set domainHash(_arg1:Number):void{
_domainHash = _arg1;
update();
}
public function set lastTime(_arg1:Number):void{
_lastTime = _arg1;
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 50
//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 51
//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 52
//UTMK (com.google.analytics.data.UTMK)
package com.google.analytics.data {
public class UTMK extends UTMCookie {
private var _hash:Number;
public function UTMK(_arg1:Number=NaN){
super("utmk", "__utmk", ["hash"]);
this.hash = _arg1;
}
public function set hash(_arg1:Number):void{
_hash = _arg1;
update();
}
public function get hash():Number{
return (_hash);
}
}
}//package com.google.analytics.data
Section 53
//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(_arg1:Number=NaN, _arg2:String=""){
super("utmv", "__utmv", ["domainHash", "value"], (Timespan.twoyears * 1000));
this.domainHash = _arg1;
this.value = _arg2;
}
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(_arg1:Number):void{
_domainHash = _arg1;
update();
}
public function set value(_arg1:String):void{
_value = _arg1;
update();
}
}
}//package com.google.analytics.data
Section 54
//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(_arg1:Number=NaN, _arg2:Number=NaN, _arg3:Number=NaN, _arg4:Number=NaN, _arg5:String=""){
super("utmz", "__utmz", ["domainHash", "campaignCreation", "campaignSessions", "responseCount", "campaignTracking"], (defaultTimespan * 1000));
this.domainHash = _arg1;
this.campaignCreation = _arg2;
this.campaignSessions = _arg3;
this.responseCount = _arg4;
this.campaignTracking = _arg5;
}
public function set responseCount(_arg1:Number):void{
_responseCount = _arg1;
update();
}
public function set domainHash(_arg1:Number):void{
_domainHash = _arg1;
update();
}
public function set campaignCreation(_arg1:Number):void{
_campaignCreation = _arg1;
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(_arg1:Number):void{
_campaignSessions = _arg1;
update();
}
public function set campaignTracking(_arg1:String):void{
_campaignTracking = _arg1;
update();
}
}
}//package com.google.analytics.data
Section 55
//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 56
//_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 57
//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 58
//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 59
//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 60
//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 61
//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(_arg1:uint=0, _arg2:Align=null, _arg3:Boolean=false){
if (_arg2 == null){
_arg2 = Align.bottom;
};
super("", "uiLabel", _arg1, _arg2, _arg3);
this.name = ("Debug" + count++);
_lines = [];
selectable = true;
addEventListener(KeyboardEvent.KEY_DOWN, onKey);
}
public function writeBold(_arg1:String):void{
write(_arg1, true);
}
private function _getLinesToDisplay(_arg1:int=0):Array{
var _local2:Array;
var _local3:uint;
var _local4:uint;
if ((_lines.length - 1) > maxLines){
if ((_linediff <= 0)){
_linediff = (_linediff + _arg1);
} else {
if ((((_linediff > 0)) && ((_arg1 < 0)))){
_linediff = (_linediff + _arg1);
};
};
_local3 = ((_lines.length - maxLines) + _linediff);
_local4 = (_local3 + maxLines);
_local2 = _lines.slice(_local3, _local4);
} else {
_local2 = _lines;
};
return (_local2);
}
private function onKey(_arg1:KeyboardEvent=null):void{
var _local2:Array;
switch (_arg1.keyCode){
case Keyboard.DOWN:
_local2 = _getLinesToDisplay(1);
break;
case Keyboard.UP:
_local2 = _getLinesToDisplay(-1);
break;
default:
_local2 = null;
};
if (_local2 == null){
return;
};
text = _local2.join("\n");
}
override public function get forcedWidth():uint{
if (this.parent){
if (UISprite(this.parent).forcedWidth > _preferredForcedWidth){
return (_preferredForcedWidth);
};
return (UISprite(this.parent).forcedWidth);
//unresolved jump
};
return (super.forcedWidth);
}
public function write(_arg1:String, _arg2:Boolean=false):void{
var _local3:Array;
if (_arg1.indexOf("") > -1){
_local3 = _arg1.split("\n");
} else {
_local3 = [_arg1];
};
var _local4 = "";
var _local5 = "";
if (_arg2){
_local4 = "<b>";
_local5 = "</b>";
};
var _local6:int;
while (_local6 < _local3.length) {
_lines.push(((_local4 + _local3[_local6]) + _local5));
_local6++;
};
var _local7:Array = _getLinesToDisplay();
text = _local7.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 62
//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(_arg1:Boolean):void{
_verbose = _arg1;
}
public function set mode(_arg1):void{
if ((_arg1 is String)){
switch (_arg1){
case "geek":
_arg1 = VisualDebugMode.geek;
break;
case "advanced":
_arg1 = VisualDebugMode.advanced;
break;
case "basic":
default:
_arg1 = VisualDebugMode.basic;
};
};
_mode = _arg1;
}
public function success(_arg1:String):void{
if (layout){
layout.createSuccessAlert(_arg1);
};
if (traceOutput){
trace((("[+] " + _arg1) + " !!"));
};
}
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(_arg1:String, _arg2:VisualDebugMode=null):void{
if (_filter(_arg2)){
return;
};
if (((layout) && (showWarnings))){
layout.createWarning(_arg1);
};
if (traceOutput){
trace((("## " + _arg1) + " ##"));
};
}
private function _filter(_arg1:VisualDebugMode=null):Boolean{
return (((_arg1) && ((int(_arg1) >= int(this.mode)))));
}
public function failure(_arg1:String):void{
if (layout){
layout.createFailureAlert(_arg1);
};
if (traceOutput){
trace((("[-] " + _arg1) + " !!"));
};
}
public function get mode(){
return (_mode);
}
public function set active(_arg1:Boolean):void{
_active = _arg1;
if (_active){
_initializeVisual();
} else {
_destroyVisual();
};
}
protected function trace(_arg1:String):void{
var _local7:Array;
var _local8:int;
var _local2:Array = [];
var _local3 = "";
var _local4 = "";
if (this.mode == VisualDebugMode.geek){
_local3 = (getTimer() + " - ");
_local4 = (new Array(_local3.length).join(" ") + " ");
};
if (_arg1.indexOf("\n") > -1){
_local7 = _arg1.split("\n");
_local8 = 0;
while (_local8 < _local7.length) {
if (_local7[_local8] == ""){
} else {
if (_local8 == 0){
_local2.push((_local3 + _local7[_local8]));
} else {
_local2.push((_local4 + _local7[_local8]));
};
};
_local8++;
};
} else {
_local2.push((_local3 + _arg1));
};
var _local5:int = _local2.length;
var _local6:int;
while (_local6 < _local5) {
trace(_local2[_local6]);
_local6++;
};
}
public function alert(_arg1:String):void{
if (layout){
layout.createAlert(_arg1);
};
if (traceOutput){
trace((("!! " + _arg1) + " !!"));
};
}
public function info(_arg1:String, _arg2:VisualDebugMode=null):void{
if (_filter(_arg2)){
return;
};
if (((layout) && (showInfos))){
layout.createInfo(_arg1);
};
if (traceOutput){
trace(_arg1);
};
}
public function alertGifRequest(_arg1:String, _arg2:URLRequest, _arg3:GIFRequest):void{
if (layout){
layout.createGIFRequestAlert(_arg1, _arg2, _arg3);
};
if (traceOutput){
trace(((">> " + _arg1) + " <<"));
};
}
}
}//package com.google.analytics.debug
Section 63
//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 64
//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 65
//ILayout (com.google.analytics.debug.ILayout)
package com.google.analytics.debug {
import com.google.analytics.core.*;
import flash.net.*;
import flash.display.*;
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 66
//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 67
//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(_arg1:String="", _arg2:String="uiLabel", _arg3:uint=0, _arg4:Align=null, _arg5:Boolean=false){
this.name = ("Label" + count++);
selectable = false;
_background = new Shape();
_textField = new TextField();
_text = _arg1;
_tag = _arg2;
if (_arg4 == null){
_arg4 = Align.none;
};
this.alignement = _arg4;
this.stickToEdge = _arg5;
if (_arg3 == 0){
_arg3 = Style.backgroundColor;
};
_color = _arg3;
_textField.addEventListener(TextEvent.LINK, onLink);
}
public function get tag():String{
return (_tag);
}
private function _draw():void{
var _local1:Graphics = _background.graphics;
_local1.clear();
_local1.beginFill(_color);
var _local2:uint = _textField.width;
var _local3:uint = _textField.height;
if (forcedWidth > 0){
_local2 = forcedWidth;
};
Background.drawRounded(this, _local1, _local2, _local3);
_local1.endFill();
}
public function get text():String{
return (_textField.text);
}
public function appendText(_arg1:String, _arg2:String=""):void{
if (_arg1 == ""){
return;
};
if (_arg2 == ""){
_arg2 = tag;
};
_textField.htmlText = (_textField.htmlText + (((("<span class=\"" + _arg2) + "\">") + _arg1) + "</span>"));
_text = (_text + _arg1);
_draw();
resize();
}
public function set text(_arg1:String):void{
if (_arg1 == ""){
_arg1 = _text;
};
_textField.htmlText = (((("<span class=\"" + tag) + "\">") + _arg1) + "</span>");
_text = _arg1;
_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(_arg1:String):void{
_tag = _arg1;
text = "";
}
public function onLink(_arg1:TextEvent):void{
}
override protected function dispose():void{
_textField.removeEventListener(TextEvent.LINK, onLink);
super.dispose();
}
}
}//package com.google.analytics.debug
Section 68
//Layout (com.google.analytics.debug.Layout)
package com.google.analytics.debug {
import com.google.analytics.core.*;
import flash.net.*;
import flash.display.*;
import flash.events.*;
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(_arg1:DebugConfiguration, _arg2:DisplayObject){
_display = _arg2;
_debug = _arg1;
_hasWarning = false;
_hasInfo = false;
_hasDebug = false;
_hasGRAlert = false;
_warningQueue = [];
_infoQueue = [];
_GRAlertQueue = [];
}
private function onKey(_arg1:KeyboardEvent=null):void{
switch (_arg1.keyCode){
case _debug.showHideKey:
_mainPanel.visible = !(_mainPanel.visible);
break;
case _debug.destroyKey:
destroy();
break;
};
}
public function createWarning(_arg1:String):void{
if (((_hasWarning) || (!(isAvailable())))){
_warningQueue.push(_arg1);
return;
};
_arg1 = _filterMaxChars(_arg1);
_hasWarning = true;
var _local2:Warning = new Warning(_arg1, _debug.warningTimeout);
addToPanel("analytics", _local2);
_local2.addEventListener(Event.REMOVED_FROM_STAGE, _clearWarning, false, 0, true);
if (_hasDebug){
visualDebug.writeBold(_arg1);
};
}
public function bringToFront(_arg1:DisplayObject):void{
_display.stage.setChildIndex(_arg1, (_display.stage.numChildren - 1));
}
public function createFailureAlert(_arg1:String):void{
var _local2:AlertAction;
if (_debug.verbose){
_arg1 = _filterMaxChars(_arg1);
_local2 = new AlertAction("Close", "close", "close");
} else {
_local2 = new AlertAction("X", "close", "close");
};
var _local3:Alert = new FailureAlert(_debug, _arg1, [_local2]);
addToPanel("analytics", _local3);
if (_hasDebug){
if (_debug.verbose){
_arg1 = _arg1.split("\n").join("");
_arg1 = _filterMaxChars(_arg1, 66);
};
visualDebug.writeBold(_arg1);
};
}
public function init():void{
var _local1 = 10;
var _local2:uint = (_display.stage.stageWidth - (_local1 * 2));
var _local3:uint = (_display.stage.stageHeight - (_local1 * 2));
var _local4:Panel = new Panel("analytics", _local2, _local3);
_local4.alignement = Align.top;
_local4.stickToEdge = false;
_local4.title = ("Google Analytics v" + GATracker.version);
_mainPanel = _local4;
addToStage(_local4);
bringToFront(_local4);
if (_debug.minimizedOnStart){
_mainPanel.onToggle();
};
createVisualDebug();
_display.stage.addEventListener(KeyboardEvent.KEY_DOWN, onKey, false, 0, true);
}
public function addToPanel(_arg1:String, _arg2:DisplayObject):void{
var _local4:Panel;
var _local3:DisplayObject = _display.stage.getChildByName(_arg1);
if (_local3){
_local4 = (_local3 as Panel);
_local4.addData(_arg2);
} else {
trace((("panel \"" + _arg1) + "\" not found"));
};
}
private function _clearInfo(_arg1:Event):void{
_hasInfo = false;
if (_infoQueue.length > 0){
createInfo(_infoQueue.shift());
};
}
private function _filterMaxChars(_arg1:String, _arg2:int=0):String{
var _local6:String;
var _local3 = "\n";
var _local4:Array = [];
var _local5:Array = _arg1.split(_local3);
if (_arg2 == 0){
_arg2 = _maxCharPerLine;
};
var _local7:int;
while (_local7 < _local5.length) {
_local6 = _local5[_local7];
while (_local6.length > _arg2) {
_local4.push(_local6.substr(0, _arg2));
_local6 = _local6.substring(_arg2);
};
_local4.push(_local6);
_local7++;
};
return (_local4.join(_local3));
}
private function _clearGRAlert(_arg1:Event):void{
_hasGRAlert = false;
if (_GRAlertQueue.length > 0){
createGIFRequestAlert.apply(this, _GRAlertQueue.shift());
};
}
public function createSuccessAlert(_arg1:String):void{
var _local2:AlertAction;
if (_debug.verbose){
_arg1 = _filterMaxChars(_arg1);
_local2 = new AlertAction("Close", "close", "close");
} else {
_local2 = new AlertAction("X", "close", "close");
};
var _local3:Alert = new SuccessAlert(_debug, _arg1, [_local2]);
addToPanel("analytics", _local3);
if (_hasDebug){
if (_debug.verbose){
_arg1 = _arg1.split("\n").join("");
_arg1 = _filterMaxChars(_arg1, 66);
};
visualDebug.writeBold(_arg1);
};
}
public function isAvailable():Boolean{
return (!((_display.stage == null)));
}
public function createAlert(_arg1:String):void{
_arg1 = _filterMaxChars(_arg1);
var _local2:Alert = new Alert(_arg1, [new AlertAction("Close", "close", "close")]);
addToPanel("analytics", _local2);
if (_hasDebug){
visualDebug.writeBold(_arg1);
};
}
public function createInfo(_arg1:String):void{
if (((_hasInfo) || (!(isAvailable())))){
_infoQueue.push(_arg1);
return;
};
_arg1 = _filterMaxChars(_arg1);
_hasInfo = true;
var _local2:Info = new Info(_arg1, _debug.infoTimeout);
addToPanel("analytics", _local2);
_local2.addEventListener(Event.REMOVED_FROM_STAGE, _clearInfo, false, 0, true);
if (_hasDebug){
visualDebug.write(_arg1);
};
}
public function createGIFRequestAlert(_arg1:String, _arg2:URLRequest, _arg3:GIFRequest):void{
var message = _arg1;
var request = _arg2;
var ref = _arg3;
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(_arg1:DisplayObject):void{
_display.stage.addChild(_arg1);
}
private function _clearWarning(_arg1:Event):void{
_hasWarning = false;
if (_warningQueue.length > 0){
createWarning(_warningQueue.shift());
};
}
public function createPanel(_arg1:String, _arg2:uint, _arg3:uint):void{
var _local4:Panel = new Panel(_arg1, _arg2, _arg3);
_local4.alignement = Align.center;
_local4.stickToEdge = false;
addToStage(_local4);
bringToFront(_local4);
}
public function destroy():void{
_mainPanel.close();
_debug.layout = null;
}
}
}//package com.google.analytics.debug
Section 69
//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 70
//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(_arg1:String, _arg2:uint, _arg3:uint, _arg4:uint=0, _arg5:uint=0, _arg6:Number=0.3, _arg7:Align=null, _arg8:Boolean=false){
_name = _arg1;
this.name = _arg1;
this.mouseEnabled = false;
_colapsed = false;
forcedWidth = _arg2;
forcedHeight = _arg3;
this.baseAlpha = _arg6;
_background = new Shape();
_data = new UISprite();
_data.forcedWidth = _arg2;
_data.forcedHeight = _arg3;
_data.mouseEnabled = false;
_title = new Label(_arg1, "uiLabel", 0xFFFFFF, Align.topLeft, _arg8);
_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 (_arg7 == null){
_arg7 = Align.none;
};
this.alignement = _arg7;
this.stickToEdge = _arg8;
if (_arg4 == 0){
_arg4 = Style.backgroundColor;
};
_backgroundColor = _arg4;
if (_arg5 == 0){
_arg5 = Style.borderColor;
};
_borderColor = _arg5;
}
public function get stickToEdge():Boolean{
return (_stickToEdge);
}
public function onToggle(_arg1:MouseEvent=null):void{
if (_colapsed){
_data.visible = true;
} else {
_data.visible = false;
};
_colapsed = !(_colapsed);
_update();
resize();
}
public function set stickToEdge(_arg1:Boolean):void{
_stickToEdge = _arg1;
_title.stickToEdge = _arg1;
}
override protected function dispose():void{
_title.removeEventListener(MouseEvent.CLICK, onToggle);
super.dispose();
}
private function _draw():void{
var _local1:uint;
var _local2:uint;
if (((_savedW) && (_savedH))){
forcedWidth = _savedW;
forcedHeight = _savedH;
};
if (!_colapsed){
_local1 = forcedWidth;
_local2 = forcedHeight;
} else {
_local1 = _title.width;
_local2 = _title.height;
_savedW = forcedWidth;
_savedH = forcedHeight;
forcedWidth = _local1;
forcedHeight = _local2;
};
var _local3:Graphics = _background.graphics;
_local3.clear();
_local3.beginFill(_backgroundColor);
Background.drawRounded(this, _local3, _local1, _local2);
_local3.endFill();
var _local4:Graphics = _data.graphics;
_local4.clear();
_local4.beginFill(_backgroundColor, 0);
Background.drawRounded(this, _local4, _local1, _local2);
_local4.endFill();
var _local5:Graphics = _border.graphics;
_local5.clear();
_local5.lineStyle(0.1, _borderColor);
Background.drawRounded(this, _local5, _local1, _local2);
_local5.endFill();
var _local6:Graphics = _mask.graphics;
_local6.clear();
_local6.beginFill(_backgroundColor);
Background.drawRounded(this, _local6, (_local1 + 1), (_local2 + 1));
_local6.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(_arg1:DisplayObject):void{
_data.addChild(_arg1);
}
override protected function layout():void{
_update();
addChild(_background);
addChild(_data);
addChild(_title);
addChild(_border);
addChild(_mask);
mask = _mask;
}
public function set title(_arg1:String):void{
_title.text = _arg1;
}
public function close():void{
dispose();
if (parent != null){
parent.removeChild(this);
};
}
}
}//package com.google.analytics.debug
Section 71
//Style (com.google.analytics.debug.Style)
package com.google.analytics.debug {
public const Style:_Style = new _Style();
}//package com.google.analytics.debug
Section 72
//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 73
//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 74
//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 75
//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 76
//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 77
//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 78
//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 79
//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 80
//Environment (com.google.analytics.utils.Environment)
package com.google.analytics.utils {
import com.google.analytics.core.*;
import com.google.analytics.debug.*;
import com.google.analytics.external.*;
import flash.system.*;
public class Environment {
private var _dom:HTMLDOM;
private var _appName:String;
private var _debug:DebugConfiguration;
private var _appVersion:Version;
private var _url:String;
private var _protocol:Protocols;
private var _userAgent:UserAgent;
public function Environment(_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 81
//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 82
//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;
}
}//package com.google.analytics.utils
Section 83
//URL (com.google.analytics.utils.URL)
package com.google.analytics.utils {
public class URL {
private var _url:String;
public function URL(_arg1:String=""){
_url = _arg1.toLowerCase();
}
public function get domain():String{
var _local1:Array;
if (((!((hostName == ""))) && ((hostName.indexOf(".") > -1)))){
_local1 = hostName.split(".");
switch (_local1.length){
case 2:
return (hostName);
case 3:
if (_local1[1] == "co"){
return (hostName);
};
_local1.shift();
return (_local1.join("."));
case 4:
_local1.shift();
return (_local1.join("."));
};
};
return ("");
}
public function get path():String{
var _local1:String = _url;
if (_local1.indexOf("://") > -1){
_local1 = _local1.split("://")[1];
};
if (_local1.indexOf(hostName) == 0){
_local1 = _local1.substr(hostName.length);
};
if (_local1.indexOf("?") > -1){
_local1 = _local1.split("?")[0];
};
if (_local1.charAt(0) != "/"){
_local1 = ("/" + _local1);
};
return (_local1);
}
public function get protocol():Protocols{
var _local1:String = _url.split("://")[0];
switch (_local1){
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 _local1:String = _url;
if (_local1.indexOf("://") > -1){
_local1 = _local1.split("://")[1];
};
if (_local1.indexOf("/") > -1){
_local1 = _local1.split("/")[0];
};
if (_local1.indexOf("?") > -1){
_local1 = _local1.split("?")[0];
};
if ((((protocol == Protocols.file)) || ((protocol == Protocols.none)))){
return ("");
};
return (_local1);
}
public function get subDomain():String{
if (((!((domain == ""))) && (!((domain == hostName))))){
return (hostName.split(("." + domain)).join(""));
};
return ("");
}
public function get search():String{
var _local1:String = _url;
if (_local1.indexOf("://") > -1){
_local1 = _local1.split("://")[1];
};
if (_local1.indexOf(hostName) == 0){
_local1 = _local1.substr(hostName.length);
};
if (_local1.indexOf("?") > -1){
_local1 = _local1.split("?")[1];
} else {
_local1 = "";
};
return (_local1);
}
}
}//package com.google.analytics.utils
Section 84
//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 85
//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(_arg1:String=null, _arg2:Array=null, _arg3:Array=null){
pre = [];
post = [];
super();
if (_arg1){
decode(_arg1);
};
if (_arg2){
this.pre = _arg2;
};
if (_arg3){
this.post = _arg3;
};
}
private function _join(_arg1:Variables):void{
var _local2:String;
if (!_arg1){
return;
};
for (_local2 in _arg1) {
this[_local2] = _arg1[_local2];
};
}
public function join(... _args):void{
var _local2:int = _args.length;
var _local3:int;
while (_local3 < _local2) {
if (!(_args[_local3] is Variables)){
} else {
_join(_args[_local3]);
};
_local3++;
};
}
public function toString():String{
var _local2:String;
var _local3:String;
var _local4:String;
var _local5:int;
var _local6:int;
var _local7:String;
var _local8:String;
var _local1:Array = [];
for (_local3 in this) {
_local2 = this[_local3];
if (URIencode){
_local2 = encodeURI(_local2);
};
_local1.push(((_local3 + "=") + _local2));
};
if (sort){
_local1.sort();
};
if (pre.length > 0){
pre.reverse();
_local5 = 0;
while (_local5 < pre.length) {
_local7 = pre[_local5];
_local6 = 0;
while (_local6 < _local1.length) {
_local4 = _local1[_local6];
if (_local4.indexOf(_local7) == 0){
_local1.unshift(_local1.splice(_local6, 1)[0]);
};
_local6++;
};
_local5++;
};
pre.reverse();
};
if (post.length > 0){
_local5 = 0;
while (_local5 < post.length) {
_local8 = post[_local5];
_local6 = 0;
while (_local6 < _local1.length) {
_local4 = _local1[_local6];
if (_local4.indexOf(_local8) == 0){
_local1.push(_local1.splice(_local6, 1)[0]);
};
_local6++;
};
_local5++;
};
};
return (_local1.join("&"));
}
public function decode(_arg1:String):void{
var _local2:Array;
var _local3:String;
var _local4:String;
var _local5:String;
var _local6:Array;
if (_arg1 == ""){
return;
};
if (_arg1.indexOf("&") > -1){
_local2 = _arg1.split("&");
} else {
_local2 = [_arg1];
};
var _local7:int;
while (_local7 < _local2.length) {
_local3 = _local2[_local7];
if (_local3.indexOf("=") > -1){
_local6 = _local3.split("=");
_local4 = _local6[0];
_local5 = decodeURI(_local6[1]);
this[_local4] = _local5;
};
_local7++;
};
}
public function toURLVariables():URLVariables{
var _local2:String;
var _local1:URLVariables = new URLVariables();
for (_local2 in this) {
_local1[_local2] = this[_local2];
};
return (_local1);
}
}
}//package com.google.analytics.utils
Section 86
//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 87
//Bridge (com.google.analytics.v4.Bridge)
package com.google.analytics.v4 {
import com.google.analytics.core.*;
import com.google.analytics.debug.*;
import com.google.analytics.external.*;
public class Bridge implements GoogleAnalyticsAPI {
private var _debug:DebugConfiguration;
private var _proxy:JavascriptProxy;
private var _jsContainer:String;// = "_GATracker"
private var _hasGATracker:Boolean;// = false
private var _account:String;
private static var _linkTrackingObject_js:XML = <script>
<![CDATA[
function( container , target )
{
var targets ;
var name ;
if( target.indexOf(".") > 0 )
{
targets = target.split(".");
name = targets.pop();
}
else
{
targets = [];
name = target;
}
var ref = window;
var depth = targets.length;
for( var j = 0 ; j < depth ; j++ )
{
ref = ref[ targets[j] ] ;
}
window[container][target] = ref[name] ;
}
]]>
</script>
;
private static var _createTrackingObject_js:XML = <script>
<![CDATA[
function( acct )
{
_GATracker[acct] = _gat._getTracker(acct);
}
]]>
</script>
;
private static var _injectTrackingObject_js:XML = <script>
<![CDATA[
function()
{
try
{
_GATracker
}
catch(e)
{
_GATracker = {};
}
}
]]>
</script>
;
private static var _checkGAJS_js:XML = <script>
<![CDATA[
function()
{
if( _gat && _gat._getTracker )
{
return true;
}
return false;
}
]]>
</script>
;
private static var _checkValidTrackingObject_js:XML = <script>
<![CDATA[
function(acct)
{
if( _GATracker[acct] && (_GATracker[acct]._getAccount) )
{
return true ;
}
else
{
return false;
}
}
]]>
</script>
;
public function Bridge(_arg1:String, _arg2:DebugConfiguration, _arg3:JavascriptProxy){
var _local4:String;
var _local5:String;
var _local6:String;
super();
_account = _arg1;
_debug = _arg2;
_proxy = _arg3;
if (!_checkGAJS()){
_local4 = "";
_local4 = (_local4 + "ga.js not found, be sure to check if\n");
_local4 = (_local4 + "<script src=\"http://www.google-analytics.com/ga.js\"></script>\n");
_local4 = (_local4 + "is included in the HTML.");
_debug.warning(_local4);
throw (new Error(_local4));
};
if (!_hasGATracker){
if (((_debug.javascript) && (_debug.verbose))){
_local5 = "";
_local5 = (_local5 + "The Google Analytics tracking code was not found on the container page\n");
_local5 = (_local5 + "we create it");
_debug.info(_local5, VisualDebugMode.advanced);
};
_injectTrackingObject();
};
if (Utils.validateAccount(_arg1)){
_createTrackingObject(_arg1);
} else {
if (_checkTrackingObject(_arg1)){
_linkTrackingObject(_arg1);
} else {
_local6 = "";
_local6 = (_local6 + (("JS Object \"" + _arg1) + "\" doesn't exist in DOM\n"));
_local6 = (_local6 + "Bridge object not created.");
_debug.warning(_local6);
throw (new Error(_local6));
};
};
}
public function link(_arg1:String, _arg2:Boolean=false):void{
_debug.info((((("link( " + _arg1) + ", ") + _arg2) + " )"));
_call("_link", _arg1, _arg2);
}
public function addOrganic(_arg1:String, _arg2:String):void{
_debug.info((("addOrganic( " + [_arg1, _arg2].join(", ")) + " )"));
_call("_addOrganic", _arg1);
}
public function setAllowLinker(_arg1:Boolean):void{
_debug.info((("setAllowLinker( " + _arg1) + " )"));
_call("_setAllowLinker", _arg1);
}
private function _linkTrackingObject(_arg1:String):void{
_proxy.call(_linkTrackingObject_js, _jsContainer, _arg1);
}
public function trackEvent(_arg1:String, _arg2:String, _arg3:String=null, _arg4:Number=NaN):Boolean{
var _local5 = 2;
if (((_arg3) && (!((_arg3 == ""))))){
_local5 = 3;
};
if ((((_local5 == 3)) && (!(isNaN(_arg4))))){
_local5 = 4;
};
switch (_local5){
case 4:
_debug.info((("trackEvent( " + [_arg1, _arg2, _arg3, _arg4].join(", ")) + " )"));
return (_call("_trackEvent", _arg1, _arg2, _arg3, _arg4));
case 3:
_debug.info((("trackEvent( " + [_arg1, _arg2, _arg3].join(", ")) + " )"));
return (_call("_trackEvent", _arg1, _arg2, _arg3));
case 2:
default:
_debug.info((("trackEvent( " + [_arg1, _arg2].join(", ")) + " )"));
return (_call("_trackEvent", _arg1, _arg2));
};
}
public function setClientInfo(_arg1:Boolean):void{
_debug.info((("setClientInfo( " + _arg1) + " )"));
_call("_setClientInfo", _arg1);
}
public function trackTrans():void{
_debug.info("trackTrans()");
_call("_trackTrans");
}
public function setCookieTimeout(_arg1:int):void{
_debug.info((("setCookieTimeout( " + _arg1) + " )"));
_call("_setCookieTimeout", _arg1);
}
public function trackPageview(_arg1:String=""):void{
_debug.info((("trackPageview( " + _arg1) + " )"));
_call("_trackPageview", _arg1);
}
public function getClientInfo():Boolean{
_debug.info("getClientInfo()");
return (_call("_getClientInfo"));
}
private function _checkValidTrackingObject(_arg1:String):Boolean{
return (_proxy.call(_checkValidTrackingObject_js, _arg1));
}
private function _checkGAJS():Boolean{
return (_proxy.call(_checkGAJS_js));
}
public function linkByPost(_arg1:Object, _arg2:Boolean=false):void{
_debug.warning((((("linkByPost( " + _arg1) + ", ") + _arg2) + " ) not implemented"));
}
private function _call(_arg1:String, ... _args){
_args.unshift(((((("window." + _jsContainer) + "[\"") + _account) + "\"].") + _arg1));
return (_proxy.call.apply(_proxy, _args));
}
public function hasGAJS():Boolean{
return (_checkGAJS());
}
private function _checkTrackingObject(_arg1:String):Boolean{
var _local2:Boolean = _proxy.hasProperty(_arg1);
var _local3:Boolean = _proxy.hasProperty((_arg1 + "._getAccount"));
return (((_local2) && (_local3)));
}
public function resetSession():void{
_debug.warning("resetSession() not implemented");
}
public function getDetectTitle():Boolean{
_debug.info("getDetectTitle()");
return (_call("_getDetectTitle"));
}
public function setCampNameKey(_arg1:String):void{
_debug.info((("setCampNameKey( " + _arg1) + " )"));
_call("_setCampNameKey", _arg1);
}
public function setDetectFlash(_arg1:Boolean):void{
_debug.info((("setDetectFlash( " + _arg1) + " )"));
_call("_setDetectFlash", _arg1);
}
public function createEventTracker(_arg1:String):EventTracker{
_debug.info((("createEventTracker( " + _arg1) + " )"));
return (new EventTracker(_arg1, this));
}
public function addItem(_arg1:String, _arg2:String, _arg3:String, _arg4:String, _arg5:Number, _arg6:int):void{
_debug.info((("addItem( " + [_arg1, _arg2, _arg3, _arg4, _arg5, _arg6].join(", ")) + " )"));
_call("_addItem", _arg1, _arg2, _arg3, _arg4, _arg5, _arg6);
}
public function clearIgnoredOrganic():void{
_debug.info("clearIgnoredOrganic()");
_call("_clearIgnoreOrganic");
}
public function setVar(_arg1:String):void{
_debug.info((("setVar( " + _arg1) + " )"));
_call("_setVar", _arg1);
}
public function setDomainName(_arg1:String):void{
_debug.info((("setDomainName( " + _arg1) + " )"));
_call("_setDomainName", _arg1);
}
public function hasTrackingAccount(_arg1:String):Boolean{
if (Utils.validateAccount(_arg1)){
return (_checkValidTrackingObject(_arg1));
};
return (_checkTrackingObject(_arg1));
}
public function setCampSourceKey(_arg1:String):void{
_debug.info((("setCampSourceKey( " + _arg1) + " )"));
_call("_setCampSourceKey", _arg1);
}
public function addTrans(_arg1:String, _arg2:String, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:String, _arg7:String, _arg8:String):Object{
_debug.info((("addTrans( " + [_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7, _arg8].join(", ")) + " )"));
_call("_addTrans", _arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7, _arg8);
return (null);
}
public function setCampContentKey(_arg1:String):void{
_debug.info((("setCampContentKey( " + _arg1) + " )"));
_call("_setCampContentKey", _arg1);
}
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(_arg1:Boolean):void{
_debug.info((("setAllowAnchor( " + _arg1) + " )"));
_call("_setAllowAnchor", _arg1);
}
public function setLocalGifPath(_arg1:String):void{
_debug.info((("setLocalGifPath( " + _arg1) + " )"));
_call("_setLocalGifPath", _arg1);
}
public function getVersion():String{
_debug.info("getVersion()");
return (_call("_getVersion"));
}
private function _injectTrackingObject():void{
_proxy.executeBlock(_injectTrackingObject_js);
_hasGATracker = true;
}
public function setCookiePath(_arg1:String):void{
_debug.info((("setCookiePath( " + _arg1) + " )"));
_call("_setCookiePath", _arg1);
}
public function setSampleRate(_arg1:Number):void{
_debug.info((("setSampleRate( " + _arg1) + " )"));
_call("_setSampleRate", _arg1);
}
public function setAllowHash(_arg1:Boolean):void{
_debug.info((("setAllowHash( " + _arg1) + " )"));
_call("_setAllowHash", _arg1);
}
public function addIgnoredOrganic(_arg1:String):void{
_debug.info((("addIgnoredOrganic( " + _arg1) + " )"));
_call("_addIgnoredOrganic", _arg1);
}
public function setCampNOKey(_arg1:String):void{
_debug.info((("setCampNOKey( " + _arg1) + " )"));
_call("_setCampNOKey", _arg1);
}
public function cookiePathCopy(_arg1:String):void{
_debug.info((("cookiePathCopy( " + _arg1) + " )"));
_call("_cookiePathCopy", _arg1);
}
public function setLocalRemoteServerMode():void{
_debug.info("setLocalRemoteServerMode()");
_call("_setLocalRemoteServerMode");
}
public function getServiceMode():ServerOperationMode{
_debug.info("getServiceMode()");
return (_call("_getServiceMode"));
}
public function setDetectTitle(_arg1:Boolean):void{
_debug.info((("setDetectTitle( " + _arg1) + " )"));
_call("_setDetectTitle", _arg1);
}
private function _createTrackingObject(_arg1:String):void{
_proxy.call(_createTrackingObject_js, _arg1);
}
public function setCampaignTrack(_arg1:Boolean):void{
_debug.info((("setCampaignTrack( " + _arg1) + " )"));
_call("_setCampaignTrack", _arg1);
}
public function clearOrganic():void{
_debug.info("clearOrganic()");
_call("_clearOrganic");
}
public function setCampTermKey(_arg1:String):void{
_debug.info((("setCampTermKey( " + _arg1) + " )"));
_call("_setCampTermKey", _arg1);
}
public function getDetectFlash():Boolean{
_debug.info("getDetectFlash()");
return (_call("_getDetectFlash"));
}
public function setCampMediumKey(_arg1:String):void{
_debug.info((("setCampMediumKey( " + _arg1) + " )"));
_call("_setCampMediumKey", _arg1);
}
public function addIgnoredRef(_arg1:String):void{
_debug.info((("addIgnoredRef( " + _arg1) + " )"));
_call("_addIgnoredRef", _arg1);
}
public function setSessionTimeout(_arg1:int):void{
_debug.info((("setSessionTimeout( " + _arg1) + " )"));
_call("_setSessionTimeout", _arg1);
}
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 88
//Configuration (com.google.analytics.v4.Configuration)
package com.google.analytics.v4 {
import com.google.analytics.core.*;
import com.google.analytics.debug.*;
import com.google.analytics.utils.*;
import com.google.analytics.campaign.*;
public class Configuration {
public var serverMode:ServerOperationMode;
public var detectFlash:Boolean;// = true
public var allowLocalTracking:Boolean;// = true
public var secureRemoteGIFpath:String;// = "https://ssl.google-analytics.com/__utm.gif"
public var hasSiteOverlay:Boolean;// = false
private var _version:String;// = "4.3as"
public var allowDomainHash:Boolean;// = true
public var detectClientInfo:Boolean;// = true
public var idleLoop:Number;// = 30
public var isTrackOutboundSubdomains:Boolean;// = false
public var cookiePath:String;// = "/"
public var transactionFieldDelim:String;// = "|"
private var _organic:Organic;
private var _cookieName:String;// = "analytics"
public var campaignKey:CampaignKey;
public var google:String;// = "google"
public var googleCsePath:String;// = "cse"
public var bucketCapacity:Number;// = 10
private var _sampleRate:Number;// = 1
public var remoteGIFpath:String;// = "http://www.google-analytics.com/__utm.gif"
public var googleSearchParam:String;// = "q"
public var allowLinker:Boolean;// = false
public var maxOutboundLinkExamined:Number;// = 1000
private var _debug:DebugConfiguration;
private var _trackingLimitPerSession:int;// = 500
private var _domain:Domain;
public var allowAnchor:Boolean;// = false
public var tokenCliff:int;// = 10
public var sessionTimeout:Number;
public var idleTimeout:Number;// = 60
public var campaignTracking:Boolean;// = true
public var domainName:String;// = ""
public var detectTitle:Boolean;// = true
public var tokenRate:Number;// = 0.2
public var conversionTimeout:Number;
public var localGIFpath:String;// = "/__utm.gif"
public function Configuration(_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 89
//GoogleAnalyticsAPI (com.google.analytics.v4.GoogleAnalyticsAPI)
package com.google.analytics.v4 {
import com.google.analytics.core.*;
public interface GoogleAnalyticsAPI {
function setCampSourceKey(_arg1:String):void;
function getServiceMode():ServerOperationMode;
function resetSession():void;
function setLocalServerMode():void;
function setCampContentKey(_arg1:String):void;
function addOrganic(_arg1:String, _arg2:String):void;
function setDetectFlash(_arg1: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(_arg1:String):void;
function setCampNameKey(_arg1:String):void;
function addIgnoredOrganic(_arg1:String):void;
function addItem(_arg1:String, _arg2:String, _arg3:String, _arg4:String, _arg5:Number, _arg6:int):void;
function setAllowLinker(_arg1:Boolean):void;
function getClientInfo():Boolean;
function getDetectFlash():Boolean;
function setCampaignTrack(_arg1:Boolean):void;
function createEventTracker(_arg1:String):EventTracker;
function setCookieTimeout(_arg1:int):void;
function setAllowAnchor(_arg1:Boolean):void;
function trackTrans():void;
function clearOrganic():void;
function trackPageview(_arg1:String=""):void;
function setLocalGifPath(_arg1:String):void;
function getVersion():String;
function getLocalGifPath():String;
function setVar(_arg1:String):void;
function clearIgnoredOrganic():void;
function setCampMediumKey(_arg1:String):void;
function addIgnoredRef(_arg1:String):void;
function setClientInfo(_arg1:Boolean):void;
function setCookiePath(_arg1:String):void;
function setSampleRate(_arg1:Number):void;
function setSessionTimeout(_arg1:int):void;
function setRemoteServerMode():void;
function clearIgnoredRef():void;
function setDomainName(_arg1:String):void;
function setDetectTitle(_arg1:Boolean):void;
function setAllowHash(_arg1:Boolean):void;
function getAccount():String;
function linkByPost(_arg1:Object, _arg2:Boolean=false):void;
function link(_arg1:String, _arg2:Boolean=false):void;
function setCampNOKey(_arg1:String):void;
function setLocalRemoteServerMode():void;
function cookiePathCopy(_arg1:String):void;
function getDetectTitle():Boolean;
}
}//package com.google.analytics.v4
Section 90
//Tracker (com.google.analytics.v4.Tracker)
package com.google.analytics.v4 {
import com.google.analytics.core.*;
import com.google.analytics.debug.*;
import com.google.analytics.utils.*;
import com.google.analytics.data.*;
import com.google.analytics.external.*;
import com.google.analytics.campaign.*;
public class Tracker implements GoogleAnalyticsAPI {
private const EVENT_TRACKER_LABEL_KEY_NUM:int = 3;
private const EVENT_TRACKER_VALUE_VALUE_NUM:int = 1;
private const EVENT_TRACKER_PROJECT_ID:int = 5;
private const EVENT_TRACKER_OBJECT_NAME_KEY_NUM:int = 1;
private const EVENT_TRACKER_TYPE_KEY_NUM:int = 2;
private var _adSense:AdSenseGlobals;
private var _eventTracker:X10;
private var _noSessionInformation:Boolean;// = false
private var _browserInfo:BrowserInfo;
private var _debug:DebugConfiguration;
private var _isNewVisitor:Boolean;// = false
private var _buffer:Buffer;
private var _config:Configuration;
private var _x10Module:X10;
private var _campaign:CampaignManager;
private var _formatedReferrer:String;
private var _timeStamp:Number;
private var _info:Environment;
private var _domainHash:Number;
private var _campaignInfo:CampaignInfo;
private var _gifRequest:GIFRequest;
private var _hasInitData:Boolean;// = false
private var _account:String;
public function Tracker(_arg1:String, _arg2:Configuration, _arg3:DebugConfiguration, _arg4:Environment, _arg5:Buffer, _arg6:GIFRequest, _arg7:AdSenseGlobals){
var _local8:String;
super();
_account = _arg1;
_config = _arg2;
_debug = _arg3;
_info = _arg4;
_buffer = _arg5;
_gifRequest = _arg6;
_adSense = _arg7;
if (!Utils.validateAccount(_arg1)){
_local8 = (("Account \"" + _arg1) + "\" is not valid.");
_debug.warning(_local8);
throw (new Error(_local8));
};
_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(_arg1:String, _arg2:String):void{
_debug.info((("addOrganic( " + [_arg1, _arg2].join(", ")) + " )"));
_config.organic.addSource(_arg1, _arg2);
}
public function setAllowLinker(_arg1:Boolean):void{
_config.allowLinker = _arg1;
_debug.info((("setAllowLinker( " + _config.allowLinker) + " )"));
}
public function trackEvent(_arg1:String, _arg2:String, _arg3:String=null, _arg4:Number=NaN):Boolean{
var _local5:Boolean;
var _local6 = 2;
if (((!((_arg1 == ""))) && (!((_arg2 == ""))))){
_eventTracker.clearKey(EVENT_TRACKER_PROJECT_ID);
_eventTracker.clearValue(EVENT_TRACKER_PROJECT_ID);
_local5 = _eventTracker.setKey(EVENT_TRACKER_PROJECT_ID, EVENT_TRACKER_OBJECT_NAME_KEY_NUM, _arg1);
_local5 = _eventTracker.setKey(EVENT_TRACKER_PROJECT_ID, EVENT_TRACKER_TYPE_KEY_NUM, _arg2);
if (((_arg3) && (!((_arg3 == ""))))){
_local5 = _eventTracker.setKey(EVENT_TRACKER_PROJECT_ID, EVENT_TRACKER_LABEL_KEY_NUM, _arg3);
_local6 = 3;
if (!isNaN(_arg4)){
_local5 = _eventTracker.setValue(EVENT_TRACKER_PROJECT_ID, EVENT_TRACKER_VALUE_VALUE_NUM, _arg4);
_local6 = 4;
};
};
if (_local5){
_debug.info(((("valid event tracking call\ncategory: " + _arg1) + "\naction: ") + _arg2), VisualDebugMode.geek);
_sendXEvent(_eventTracker);
};
} else {
_debug.warning(((("event tracking call is not valid, failed!\ncategory: " + _arg1) + "\naction: ") + _arg2), VisualDebugMode.geek);
_local5 = false;
};
switch (_local6){
case 4:
_debug.info((("trackEvent( " + [_arg1, _arg2, _arg3, _arg4].join(", ")) + " )"));
break;
case 3:
_debug.info((("trackEvent( " + [_arg1, _arg2, _arg3].join(", ")) + " )"));
break;
case 2:
default:
_debug.info((("trackEvent( " + [_arg1, _arg2].join(", ")) + " )"));
};
return (_local5);
}
public function trackPageview(_arg1:String=""):void{
_debug.info((("trackPageview( " + _arg1) + " )"));
if (_doTracking()){
_initData();
_trackMetrics(_arg1);
_noSessionInformation = false;
} else {
_debug.warning((("trackPageview( " + _arg1) + " ) failed"));
};
}
public function setCookieTimeout(_arg1:int):void{
_config.conversionTimeout = _arg1;
_debug.info((("setCookieTimeout( " + _config.conversionTimeout) + " )"));
}
public function trackTrans():void{
_debug.warning("trackTrans() not implemented");
}
public function setClientInfo(_arg1:Boolean):void{
_config.detectClientInfo = _arg1;
_debug.info((("setClientInfo( " + _config.detectClientInfo) + " )"));
}
public function linkByPost(_arg1:Object, _arg2:Boolean=false):void{
_debug.warning((("linkByPost( " + [_arg1, _arg2].join(", ")) + " ) not implemented"));
}
private function _initData():void{
var _local1:String;
var _local2:String;
if (!_hasInitData){
_updateDomainName();
_domainHash = _getDomainHash();
_timeStamp = Math.round((new Date().getTime() / 1000));
if (_debug.verbose){
_local1 = "";
_local1 = (_local1 + "_initData 0");
_local1 = (_local1 + ("\ndomain name: " + _config.domainName));
_local1 = (_local1 + ("\ndomain hash: " + _domainHash));
_local1 = (_local1 + (((("\ntimestamp: " + _timeStamp) + " (") + new Date((_timeStamp * 1000))) + ")"));
_debug.info(_local1, 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){
_local2 = "";
_local2 = (_local2 + "_initData (misc)");
_local2 = (_local2 + ("\nflash version: " + _info.flashVersion.toString(4)));
_local2 = (_local2 + ("\nprotocol: " + _info.protocol));
_local2 = (_local2 + (("\ndefault domain name (auto): \"" + _info.domainName) + "\""));
_local2 = (_local2 + ("\nlanguage: " + _info.language));
_local2 = (_local2 + ("\ndomain hash: " + _getDomainHash()));
_local2 = (_local2 + ("\nuser-agent: " + _info.userAgent));
_debug.info(_local2, 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(_arg1:X10=null):void{
var _local2:Variables;
var _local3:EventInfo;
var _local4:Variables;
var _local5:Variables;
_initData();
if (_takeSample()){
_local2 = new Variables();
_local2.URIencode = true;
_local3 = new EventInfo(true, _x10Module, _arg1);
_local4 = _local3.toVariables();
_local5 = _renderMetricsSearchVariables();
_local2.join(_local4, _local5);
_gifRequest.send(_account, _local2, false, true);
};
}
public function setDetectFlash(_arg1:Boolean):void{
_config.detectFlash = _arg1;
_debug.info((("setDetectFlash( " + _config.detectFlash) + " )"));
}
public function setCampNameKey(_arg1:String):void{
_config.campaignKey.UCCN = _arg1;
var _local2 = (("setCampNameKey( " + _config.campaignKey.UCCN) + " )");
if (_debug.mode == VisualDebugMode.geek){
_debug.info((_local2 + " [UCCN]"));
} else {
_debug.info(_local2);
};
}
private function _formatReferrer():String{
var _local2:String;
var _local3:URL;
var _local4:URL;
var _local1:String = _info.referrer;
if ((((_local1 == "")) || ((_local1 == "localhost")))){
_local1 = "-";
} else {
_local2 = _info.domainName;
_local3 = new URL(_local1);
_local4 = new URL(("http://" + _local2));
if (_local3.hostName == _local2){
return ("-");
};
if (_local4.domain == _local3.domain){
if (_local4.subDomain != _local3.subDomain){
_local1 = "0";
};
};
if ((((_local1.charAt(0) == "[")) && (_local1.charAt((_local1.length - 1))))){
_local1 = "-";
};
};
_debug.info(("formated referrer: " + _local1), VisualDebugMode.advanced);
return (_local1);
}
private function _visitCode():Number{
if (_debug.verbose){
_debug.info(("visitCode: " + _buffer.utma.sessionId), VisualDebugMode.geek);
};
return (_buffer.utma.sessionId);
}
public function createEventTracker(_arg1:String):EventTracker{
_debug.info((("createEventTracker( " + _arg1) + " )"));
return (new EventTracker(_arg1, this));
}
public function addItem(_arg1:String, _arg2:String, _arg3:String, _arg4:String, _arg5:Number, _arg6:int):void{
_debug.warning((("addItem( " + [_arg1, _arg2, _arg3, _arg4, _arg5, _arg6].join(", ")) + " ) not implemented"));
}
public function clearIgnoredOrganic():void{
_debug.info("clearIgnoredOrganic()");
_config.organic.clearIgnoredKeywords();
}
public function setVar(_arg1:String):void{
var _local2:Variables;
if (((!((_arg1 == ""))) && (_isNotGoogleSearch()))){
_initData();
_buffer.utmv.domainHash = _domainHash;
_buffer.utmv.value = _arg1;
if (_debug.verbose){
_debug.info(_buffer.utmv.toString(), VisualDebugMode.geek);
};
_debug.info((("setVar( " + _arg1) + " )"));
if (_takeSample()){
_local2 = new Variables();
_local2.utmt = "var";
_gifRequest.send(_account, _local2);
};
} else {
_debug.warning((("setVar \"" + _arg1) + "\" is ignored"));
};
}
public function setDomainName(_arg1:String):void{
if (_arg1 == "auto"){
_config.domain.mode = DomainNameMode.auto;
} else {
if (_arg1 == "none"){
_config.domain.mode = DomainNameMode.none;
} else {
_config.domain.mode = DomainNameMode.custom;
_config.domain.name = _arg1;
};
};
_updateDomainName();
_debug.info((("setDomainName( " + _config.domainName) + " )"));
}
private function _updateDomainName():void{
var _local1:String;
if (_config.domain.mode == DomainNameMode.auto){
_local1 = _info.domainName;
if (_local1.substring(0, 4) == "www."){
_local1 = _local1.substring(4);
};
_config.domain.name = _local1;
};
_config.domainName = _config.domain.name.toLowerCase();
_debug.info(("domain name: " + _config.domainName), VisualDebugMode.advanced);
}
public function addTrans(_arg1:String, _arg2:String, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:String, _arg7:String, _arg8:String):Object{
_debug.warning((("addTrans( " + [_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7, _arg8].join(", ")) + " ) not implemented"));
return (null);
}
private function _renderMetricsSearchVariables(_arg1:String=""):Variables{
var _local4:Variables;
var _local2:Variables = new Variables();
_local2.URIencode = true;
var _local3:DocumentInfo = new DocumentInfo(_config, _info, _formatedReferrer, _arg1, _adSense);
_debug.info(("docInfo: " + _local3.toURLString()), VisualDebugMode.geek);
if (_config.campaignTracking){
_local4 = _campaignInfo.toVariables();
};
var _local5:Variables = _browserInfo.toVariables();
_local2.join(_local3.toVariables(), _local5, _local4);
return (_local2);
}
public function setCampContentKey(_arg1:String):void{
_config.campaignKey.UCCT = _arg1;
var _local2 = (("setCampContentKey( " + _config.campaignKey.UCCT) + " )");
if (_debug.mode == VisualDebugMode.geek){
_debug.info((_local2 + " [UCCT]"));
} else {
_debug.info(_local2);
};
}
private function _handleCookie():void{
var _local1:String;
var _local2:String;
var _local3:Array;
var _local4: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){
_local1 = "";
_local1 = (_local1 + "AdSense sid found\n");
_local1 = (_local1 + (((("Override currentTime(" + _buffer.utma.currentTime) + ") from AdSense sid(") + Number(_adSense.sid)) + ")"));
_debug.info(_local1, VisualDebugMode.geek);
};
};
if (_isNewVisitor){
if (_adSense.sid){
_buffer.utma.lastTime = Number(_adSense.sid);
if (_debug.verbose){
_local2 = "";
_local2 = (_local2 + "AdSense sid found (new visitor)\n");
_local2 = (_local2 + (((("Override lastTime(" + _buffer.utma.lastTime) + ") from AdSense sid(") + Number(_adSense.sid)) + ")"));
_debug.info(_local2, VisualDebugMode.geek);
};
};
if (_adSense.vid){
_local3 = _adSense.vid.split(".");
_buffer.utma.sessionId = Number(_local3[0]);
_buffer.utma.firstTime = Number(_local3[1]);
if (_debug.verbose){
_local4 = "";
_local4 = (_local4 + "AdSense vid found (new visitor)\n");
_local4 = (_local4 + (((("Override sessionId(" + _buffer.utma.sessionId) + ") from AdSense vid(") + Number(_local3[0])) + ")\n"));
_local4 = (_local4 + (((("Override firstTime(" + _buffer.utma.firstTime) + ") from AdSense vid(") + Number(_local3[1])) + ")"));
_debug.info(_local4, 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(_arg1:String):void{
_config.campaignKey.UCSR = _arg1;
var _local2 = (("setCampSourceKey( " + _config.campaignKey.UCSR) + " )");
if (_debug.mode == VisualDebugMode.geek){
_debug.info((_local2 + " [UCSR]"));
} else {
_debug.info(_local2);
};
}
public function getLocalGifPath():String{
_debug.info("getLocalGifPath()");
return (_config.localGIFpath);
}
public function setLocalGifPath(_arg1:String):void{
_config.localGIFpath = _arg1;
_debug.info((("setLocalGifPath( " + _config.localGIFpath) + " )"));
}
public function getVersion():String{
_debug.info("getVersion()");
return (_config.version);
}
public function setAllowAnchor(_arg1:Boolean):void{
_config.allowAnchor = _arg1;
_debug.info((("setAllowAnchor( " + _config.allowAnchor) + " )"));
}
private function _isNotGoogleSearch():Boolean{
var _local1:String = _config.domainName;
var _local2 = (_local1.indexOf("www.google.") < 0);
var _local3 = (_local1.indexOf(".google.") < 0);
var _local4 = (_local1.indexOf("google.") < 0);
var _local5 = (_local1.indexOf("google.org") > -1);
return (((((((((_local2) || (_local3))) || (_local4))) || (!((_config.cookiePath == "/"))))) || (_local5)));
}
public function setSampleRate(_arg1:Number):void{
if (_arg1 < 0){
_debug.warning("sample rate can not be negative, ignoring value.");
} else {
_config.sampleRate = _arg1;
};
_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(_arg1:String):void{
_config.cookiePath = _arg1;
_debug.info((("setCookiePath( " + _config.cookiePath) + " )"));
}
public function setAllowHash(_arg1:Boolean):void{
_config.allowDomainHash = _arg1;
_debug.info((("setAllowHash( " + _config.allowDomainHash) + " )"));
}
private function _generateUserDataHash():Number{
var _local1 = "";
_local1 = (_local1 + _info.appName);
_local1 = (_local1 + _info.appVersion);
_local1 = (_local1 + _info.language);
_local1 = (_local1 + _info.platform);
_local1 = (_local1 + _info.userAgent.toString());
_local1 = (_local1 + (((_info.screenWidth + "x") + _info.screenHeight) + _info.screenColorDepth));
_local1 = (_local1 + _info.referrer);
return (Utils.generateHash(_local1));
}
public function setCampNOKey(_arg1:String):void{
_config.campaignKey.UCNO = _arg1;
var _local2 = (("setCampNOKey( " + _config.campaignKey.UCNO) + " )");
if (_debug.mode == VisualDebugMode.geek){
_debug.info((_local2 + " [UCNO]"));
} else {
_debug.info(_local2);
};
}
public function addIgnoredOrganic(_arg1:String):void{
_debug.info((("addIgnoredOrganic( " + _arg1) + " )"));
_config.organic.addIgnoredKeyword(_arg1);
}
public function setLocalRemoteServerMode():void{
_config.serverMode = ServerOperationMode.both;
_debug.info("setLocalRemoteServerMode()");
}
public function cookiePathCopy(_arg1:String):void{
_debug.warning((("cookiePathCopy( " + _arg1) + " ) not implemented"));
}
public function setDetectTitle(_arg1:Boolean):void{
_config.detectTitle = _arg1;
_debug.info((("setDetectTitle( " + _config.detectTitle) + " )"));
}
public function setCampTermKey(_arg1:String):void{
_config.campaignKey.UCTR = _arg1;
var _local2 = (("setCampTermKey( " + _config.campaignKey.UCTR) + " )");
if (_debug.mode == VisualDebugMode.geek){
_debug.info((_local2 + " [UCTR]"));
} else {
_debug.info(_local2);
};
}
public function getServiceMode():ServerOperationMode{
_debug.info("getServiceMode()");
return (_config.serverMode);
}
private function _trackMetrics(_arg1:String=""):void{
var _local2:Variables;
var _local3:Variables;
var _local4:Variables;
var _local5:EventInfo;
if (_takeSample()){
_local2 = new Variables();
_local2.URIencode = true;
if (((_x10Module) && (_x10Module.hasData()))){
_local5 = new EventInfo(false, _x10Module);
_local3 = _local5.toVariables();
};
_local4 = _renderMetricsSearchVariables(_arg1);
_local2.join(_local3, _local4);
_gifRequest.send(_account, _local2);
};
}
public function setCampaignTrack(_arg1:Boolean):void{
_config.campaignTracking = _arg1;
_debug.info((("setCampaignTrack( " + _config.campaignTracking) + " )"));
}
public function addIgnoredRef(_arg1:String):void{
_debug.info((("addIgnoredRef( " + _arg1) + " )"));
_config.organic.addIgnoredReferral(_arg1);
}
public function clearOrganic():void{
_debug.info("clearOrganic()");
_config.organic.clearEngines();
}
public function getDetectFlash():Boolean{
_debug.info("getDetectFlash()");
return (_config.detectFlash);
}
public function setCampMediumKey(_arg1:String):void{
_config.campaignKey.UCMD = _arg1;
var _local2 = (("setCampMediumKey( " + _config.campaignKey.UCMD) + " )");
if (_debug.mode == VisualDebugMode.geek){
_debug.info((_local2 + " [UCMD]"));
} else {
_debug.info(_local2);
};
}
private function _getUniqueSessionId():Number{
var _local1:Number = ((Utils.generate32bitRandom() ^ _generateUserDataHash()) * 2147483647);
_debug.info(("Session ID: " + _local1), VisualDebugMode.geek);
return (_local1);
}
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(_arg1:int):void{
_config.sessionTimeout = _arg1;
_debug.info((("setSessionTimeout( " + _config.sessionTimeout) + " )"));
}
public function getAccount():String{
_debug.info("getAccount()");
return (_account);
}
public function link(_arg1:String, _arg2:Boolean=false):void{
_debug.warning((("link( " + [_arg1, _arg2].join(", ")) + " ) not implemented"));
}
public function setRemoteServerMode():void{
_config.serverMode = ServerOperationMode.remote;
_debug.info("setRemoteServerMode()");
}
}
}//package com.google.analytics.v4
Section 91
//AnalyticsTracker (com.google.analytics.AnalyticsTracker)
package com.google.analytics {
import com.google.analytics.v4.*;
import com.google.analytics.debug.*;
import flash.events.*;
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 92
//API (com.google.analytics.API)
package com.google.analytics {
import com.google.analytics.utils.*;
public class API {
public static var version:Version = new Version();
version.major = 1;
version.minor = 0;
version.build = 1;
version.revision = "$Rev: 319 $ ".split(" ")[1];
}
}//package com.google.analytics
Section 93
//GATracker (com.google.analytics.GATracker)
package com.google.analytics {
import com.google.analytics.core.*;
import com.google.analytics.v4.*;
import com.google.analytics.debug.*;
import com.google.analytics.utils.*;
import flash.display.*;
import flash.events.*;
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 94
//AppDoc (com.lisong.Application.AppDoc)
package com.lisong.Application {
import flash.display.*;
import flash.events.*;
import code.sound.*;
import com.lisong.Data.*;
import com.lisong.Controller.*;
import com.lisong.Core.*;
import flash.utils.*;
public class AppDoc extends MovieClip {
private var game:GameStage;
public function AppDoc(){
Model.getInstance();
setTimeout(init, 1);
}
public function del():void{
this.removeEventListener(Event.ENTER_FRAME, update);
BroadCaster.getInstance().removeEventListener("onRemoveSheep", removeSheep);
BroadCaster.getInstance().removeEventListener("onAddScore", onAddScore);
BroadCaster.getInstance().removeEventListener("onLooseScore", onLooseScore);
stage.removeEventListener(KeyboardEvent.KEY_UP, changeTool);
game.del();
}
private function init():void{
initGame();
initListeners();
SoundManager.instance.playMusic("music_in_game");
}
private function initListeners():void{
this.addEventListener(Event.ENTER_FRAME, update, false, 0, true);
BroadCaster.getInstance().addEventListener("onRemoveSheep", removeSheep);
BroadCaster.getInstance().addEventListener("onAddScore", onAddScore);
BroadCaster.getInstance().addEventListener("onLooseScore", onLooseScore);
stage.addEventListener(KeyboardEvent.KEY_UP, changeTool);
}
private function onLooseScore(_arg1:LetheEvent):void{
game.onLooseScore(_arg1.data.x, _arg1.data.y, _arg1.data.score);
}
private function onAddScore(_arg1:LetheEvent):void{
game.onAddScore(_arg1.data.x, _arg1.data.y, _arg1.data.score);
}
private function changeTool(_arg1:KeyboardEvent):void{
if (_arg1.keyCode == 32){
game.changeTool();
};
}
private function removeSheep(_arg1:LetheEvent):void{
game.removeSheepByData(_arg1.data);
}
private function initGame():void{
game = new GameStage(this);
}
private function update(_arg1:Event):void{
game.update();
}
}
}//package com.lisong.Application
Section 95
//BroadCaster (com.lisong.Controller.BroadCaster)
package com.lisong.Controller {
import flash.events.*;
public class BroadCaster extends EventDispatcher {
private static var _instance:BroadCaster;
public function run(_arg1:String, _arg2=null):void{
this.dispatchEvent(new LetheEvent(_arg1, _arg2));
}
public static function getInstance():BroadCaster{
if (_instance == null){
_instance = new (BroadCaster);
};
return (_instance);
}
}
}//package com.lisong.Controller
Section 96
//LetheEvent (com.lisong.Controller.LetheEvent)
package com.lisong.Controller {
import flash.events.*;
public class LetheEvent extends Event {
public var data;
public function LetheEvent(_arg1:String, _arg2){
super(_arg1, false, false);
data = _arg2;
}
}
}//package com.lisong.Controller
Section 97
//PoolMc (com.lisong.Core.Items.PoolMc)
package com.lisong.Core.Items {
import com.lisong.Enginee.*;
public class PoolMc extends StageItem {
public function PoolMc(_arg1:PhysicalSheep){
addFrameScript(12, frame13);
super(_arg1);
}
function frame13(){
stop();
}
}
}//package com.lisong.Core.Items
Section 98
//StageItem (com.lisong.Core.Items.StageItem)
package com.lisong.Core.Items {
import flash.display.*;
import com.lisong.Enginee.*;
public class StageItem extends MovieClip {
public var data:PhysicalSheep;
public var sheepDepth:Number;
public function StageItem(_arg1:PhysicalSheep){
data = _arg1;
sheepDepth = data.y;
this.x = data.x;
this.y = data.y;
}
}
}//package com.lisong.Core.Items
Section 99
//StumbMc (com.lisong.Core.Items.StumbMc)
package com.lisong.Core.Items {
import com.lisong.Enginee.*;
public class StumbMc extends StageItem {
public function StumbMc(_arg1:PhysicalSheep){
addFrameScript(12, frame13);
super(_arg1);
}
function frame13(){
stop();
}
}
}//package com.lisong.Core.Items
Section 100
//BackGroundContainer (com.lisong.Core.BackGroundContainer)
package com.lisong.Core {
import flash.display.*;
public class BackGroundContainer extends UIContainer {
public function BackGroundContainer(_arg1:DisplayObjectContainer){
super(_arg1);
}
}
}//package com.lisong.Core
Section 101
//BlackSheep (com.lisong.Core.BlackSheep)
package com.lisong.Core {
import flash.display.*;
import com.lisong.Enginee.*;
import com.lisong.Controller.*;
public class BlackSheep extends Sheep {
public function BlackSheep(_arg1:PhysicalSheep, _arg2:MovieClip){
super(_arg1, _arg2);
head.gotoAndStop("normal");
sheepLife = 0;
addFrameScript(0, onLand);
addFrameScript(15, onSky);
}
private function onSky():void{
isOnLand = true;
}
private function onLand():void{
isOnLand = false;
}
override public function update():void{
super.update();
if (cutCounter > 0){
cutCounter--;
if (cutCounter == 0){
head.gotoAndStop("normal");
};
};
}
override public function run():void{
super.run();
}
override public function tryToCut():void{
super.tryToCut();
BroadCaster.getInstance().run("onLooseScore", {x:x, y:y, score:-200});
cutCounter = 30;
head.gotoAndStop("angry");
}
}
}//package com.lisong.Core
Section 102
//GameStage (com.lisong.Core.GameStage)
package com.lisong.Core {
import flash.display.*;
import flash.events.*;
import com.lisong.Enginee.*;
import com.lisong.Data.*;
import code.tool.*;
import flash.utils.*;
import flash.ui.*;
import com.lisong.Items.*;
import flash.geom.*;
public class GameStage extends UIContainer {
private var sheepContainer:SheepContainer;
private var backGroundContainer:UIContainer;
private var frontBackContainer:UIContainer;
private var shadowContainer:UIContainer;
private var toolContainer:ToolContainer;
private var sheepTimer:Timer;
private var physWorld:SheepWorld;
private var moveAbleItems:Array;
private var mouseCursor:MovieClip;
private var _isdown:Boolean;
private var _isDrag:Boolean;
private var _tempPoint:Point;
private var model:Model;
private var cursorPlaying:Boolean;// = false
private var waveData:Wave;
private var waveCounter:int;// = 0
private var cUpdateSheep:Sheep;
private var checkGameWin:Function;
public var update:Function;
private var cProp:Number;
private var allSheepOut:Boolean;
public function GameStage(_arg1:DisplayObjectContainer){
_tempPoint = new Point(0, 0);
super(_arg1);
initData();
createPhysicalWorld();
createDisplay();
createItems();
addListeners();
}
public function del():void{
}
private function addListeners():void{
sheepContainer.addEventListener(MouseEvent.MOUSE_DOWN, onSelectSheep, false, 0, true);
sheepContainer.addEventListener(MouseEvent.MOUSE_UP, onCutSheep, false, 0, true);
sheepContainer.addEventListener(MouseEvent.MOUSE_OVER, onOverSheep, false, 0, true);
sheepContainer.addEventListener(MouseEvent.MOUSE_OUT, onOutSheep, false, 0, true);
sheepContainer.addEventListener(MouseEvent.MOUSE_MOVE, onMouseOverFun, false, 0, true);
this.stage.addEventListener(MouseEvent.MOUSE_UP, onMouseUpFun, false, 0, true);
stage.addEventListener(MouseEvent.MOUSE_UP, onDropSheep, false, 0, true);
}
private function onMouseOverFun(_arg1:MouseEvent):void{
var _local2:int;
if (_isdown){
_local2 = int((Math.pow((stage.mouseX - _tempPoint.x), 2) + Math.pow((stage.mouseY - _tempPoint.y), 2)));
_tempPoint.x = stage.mouseX;
_tempPoint.y = stage.mouseY;
if (_local2 > 25){
trace("ECHO:Distance over 25");
_isDrag = true;
};
};
if (((_isdown) && (_isDrag))){
if (toolContainer.state == 1){
trace("hand");
changeTool();
};
};
}
private function onMouseUpFun(_arg1:MouseEvent):void{
_isdown = false;
_isDrag = false;
if (toolContainer.state == 0){
changeTool();
};
}
public function onLooseScore(_arg1:Number, _arg2:Number, _arg3:int):void{
var _local4:AddScore;
toolContainer.onAddScore(_arg3);
_local4 = (Attach.instance.getMovieClip("LoseScoreEffect") as AddScore);
_local4.setInfo(toolContainer, _arg1, _arg2, _arg3);
}
public function onAddScore(_arg1:Number, _arg2:Number, _arg3:int):void{
var _local4:AddScore;
toolContainer.onAddScore(_arg3);
_local4 = (Attach.instance.getMovieClip("AddScoreEffect") as AddScore);
_local4.setInfo(toolContainer, _arg1, _arg2, _arg3);
}
private function onOutSheep(_arg1:MouseEvent):void{
mouseCursor.gotoAndStop(1);
}
private function onOverSheep(_arg1:MouseEvent):void{
if ((_arg1.target is Sheep)){
mouseCursor.gotoAndStop(2);
};
}
private function onDropSheep(_arg1:MouseEvent):void{
sheepContainer.onDropSheep(_arg1);
if (toolContainer.state == 0){
mouseCursor.cassor.gotoAndStop("handNormal");
};
}
private function onCutSheep(_arg1:MouseEvent):void{
playCursorMovie();
sheepContainer.onCutSheep(_arg1);
}
private function onSelectSheep(_arg1:MouseEvent):void{
_isdown = true;
_tempPoint.x = stage.mouseX;
_tempPoint.y = stage.mouseY;
sheepContainer.onSelectSheep(_arg1);
}
public function onGameOver():void{
update = empty;
}
private function initData():void{
moveAbleItems = new Array();
}
private function createPhysicalWorld():void{
physWorld = new SheepWorld(720, 205, -50, 145);
}
private function createDisplay():void{
backGroundContainer = new BackGroundContainer(this);
shadowContainer = new ShadowContainer(this);
sheepContainer = new SheepContainer(this);
frontBackContainer = new BackGroundContainer(this);
toolContainer = new ToolContainer(this);
mouseCursor = Attach.instance.getMovieClip("MouseCursor");
Mouse.hide();
addChild(mouseCursor);
mouseCursor.startDrag(true);
mouseCursor.cassor.addFrameScript(7, oncursorMovieDone);
mouseCursor.gotoAndStop(1);
mouseCursor.mouseEnabled = false;
mouseCursor.mouseChildren = false;
playCursorMovie();
backGroundContainer.addDisplay(Attach.instance.getMovieClip("TempBackGround"));
}
private function oncursorMovieDone():void{
cursorPlaying = false;
mouseCursor.cassor.gotoAndStop(1);
}
public function getWaveData():void{
var _local1:int;
while (_local1 < physWorld.sheeps.length) {
if ((physWorld.sheeps[_local1] is NormalSheep)){
removeSheepByData(physWorld.sheeps[_local1], false);
_local1--;
};
_local1++;
};
waveCounter = 0;
update = updateAll;
waveData = Model.getInstance().getWave();
checkGameWin = checkSheepCreator;
}
private function addSheep(_arg1):void{
var _local2:MovieClip = Attach.instance.getMovieClip("SheepShadow");
var _local3:Sheep = new _arg1(physWorld.createSheep(640, (145 + (Math.random() * 220)), 0), _local2);
shadowContainer.addDisplay(_local2);
moveAbleItems.push(_local3);
sheepContainer.addDisplay(_local3);
}
private function createItems():void{
}
public function onToolChanged():void{
sheepContainer.setState(toolContainer.state);
changeCursor();
}
public function removeSheepByData(_arg1:PhysicalSheep, _arg2:Boolean=true):void{
physWorld.removeSheep(_arg1);
var _local3:int;
while (_local3 < moveAbleItems.length) {
if (moveAbleItems[_local3].data == _arg1){
if (_arg2){
toolContainer.checkLife(moveAbleItems[_local3].sheepLife);
};
shadowContainer.removeDisplay(moveAbleItems[_local3].shadow);
sheepContainer.removeSheep(moveAbleItems[_local3]);
moveAbleItems.splice(_local3, 1);
return;
};
_local3++;
};
}
private function playCursorMovie():void{
if (((!(cursorPlaying)) && ((toolContainer.state == 1)))){
cursorPlaying = true;
mouseCursor.cassor.play();
};
}
private function changeCursor():void{
mouseCursor.gotoAndStop(1);
if (toolContainer.state == 1){
mouseCursor.cassor.gotoAndStop("cut");
cursorPlaying = false;
} else {
mouseCursor.cassor.gotoAndStop("handNormal");
cursorPlaying = false;
};
}
public function changeTool():void{
toolContainer.changeTool();
}
public function empty():void{
}
public function updateAll():void{
physWorld.update();
for each (cUpdateSheep in moveAbleItems) {
cUpdateSheep.update();
};
sheepContainer.updateLayers();
toolContainer.update();
checkGameWin();
}
public function checkAllSheepOut():void{
if (sheepContainer.sheeps.length == 0){
update = empty;
toolContainer.onLevelPass();
};
}
private function checkSheepCreator():void{
waveCounter++;
if (waveData.maxTime < waveCounter){
allSheepOut = true;
checkGameWin = checkAllSheepOut;
return;
};
for each (cProp in waveData.sheeps[waveCounter]) {
if (Math.random() < cProp){
addSheep(WhiteSheep);
} else {
addSheep(BlackSheep);
};
};
}
override public function remove():void{
super.remove();
}
}
}//package com.lisong.Core
Section 103
//ShadowContainer (com.lisong.Core.ShadowContainer)
package com.lisong.Core {
import flash.display.*;
public class ShadowContainer extends UIContainer {
public function ShadowContainer(_arg1:DisplayObjectContainer){
super(_arg1);
}
}
}//package com.lisong.Core
Section 104
//Sheep (com.lisong.Core.Sheep)
package com.lisong.Core {
import flash.display.*;
import com.lisong.Enginee.*;
import code.sound.*;
public class Sheep extends MovieClip {
protected const S_NONE:int = 0;
protected const S_RUN:int = 1;
protected const S_CRAZY:int = 2;
protected const S_CUT:int = 3;
protected const S_SHY:int = 4;
protected const S_FAINT:int = 5;
public var head:MovieClip;
public var shadow:MovieClip;
public var body:MovieClip;
public var data:PhysicalSheep;
public var sheepDepth:Number;
protected var cutting:MovieClip;
protected var _cutTime:int;// = 2
protected var _standTime:int;// = 10
protected var fallenTime:int;// = 40
protected var cutCounter:int;// = 0
protected var standCount:int;// = 0
public var sheepLife:int;// = 3
protected var state:int;// = 0
protected var died:Boolean;// = false
private var tmpScale:Number;
public function Sheep(_arg1:PhysicalSheep, _arg2:MovieClip){
addFrameScript(0, frame1, 17, frame18, 20, frame21, 30, frame31, 51, frame52);
this.mouseChildren = false;
data = _arg1;
shadow = _arg2;
this.x = -100;
this.y = -100;
shadow.x = -100;
shadow.y = -100;
}
public function set isOnLand(_arg1:Boolean):void{
data.isRunStop = _arg1;
}
public function update():void{
sheepDepth = data.y;
this.x = data.x;
this.y = (data.y + data.z);
tmpScale = ((800 + data.z) / 800);
if (tmpScale < 0.5){
tmpScale = 0.5;
};
shadow.scaleX = (shadow.scaleY = tmpScale);
shadow.x = data.x;
shadow.y = data.y;
data.clearId();
}
public function tryToCut():void{
SoundManager.instance.playSound("sound_cut");
}
public function run():void{
}
public function dragTo(_arg1:Number, _arg2:Number):void{
data.gotoTarget(_arg1, _arg2);
}
public function moveAbleTure():void{
data.moveAbleTure();
}
public function setSelect(_arg1:Boolean):void{
data.setSelect(_arg1);
}
public function moveAableFalse():void{
data.moveAableFalse();
}
public function stopMoving():void{
data.stopMoving();
}
function frame1(){
isOnLand = false;
}
function frame18(){
isOnLand = true;
}
function frame21(){
gotoAndPlay("run");
}
function frame31(){
gotoAndPlay("crazy");
}
function frame52(){
gotoAndPlay("shy");
}
}
}//package com.lisong.Core
Section 105
//SheepContainer (com.lisong.Core.SheepContainer)
package com.lisong.Core {
import flash.display.*;
import flash.events.*;
public class SheepContainer extends UIContainer {
private var state:int;// = 1
private var selectSheep:Sheep;
public var sheeps:Array;
private var sheepCounter:int;
public function SheepContainer(_arg1:DisplayObjectContainer){
super(_arg1);
sheeps = new Array();
}
public function onCutSheep(_arg1:MouseEvent):void{
if (state == 0){
return;
};
if ((_arg1.target is Sheep)){
(_arg1.target as Sheep).tryToCut();
};
}
public function onDropSheep(_arg1:MouseEvent=null):void{
if (selectSheep != null){
selectSheep.moveAbleTure();
selectSheep.setSelect(false);
selectSheep = null;
};
}
public function setState(_arg1:int):void{
state = _arg1;
if (state == 1){
onDropSheep();
};
}
public function onSelectSheep(_arg1:MouseEvent):void{
if ((_arg1.target is Sheep)){
if (selectSheep != null){
selectSheep.moveAbleTure();
selectSheep.setSelect(false);
};
selectSheep = (_arg1.target as Sheep);
selectSheep.moveAableFalse();
selectSheep.setSelect(true);
};
}
public function removeSheep(_arg1:Sheep):void{
removeChild(_arg1);
sheeps.splice(sheeps.indexOf(_arg1), 1);
}
override public function addDisplay(_arg1):void{
super.addDisplay(_arg1);
sheeps.push(_arg1);
}
public function updateLayers():void{
sheeps.sortOn("sheepDepth", Array.NUMERIC);
sheepCounter = 0;
while (sheepCounter < sheeps.length) {
this.setChildIndex(sheeps[sheepCounter], sheepCounter);
sheepCounter++;
};
if (selectSheep != null){
selectSheep.dragTo(mouseX, mouseY);
};
}
}
}//package com.lisong.Core
Section 106
//ToolContainer (com.lisong.Core.ToolContainer)
package com.lisong.Core {
import flash.display.*;
import flash.events.*;
import code.ui.*;
import code.*;
import com.lisong.Data.*;
import flash.text.*;
import flash.utils.*;
import flash.ui.*;
import com.lisong.UI.*;
public class ToolContainer extends UIContainer {
private const GAMETIME:int = 600000;
public var __id1_:MovieClip;
public var state:int;
public var isChanging:Boolean;
public var t_time:TextField;
public var t_score:TextField;
public var t_wave:TextField;
public var t_leftLife:TextField;
public var m_moneyEarn:MovieClip;
public var sheep_lost:MovieClip;
public var time_gone:MovieClip;
public var update:Function;
private var totalLife:Number;// = 15
private var startTime:int;
private var sec:int;
private var second:int;
private var min:int;
private var lastTime:int;
private var totalWave:int;// = 8
private var gameOverMc:RoundPass;
private var stepScore:Number;
private var cShowScore:int;// = 0
public static var lifeLeft:Number = 15;
public static var timeUsed:int;
public static var totalScore:int = 0;
public function ToolContainer(_arg1:DisplayObjectContainer){
super(_arg1);
initDisplay();
initData();
initToolMc();
initEvent();
__setProp___id1__UI_ingame_();
}
private function initDisplay():void{
m_moneyEarn.stop();
sheep_lost.stop();
time_gone.stop();
}
private function initToolMc():void{
state = 1;
isChanging = false;
}
private function changeToolByClick(_arg1:MouseEvent):void{
if (!isChanging){
(parent as GameStage).changeTool();
};
}
private function initData():void{
t_wave.text = String((Model.getInstance().currentWave + 1));
update = updateTime;
startTime = getTimer();
if (Model.getInstance().currentWave == 0){
lastTime = GAMETIME;
};
if (lifeLeft <= 0){
lifeLeft = totalLife;
totalScore = 0;
t_leftLife.text = String(lifeLeft);
lastTime = GAMETIME;
};
(parent as GameStage).getWaveData();
}
public function empty():void{
}
public function checkLife(_arg1:int):void{
if (_arg1 <= 0){
return;
};
lifeLeft = (lifeLeft - 1);
t_leftLife.text = String(lifeLeft);
sheep_lost.gotoAndPlay(1);
if (lifeLeft <= 0){
if (Model.getInstance().currentWave > totalWave){
showGameOver(false);
return;
};
showGameOver(false);
return;
};
}
public function updateTime():void{
timeUsed = (getTimer() - startTime);
timeUsed = (lastTime - timeUsed);
if (timeUsed >= 0){
sec = ((timeUsed / 1000) >> 0);
min = ((sec / 60) >> 0);
second = (sec % 60);
} else {
min = 0;
second = 0;
};
t_time.text = ((((min > 9)) ? String(min) : ("0" + min) + ":") + ((second > 9)) ? String(second) : ("0" + second));
if (sec < 10){
time_gone.play();
} else {
time_gone.gotoAndStop(1);
};
if (cShowScore != totalScore){
if (stepScore > 0){
cShowScore = (cShowScore + Math.round(stepScore));
if (cShowScore > totalScore){
cShowScore = totalScore;
};
} else {
if (stepScore < 0){
cShowScore = (cShowScore + Math.round(stepScore));
if (cShowScore < totalScore){
cShowScore = totalScore;
};
};
};
t_score.text = String(cShowScore);
};
if (timeUsed < 0){
if (Model.getInstance().currentWave > totalWave){
showGameOver(true);
return;
};
showGameOver(false);
return;
};
}
private function initEvent():void{
Game.instance.addEventListener(Game.Game_Continue, onGameContinueFun);
Game.instance.addEventListener(Game.Game_LevelPass_Remove, onGameLevelPassRemoveFun);
}
private function onGameLevelPassRemoveFun(_arg1:Event):void{
}
private function onGameContinueFun(_arg1:Event):void{
Mouse.hide();
continueGame();
}
public function continueGame():void{
gameOverMc = null;
initData();
}
public function onLevelPass():void{
var _local1:LevelPass;
lastTime = timeUsed;
Model.getInstance().currentWave++;
trace("currentWave #currentWave++", Model.getInstance().currentWave);
if (Model.getInstance().currentWave > totalWave){
if (Model.getInstance().currentWave > 9){
showGameOver(false);
return;
};
showGameOver(true);
return;
};
if (gameOverMc == null){
_local1 = new LevelPass();
addChild(_local1.mc);
update = empty;
};
}
public function showGameOver(_arg1:Boolean=false):void{
(parent as GameStage).onGameOver();
if (gameOverMc == null){
gameOverMc = new RoundPass(_arg1);
addChild(gameOverMc);
update = empty;
};
Model.getInstance().currentWave = 0;
}
public function onAddScore(_arg1:int):void{
totalScore = (totalScore + _arg1);
stepScore = ((totalScore - cShowScore) / 10);
if (stepScore > 0){
stepScore = (stepScore + 1);
} else {
stepScore = (stepScore + -1);
};
m_moneyEarn.gotoAndPlay(1);
}
private function movieDone():void{
}
public function changedTool():void{
state = (1 - state);
(this.parent as GameStage).onToolChanged();
}
private function changeDone():void{
isChanging = false;
}
public function changeTool():void{
isChanging = true;
changedTool();
}
function __setProp___id1__UI_ingame_(){
try {
__id1_["componentInspectorSetting"] = true;
} catch(e:Error) {
};
__id1_.position = "button_level_moregames";
__id1_.type = "moregames";
try {
__id1_["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package com.lisong.Core
Section 107
//UIContainer (com.lisong.Core.UIContainer)
package com.lisong.Core {
import flash.display.*;
public class UIContainer extends MovieClip {
public function UIContainer(_arg1:DisplayObjectContainer){
_arg1.addChild(this);
}
public function addDisplay(_arg1):void{
addChild(_arg1);
}
public function removeDisplay(_arg1):void{
removeChild(_arg1);
}
public function remove():void{
parent.removeChild(this);
}
}
}//package com.lisong.Core
Section 108
//WhiteSheep (com.lisong.Core.WhiteSheep)
package com.lisong.Core {
import flash.display.*;
import com.lisong.Enginee.*;
import code.sound.*;
import code.tool.*;
import com.lisong.Controller.*;
import code.logic.*;
public class WhiteSheep extends Sheep {
private var _type:SheepType;
public function WhiteSheep(_arg1:PhysicalSheep, _arg2:MovieClip){
super(_arg1, _arg2);
setBodyState(1);
setType();
run();
}
private function setType():void{
var _local1:Number = Math.random();
if (_local1 > 0.95){
_type = SheepType.Type4;
} else {
if (_local1 > 0.8){
_type = SheepType.Type3;
} else {
if (_local1 > 0.6){
_type = SheepType.Type2;
} else {
_type = SheepType.Type1;
};
};
};
}
override public function update():void{
super.update();
if (cutCounter > 0){
cutCounter--;
if (cutCounter == 0){
cutOk();
} else {
cut();
};
} else {
if (data.z == 0){
if (standCount > 0){
slowDonw();
standCount--;
} else {
run();
};
} else {
standCount = 0;
crazy();
};
};
}
override public function tryToCut():void{
super.tryToCut();
if (cutting != null){
return;
};
if (died){
return;
};
cutCounter = _cutTime;
}
private function setBodyState(_arg1:int):void{
body.gotoAndStop(_arg1);
head["hair"].gotoAndStop(_arg1);
}
private function cutOk():void{
removeChild(cutting);
cutting = null;
SoundManager.instance.playSound("sound_sheep_cut");
BroadCaster.getInstance().run("onAddScore", {x:x, y:y, score:Type.Value});
sheepLife--;
if (body.currentFrame < body.totalFrames){
if (body.currentFrame == (body.totalFrames - 1)){
died = true;
if (Math.random() > 0.5){
SoundManager.instance.playSound("sound_sheep_1");
} else {
SoundManager.instance.playSound("sound_sheep_2");
};
};
body.nextFrame();
head["hair"].nextFrame();
};
state = S_NONE;
}
private function shy():void{
if (state == S_SHY){
return;
};
isOnLand = false;
this.gotoAndPlay("shy");
state = S_SHY;
head.gotoAndStop("faint");
data.crazy();
}
private function crazy():void{
if (state == S_CRAZY){
return;
};
this.gotoAndPlay("crazy");
head.gotoAndStop("crazy");
state = S_CRAZY;
}
private function slowDonw():void{
data.slowDown();
}
override public function run():void{
if (state == S_RUN){
return;
};
if (state == S_SHY){
return;
};
if (data.prevSpeed > 20){
faint();
return;
};
if (died){
shy();
return;
};
data.normalRun();
this.gotoAndPlay("run");
if (died){
head.gotoAndStop("faint");
} else {
head.gotoAndStop(Type.Name);
};
state = S_RUN;
}
private function faint():void{
if (state == S_FAINT){
return;
};
state = S_FAINT;
this.gotoAndStop("faint");
head.gotoAndStop("faint2");
standCount = Math.round(((data.prevSpeed / 20) * fallenTime));
isOnLand = true;
}
private function cut():void{
if (state == S_CUT){
return;
};
state = S_CUT;
standCount = _standTime;
this.gotoAndPlay("crazy");
head.gotoAndStop("suprise");
cutting = Attach.instance.getMovieClip("SheepCutting");
isOnLand = true;
addChild(cutting);
}
public function get Type():SheepType{
return (_type);
}
}
}//package com.lisong.Core
Section 109
//Model (com.lisong.Data.Model)
package com.lisong.Data {
import flash.net.*;
import flash.events.*;
import code.data.*;
public class Model {
public var waves:Array;
private var tempWave:Wave;
private var ldr:URLLoader;
public var currentWave:int;
private var levelChange:int;// = 100
private static var _instance:Model;
public function Model(){
waves = new Array();
currentWave = 0;
initStaticXMLData();
}
public function setGameData():void{
ldr = new URLLoader();
ldr.load(new URLRequest("Waves.xml"));
ldr.addEventListener(Event.COMPLETE, initData, false, 0, true);
}
private function initData(_arg1:Event):void{
var _local3:XML;
var _local4:Wave;
var _local5:XML;
var _local2:XML = XML(ldr.data);
ldr = null;
for each (_local3 in _local2["wave"]) {
_local4 = new Wave();
waves.push(_local4);
for each (_local5 in _local3["sheep"]) {
_local4.addSheep(Number(_local5.attribute("time")), Number(_local5.attribute("prob")));
};
};
}
private function initStaticXMLData():void{
var _local2:XML;
var _local3:Wave;
var _local4:XML;
var _local1:XML = Data.xmlData;
ldr = null;
for each (_local2 in _local1["wave"]) {
_local3 = new Wave();
waves.push(_local3);
for each (_local4 in _local2["sheep"]) {
_local3.addSheep(Number(_local4.attribute("time")), Number(_local4.attribute("prob")));
};
};
}
public function getWave():Wave{
trace("waves.length", waves.length);
if (waves[currentWave] != null){
return (waves[currentWave]);
};
return (createRandomLevel(currentWave));
}
private function createRandomLevel(_arg1:int):Wave{
var _local4:int;
var _local2:Wave = new Wave();
var _local3:int;
while (_local3 < ((_arg1 + levelChange) * 10)) {
_local4 = 0;
while (_local4 < (Math.random() * 7)) {
_local2.addSheep(_local3, 0.9);
_local4++;
};
_local3 = (_local3 + 2);
};
return (_local2);
}
public static function getInstance():Model{
if (_instance == null){
_instance = new (Model);
};
return (_instance);
}
}
}//package com.lisong.Data
Section 110
//Wave (com.lisong.Data.Wave)
package com.lisong.Data {
public class Wave {
public var sheeps:Object;
public var maxTime:int;
private var tmpTime:int;
public function Wave(){
maxTime = 0;
sheeps = new Object();
}
public function addSheep(_arg1:Number, _arg2:Number):void{
tmpTime = Math.round((_arg1 * 30));
if (sheeps[tmpTime] == null){
sheeps[tmpTime] = new Array();
};
sheeps[tmpTime].push(_arg2);
if (tmpTime > maxTime){
maxTime = tmpTime;
};
}
}
}//package com.lisong.Data
Section 111
//NormalSheep (com.lisong.Enginee.NormalSheep)
package com.lisong.Enginee {
public class NormalSheep extends PhysicalSheep {
public function NormalSheep(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:int){
super(_arg1, _arg2, _arg3, _arg4);
}
}
}//package com.lisong.Enginee
Section 112
//PhysicalSheep (com.lisong.Enginee.PhysicalSheep)
package com.lisong.Enginee {
import com.lisong.Controller.*;
public class PhysicalSheep {
public var radius:Number;
public var moveAble:Boolean;
public var x:Number;
public var y:Number;
public var z:Number;
public var initspeed:Number;// = 0
public var speedx:Number;// = 0
public var speedz:Number;// = 0
public var speedy:Number;// = 0
public var prevSpeed:Number;
private var maxxspeed:Number;// = 6
private var maxxyspeed:Number;// = 6
private var aspeed:Number;// = 1
private var maxSheepSpeed:Number;// = 3
private var dragApspeed:Number;// = 4
private var dragFriction:Number;// = 0.5
private var gravity:Number;// = 1
private var distance:Number;
private var radiusSum:Number;
private var ppdirection:Number;
private var revertDistance:Number;
private var revertSin:Number;
private var revertCos:Number;
public var collideId:Object;
private var tmpSpdx:Number;
private var tmpSpdy:Number;
private var isSelect:Boolean;// = false
public var isRunStop:Boolean;// = false
private var speedDirection:Number;
private var speedLength:Number;
private var dragdistance:Number;
public var moveBySpeed:Function;
public function PhysicalSheep(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:int){
x = _arg1;
y = _arg2;
z = _arg3;
radius = 25;
moveAble = true;
initspeed = -2;
speedx = -2;
moveBySpeed = moveAtSpeed;
clearId();
}
public function adjustBorder():void{
if (this.x >= SheepWorld.maxx){
this.x = (SheepWorld.maxx - 10);
this.speedx = (this.speedx * -0.2);
};
}
public function collide(_arg1:PhysicalSheep, _arg2:int):void{
if (((!(moveAble)) && (!(_arg1.moveAble)))){
return;
};
if ((((z < -50)) || ((_arg1.z < -50)))){
return;
};
radiusSum = (_arg1.radius + radius);
distance = Math.sqrt((Math.pow((x - _arg1.x), 2) + Math.pow((y - _arg1.y), 2)));
if (distance < radiusSum){
ppdirection = Math.atan2((_arg1.y - y), (_arg1.x - x));
revertDistance = (radiusSum - distance);
if (moveAble){
if (_arg1.moveAble){
revertCos = ((revertDistance * Math.cos(ppdirection)) / 2);
revertSin = ((revertDistance * Math.sin(ppdirection)) / 2);
_arg1.move(revertCos, revertSin);
move(-(revertCos), -(revertSin));
if ((((collideId[_arg2] == null)) || (!((collideId[_arg2] == _arg1.collideId[_arg2]))))){
collideId[_arg2] = 1;
_arg1.collideId[_arg2] = 1;
tmpSpdx = speedx;
tmpSpdy = speedy;
speedx = (_arg1.speedx * 0.5);
speedy = (_arg1.speedy * 0.5);
_arg1.speedx = (tmpSpdx * 0.5);
_arg1.speedy = (tmpSpdy * 0.5);
};
} else {
revertCos = (revertDistance * Math.cos(ppdirection));
revertSin = (revertDistance * Math.sin(ppdirection));
move(-(revertCos), -(revertSin));
};
} else {
revertCos = (revertDistance * Math.cos(ppdirection));
revertSin = (revertDistance * Math.sin(ppdirection));
_arg1.move(revertCos, revertSin);
if (isSelect){
_arg1.changeSpeedBySheep(ppdirection, speedx, Math.cos(ppdirection), Math.sin(ppdirection));
};
};
};
}
public function clearId():void{
collideId = new Object();
}
public function changeSpeedBySheep(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):void{
this.speedx = (this.speedx + ((_arg2 * _arg3) * _arg3));
this.speedy = (this.speedy + ((_arg2 * _arg3) * _arg4));
if (speedy > 15){
speedy = 15;
} else {
if (speedy < -15){
speedy = -15;
};
};
if (speedx > 15){
speedx = 15;
} else {
if (speedx < -15){
speedx = -15;
};
};
}
public function setSelect(_arg1:Boolean):void{
isSelect = _arg1;
}
public function gotoTarget(_arg1:Number, _arg2:Number):void{
prevSpeed = speedz;
dragdistance = (Math.pow(((_arg2 - y) - z), 2) + Math.pow((_arg1 - x), 2));
speedLength = ((speedx * speedx) + (speedz * speedz));
if ((((speedLength < 64)) && ((dragdistance < 100)))){
speedx = 0;
speedz = 0;
x = _arg1;
z = (_arg2 - y);
} else {
speedDirection = Math.atan2(((_arg2 - y) - z), (_arg1 - x));
this.speedx = ((speedx + (dragApspeed * Math.cos(speedDirection))) * 0.9);
this.speedz = ((speedz + (dragApspeed * Math.sin(speedDirection))) * 0.9);
this.x = (this.x + speedx);
this.z = (this.z + speedz);
};
if (z > 0){
z = 0;
speedz = 0;
};
}
public function crazy():void{
maxSheepSpeed = 9;
}
public function slowDown():void{
if (speedx == 0){
return;
};
if (speedx > 0){
speedx = (speedx - 1);
if (speedx < 0){
speedx = 0;
};
} else {
if (speedx < 0){
speedx = (speedx + 1);
if (speedx > 0){
speedx = 0;
};
};
};
}
public function normalRun():void{
maxSheepSpeed = 3;
}
private function empty():Boolean{
if (speedy == 0){
return (true);
};
if (speedy > 0){
speedy = (speedy - 1);
if (speedy < 0){
speedy = 0;
};
this.y = (this.y + speedy);
return (true);
};
speedy = (speedy + 1);
if (speedy > 0){
speedy = 0;
};
this.y = (this.y + speedy);
return (true);
}
private function moveAtSpeed():Boolean{
empty();
prevSpeed = speedz;
if (z == 0){
if (speedx == -(maxSheepSpeed)){
if (!isRunStop){
this.x = (this.x + speedx);
};
} else {
if (!isRunStop){
this.x = (this.x + speedx);
};
};
if (speedx > -(maxSheepSpeed)){
speedx = (speedx - aspeed);
} else {
if (speedx < -(maxSheepSpeed)){
speedx = (speedx + aspeed);
};
};
} else {
speedz = (speedz + gravity);
this.z = (this.z + speedz);
if (z > 0){
speedz = 0;
z = 0;
};
this.x = (this.x + speedx);
};
if (x < SheepWorld.minx){
BroadCaster.getInstance().run("onRemoveSheep", this);
return (false);
};
if (y > SheepWorld.maxy){
y = (SheepWorld.maxy - Math.random());
} else {
if (y < SheepWorld.miny){
y = (SheepWorld.miny + Math.random());
};
};
return (true);
}
public function moveAableFalse():void{
moveAble = false;
moveBySpeed = empty;
}
public function moveAbleTure():void{
speedx = Math.round(speedx);
moveAble = true;
moveBySpeed = moveAtSpeed;
}
public function stopMoving():void{
this.speedx = 0;
}
public function continueMoving():void{
this.speedx = initspeed;
moveBySpeed = moveAtSpeed;
}
public function move(_arg1:Number, _arg2:Number):void{
this.x = (this.x + (_arg1 * 1.1));
this.y = (this.y + (_arg2 * 1.1));
}
}
}//package com.lisong.Enginee
Section 113
//Pool (com.lisong.Enginee.Pool)
package com.lisong.Enginee {
public class Pool extends PhysicalSheep {
public function Pool(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:int){
super(_arg1, _arg2, _arg3, _arg4);
moveAble = false;
radius = 35;
moveBySpeed = alwaysTrue;
}
public function alwaysTrue():Boolean{
return (true);
}
}
}//package com.lisong.Enginee
Section 114
//SheepWorld (com.lisong.Enginee.SheepWorld)
package com.lisong.Enginee {
public class SheepWorld {
private var sheepCounter:int;
private var collideId:int;
public var sheeps:Array;
public static var minx:Number;
public static var miny:Number;
public static var maxx:Number;
public static var maxy:Number;
public function SheepWorld(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number){
minx = _arg3;
miny = _arg4;
maxx = (_arg1 + _arg3);
maxy = (_arg2 + _arg4);
sheeps = new Array();
}
public function update():void{
var _local1:PhysicalSheep;
var _local2:PhysicalSheep;
collideId = 0;
sheepCounter = 0;
while (sheepCounter < sheeps.length) {
_local1 = sheeps[sheepCounter];
_local1.adjustBorder();
if (!_local1.moveBySpeed()){
sheepCounter--;
} else {
for each (_local2 in sheeps) {
if (_local2 == sheeps[sheepCounter]){
} else {
collideId++;
_local2.collide(sheeps[sheepCounter], collideId);
};
};
};
sheepCounter++;
};
}
public function createSheep(_arg1:Number, _arg2:Number, _arg3:int):PhysicalSheep{
var _local4:NormalSheep = new NormalSheep(_arg1, _arg2, 0, _arg3);
sheeps.push(_local4);
return (_local4);
}
public function createStumb(_arg1:Number, _arg2:Number, _arg3:int):PhysicalSheep{
var _local4:Stumb = new Stumb(_arg1, _arg2, 0, _arg3);
sheeps.push(_local4);
return (_local4);
}
public function createPool(_arg1:Number, _arg2:Number, _arg3:int):PhysicalSheep{
var _local4:Pool = new Pool(_arg1, _arg2, 0, _arg3);
sheeps.push(_local4);
return (_local4);
}
public function removeSheep(_arg1:PhysicalSheep):void{
var _local2:int = sheeps.indexOf(_arg1);
if (_local2 != -1){
sheeps.splice(_local2, 1);
};
}
}
}//package com.lisong.Enginee
Section 115
//Stumb (com.lisong.Enginee.Stumb)
package com.lisong.Enginee {
public class Stumb extends PhysicalSheep {
public function Stumb(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:int){
super(_arg1, _arg2, _arg3, _arg4);
moveAble = false;
radius = 10;
moveBySpeed = alwaysTrue;
}
public function alwaysTrue():Boolean{
return (true);
}
}
}//package com.lisong.Enginee
Section 116
//AddScore (com.lisong.Items.AddScore)
package com.lisong.Items {
import flash.display.*;
public class AddScore extends MovieClip {
public var scoreMc:MovieClip;
public function AddScore(){
this.addFrameScript(24, remove);
}
public function setInfo(_arg1:DisplayObjectContainer, _arg2:Number, _arg3:Number, _arg4:int):void{
_arg1.addChild(this);
this.x = _arg2;
this.y = _arg3;
scoreMc.txt.text = String(_arg4);
}
private function remove():void{
stop();
try {
parent.removeChild(this);
} catch(e:Error) {
};
}
}
}//package com.lisong.Items
Section 117
//RoundPass (com.lisong.UI.RoundPass)
package com.lisong.UI {
import flash.display.*;
import flash.events.*;
import code.ui.*;
import code.*;
import code.sound.*;
import com.lisong.Data.*;
import code.data.*;
import com.lisong.Core.*;
import zlong.data.*;
public class RoundPass extends MovieClip {
public var m_gameOver:MovieClip;
private var _win:Boolean;
private var _score:int;
public function RoundPass(_arg1:Boolean=false){
addFrameScript(4, frame5);
_win = _arg1;
m_gameOver["t_round"].text = String(Model.getInstance().currentWave);
m_gameOver["t_money"].text = String(ToolContainer.totalScore);
var _local2:int = ToolContainer.timeUsed;
var _local3:int = ((_local2 / 1000) % 60);
var _local4 = ((_local2 / 60000) >> 0);
m_gameOver["t_time"].text = ((((_local4 > 9)) ? String(_local4) : ("0" + _local4) + ":") + ((_local3 > 9)) ? String(_local3) : ("0" + _local3));
if (_win){
if (Model.getInstance().currentWave == 9){
_score = ((ToolContainer.totalScore + (Model.getInstance().currentWave * 200)) + (_local2 / 100));
} else {
_score = (ToolContainer.totalScore + (Model.getInstance().currentWave * 200));
};
} else {
_score = (ToolContainer.totalScore + (Model.getInstance().currentWave * 200));
};
ToolContainer.totalScore = _score;
m_gameOver["t_total"].text = String(ToolContainer.totalScore);
m_gameOver["m_continue"].addEventListener(MouseEvent.CLICK, onContinue, false, 0, true);
m_gameOver["m_continue"].addEventListener(MouseEvent.MOUSE_OVER, onMouseOver, false, 0, true);
m_gameOver["m_continue"].addEventListener(MouseEvent.ROLL_OUT, onMouseOver, false, 0, true);
m_gameOver["m_continue"].buttonMode = true;
m_gameOver["m_continue"].mouseChildren = false;
m_gameOver["m_continue"].gotoAndStop(1);
m_gameOver["t_grade"].text = getGrade(Data.moneyLevels);
if (GameInfo.cnversion == false){
if (ToolContainer.totalScore >= 50000){
SpilSystem.instance.submitAchievement("SCISSORFAN");
trace("SCISSORFAN");
};
if (ToolContainer.totalScore >= 85000){
SpilSystem.instance.submitAchievement("SCISSORADDICT");
trace("SCISSORADDICT");
};
if (ToolContainer.lifeLeft == 15){
SpilSystem.instance.submitAchievement("SHARPSHAVERN");
trace("SHARPSHAVER");
};
if (m_gameOver["t_grade"].text == "SSS"){
SpilSystem.instance.submitAchievement("SCISSORMASTER");
trace("SCISSORMASTER");
};
};
}
private function onMouseOver(_arg1:MouseEvent):void{
var _local2:int;
if (_arg1.target == m_gameOver["m_continue"]){
_local2 = m_gameOver["m_continue"].currentFrame;
if (_local2 == 1){
m_gameOver["m_continue"].gotoAndStop(2);
SoundManager.instance.playSound("sound_menu_touch");
} else {
m_gameOver["m_continue"].gotoAndStop(1);
};
};
}
private function onContinue(_arg1:MouseEvent):void{
if (_arg1.target == m_gameOver["m_continue"]){
m_gameOver["m_continue"].gotoAndStop(1);
SoundManager.instance.playSound("sound_menu_press");
};
if (_win){
Game.instance.dispatchEvent(new Event(Game.Game_Win));
} else {
Game.instance.dispatchEvent(new Event(Game.Game_Over));
};
remove();
}
private function remove():void{
try {
this.parent.removeChild(this);
} catch(e:Error) {
};
}
private function getGrade(_arg1:Array):String{
var _local2:int = _arg1.length;
var _local3:int;
while (_local3 < _local2) {
if (ToolContainer.totalScore < _arg1[_local3]["money"]){
return (_arg1[_local3]["grade"]);
};
_local3++;
};
return (_arg1[(_local2 - 1)]["grade"]);
}
function frame5(){
stop();
}
}
}//package com.lisong.UI
Section 118
//SpilGamesServices (com.spilgames.api.SpilGamesServices)
package com.spilgames.api {
import flash.net.*;
import flash.display.*;
import flash.events.*;
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 119
//Alert (olduncle.Alert)
package olduncle {
import flash.net.*;
import flash.display.*;
import flash.events.*;
import zlong.country.*;
public class Alert extends MovieClip {
private var _afterFunction:Function;
public var goon:MovieClip;
public var agame_back:MovieClip;
public var _txt:MovieClip;
public function Alert(_arg1:DisplayObjectContainer, _arg2:Function){
m15();
_arg1.addChild(this);
_afterFunction = _arg2;
addEventListener(MouseEvent.CLICK, uiMouseClick);
}
private function m15():void{
var _local1:int = CountryInfo.instance.language;
(getChildByName("_txt") as MovieClip).gotoAndStop(_local1);
((getChildByName("goon") as MovieClip).getChildByName("_txt") as MovieClip).gotoAndStop(_local1);
((getChildByName("agame_back") as MovieClip).getChildByName("_txt") as MovieClip).gotoAndStop(_local1);
}
private function uiMouseClick(_arg1:MouseEvent):void{
var _local2:String = _arg1.target.name;
switch (_local2){
case "goon":
removeSelf();
_afterFunction();
break;
case "agame_back":
navigateToURL(new URLRequest(("http://" + CountryInfo.instance.domain)), "_blank");
break;
default:
break;
};
}
private function removeSelf():void{
removeEventListener(MouseEvent.CLICK, uiMouseClick);
var _local1:int;
while (_local1 < numChildren) {
if ((getChildAt(_local1) is BtnBase)){
(getChildAt(_local1) as BtnBase).removeAll();
};
_local1++;
};
parent.removeChild(this);
}
}
}//package olduncle
Section 120
//BtnBase (olduncle.BtnBase)
package olduncle {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
public class BtnBase extends MovieClip {
private var _btnName:String;
private var _isDown:Boolean;
private var _isAddUp:Boolean;
public function BtnBase(){
_isDown = false;
_isAddUp = false;
init();
}
public function init():void{
stop();
_btnName = name;
mouseChildren = false;
addEventListener(MouseEvent.MOUSE_OVER, mouseOverHandler);
addEventListener(MouseEvent.MOUSE_OUT, mouseOutHandler);
addEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler);
}
protected function mouseUpHandler(_arg1:MouseEvent):void{
gotoAndStop(1);
_isDown = false;
transform.colorTransform = new ColorTransform(1, 1, 1, 1, 0, 0, 0, 0);
}
protected function mouseDownHandler(_arg1:MouseEvent):void{
gotoAndStop(2);
_isDown = true;
transform.colorTransform = new ColorTransform(1, 1, 1, 1, 100, 100, 100, 0);
if (!_isAddUp){
stage.addEventListener(MouseEvent.MOUSE_UP, mouseUpHandler);
_isAddUp = true;
};
}
protected function mouseOutHandler(_arg1:MouseEvent):void{
gotoAndStop(1);
transform.colorTransform = new ColorTransform(1, 1, 1, 1, 0, 0, 0, 0);
}
protected function mouseOverHandler(_arg1:MouseEvent):void{
gotoAndStop(2);
if (_isDown){
transform.colorTransform = new ColorTransform(1, 1, 1, 1, 100, 100, 100, 0);
};
}
public function get btnName():String{
return (_btnName);
}
public function removeAll():void{
removeEventListener(MouseEvent.MOUSE_OVER, mouseOverHandler);
removeEventListener(MouseEvent.MOUSE_OUT, mouseOutHandler);
removeEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler);
stage.removeEventListener(MouseEvent.MOUSE_UP, mouseUpHandler);
}
}
}//package olduncle
Section 121
//KeyCtrl (olduncle.KeyCtrl)
package olduncle {
import flash.display.*;
import flash.events.*;
public class KeyCtrl {
private var _keyL:Stage;
protected var _keyArr:Array;
protected var _keyArrN:Array;
public static const UP:String = "&";
public static const DOWN:String = "(";
public static const LEFT:String = "%";
public static const RIGHT:String = "'";
public static const QUESTIONMARK:String = "¿";
public function KeyCtrl(_arg1:Stage){
_keyL = _arg1;
_keyArr = new Array();
_keyArrN = new Array();
_keyL.addEventListener(KeyboardEvent.KEY_UP, keyUpE);
_keyL.addEventListener(KeyboardEvent.KEY_DOWN, keyDownE);
}
public function removeAll():void{
_keyL.removeEventListener(KeyboardEvent.KEY_UP, keyUpE);
_keyL.removeEventListener(KeyboardEvent.KEY_DOWN, keyDownE);
}
private function keyUpE(_arg1:KeyboardEvent):void{
var _local2:String = String.fromCharCode(_arg1.keyCode);
delete _keyArr[_local2];
delete _keyArrN[_local2];
}
private function keyDownE(_arg1:KeyboardEvent):void{
_keyArr[String.fromCharCode(_arg1.keyCode)] = true;
}
public function isKeyDown(_arg1:String):Boolean{
return (_keyArr[_arg1]);
}
public function isKeyDownOnce(_arg1:String):Boolean{
if (((_keyArr[_arg1]) && (!(_keyArrN[_arg1])))){
_keyArrN[_arg1] = true;
return (true);
};
return (false);
}
}
}//package olduncle
Section 122
//faint2_110 (sheep_fla.faint2_110)
package sheep_fla {
import flash.display.*;
public dynamic class faint2_110 extends MovieClip {
public function faint2_110(){
addFrameScript(15, frame16);
}
function frame16(){
gotoAndPlay(1);
}
}
}//package sheep_fla
Section 123
//MONEY__17 (sheep_fla.MONEY__17)
package sheep_fla {
import flash.display.*;
public dynamic class MONEY__17 extends MovieClip {
public function MONEY__17(){
addFrameScript(8, frame9);
}
function frame9(){
gotoAndStop(1);
}
}
}//package sheep_fla
Section 124
//MoreGamesat_20 (sheep_fla.MoreGamesat_20)
package sheep_fla {
import flash.net.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.media.*;
import flash.utils.*;
import flash.ui.*;
import flash.geom.*;
import flash.system.*;
import flash.external.*;
import flash.errors.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.filters.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.xml.*;
public dynamic class MoreGamesat_20 extends MovieClip {
public var __id2_:Logo;
public var __setPropDict:Dictionary;
public function MoreGamesat_20(){
__setPropDict = new Dictionary(true);
super();
addFrameScript(0, frame1, 1, frame2);
}
function __setProp___id2__MoreGamesat_Layer4_0(){
if ((((__setPropDict[__id2_] == undefined)) || (!((int(__setPropDict[__id2_]) == 1))))){
__setPropDict[__id2_] = 1;
try {
__id2_["componentInspectorSetting"] = true;
} catch(e:Error) {
};
__id2_.alignHorizontal = "Center";
__id2_.alignVertical = "Down";
__id2_.maxHeight = 20;
__id2_.maxWidth = 150;
__id2_.position = "logo_preloader";
try {
__id2_["componentInspectorSetting"] = false;
} catch(e:Error) {
};
};
}
function __setProp___id2__MoreGamesat_Layer4_1(){
if ((((__setPropDict[__id2_] == undefined)) || (!((int(__setPropDict[__id2_]) == 2))))){
__setPropDict[__id2_] = 2;
try {
__id2_["componentInspectorSetting"] = true;
} catch(e:Error) {
};
__id2_.alignHorizontal = "Center";
__id2_.alignVertical = "Down";
__id2_.maxHeight = 20;
__id2_.maxWidth = 150;
__id2_.position = "logo_level";
try {
__id2_["componentInspectorSetting"] = false;
} catch(e:Error) {
};
};
}
function frame1(){
__setProp___id2__MoreGamesat_Layer4_0();
}
function frame2(){
__setProp___id2__MoreGamesat_Layer4_1();
}
}
}//package sheep_fla
Section 125
//Timeline_14 (sheep_fla.Timeline_14)
package sheep_fla {
import flash.display.*;
public dynamic class Timeline_14 extends MovieClip {
public function Timeline_14(){
addFrameScript(20, frame21);
}
function frame21(){
stop();
}
}
}//package sheep_fla
Section 126
//Timeline_147 (sheep_fla.Timeline_147)
package sheep_fla {
import flash.net.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.media.*;
import flash.utils.*;
import flash.ui.*;
import flash.geom.*;
import flash.system.*;
import flash.external.*;
import flash.errors.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.filters.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.xml.*;
public dynamic class Timeline_147 extends MovieClip {
public var t_money:TextField;
public var t_total:TextField;
public var t_time:TextField;
public var t_grade:TextField;
public var __id5_:MoreGamesLogo;
public var m_continue:MovieClip;
public var t_round:TextField;
public function Timeline_147(){
__setProp___id5__();
}
function __setProp___id5__(){
try {
__id5_["componentInspectorSetting"] = true;
} catch(e:Error) {
};
__id5_.position = "button_gamecomplete_moregames";
__id5_.type = "moregames";
try {
__id5_["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package sheep_fla
Section 127
//UI_Complete_ControlMc_130 (sheep_fla.UI_Complete_ControlMc_130)
package sheep_fla {
import flash.net.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.media.*;
import flash.utils.*;
import flash.ui.*;
import flash.geom.*;
import flash.system.*;
import flash.external.*;
import flash.errors.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.filters.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.xml.*;
public dynamic class UI_Complete_ControlMc_130 extends MovieClip {
public var challengeLabel:MovieClip;
public var tryAgainBtn:BTN_try;
public var __id3_:MoreGamesLogo;
public var creditsBtn:BTN_credits;
public var challengeBtn:BTN_challenge;
public var scoresTxt:TextField;
public var submitBtn:BTN_Submit;
public function UI_Complete_ControlMc_130(){
__setProp___id3__UI_Complete_ControlMc_();
}
function __setProp___id3__UI_Complete_ControlMc_(){
try {
__id3_["componentInspectorSetting"] = true;
} catch(e:Error) {
};
__id3_.position = "button_congratulations_moregames";
__id3_.type = "moregames";
try {
__id3_["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package sheep_fla
Section 128
//UI_GameOver_ControlMC_182 (sheep_fla.UI_GameOver_ControlMC_182)
package sheep_fla {
import flash.net.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.media.*;
import flash.utils.*;
import flash.ui.*;
import flash.geom.*;
import flash.system.*;
import flash.external.*;
import flash.errors.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.filters.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.xml.*;
public dynamic class UI_GameOver_ControlMC_182 extends MovieClip {
public var tryAgainBtn:BTN_try;
public var creditsBtn:BTN_credits;
public var scoresTxt:TextField;
public var __id7_:MoreGamesLogo;
public var submitBtn:BTN_Submit;
public function UI_GameOver_ControlMC_182(){
__setProp___id7__UI_GameOver_ControlMC_();
}
function __setProp___id7__UI_GameOver_ControlMC_(){
try {
__id7_["componentInspectorSetting"] = true;
} catch(e:Error) {
};
__id7_.position = "button_gameover_moregames";
__id7_.type = "moregames";
try {
__id7_["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package sheep_fla
Section 129
//Submitter (Spill.Components.Submitter)
package Spill.Components {
import flash.display.*;
public dynamic class Submitter extends MovieClip {
}
}//package Spill.Components
Section 130
//Countries (zlong.country.Countries)
package zlong.country {
import zlong.country.*;
class Countries {
private var _countries:Object;
private var _portal:String;
private var _portalGroup:Array;
private var _country:String;
private var _countryGroup:Array;
function Countries(){
initPortalGroup();
}
function set portal(_arg1:String):void{
if (!inArray(_arg1, _portalGroup)){
throw (new ArgumentError(("Please set portal with value : " + _portalGroup.toString())));
};
_portal = _arg1;
initCountries();
if (((!((_country == null))) && (!(inArray(_country, _countryGroup))))){
throw (new ArgumentError(("Please reset country with value : " + _countryGroup.toString())));
};
}
function set country(_arg1:String):void{
if (((!((_countryGroup == null))) && (!(inArray(_arg1, _countryGroup))))){
_country = _countryGroup[0];
trace(("Error in the country value,set country with default value : " + _countryGroup[0]));
trace(("Please set country with value : " + _countryGroup.toString()));
} else {
_country = _arg1;
};
}
function get current():CountryItem{
if (_portal == null){
throw (new ArgumentError("Please set portal"));
};
if (_country == null){
throw (new ArgumentError("Please set country"));
};
return (_countries[_country]);
}
function get countryGroup():Array{
if (_countryGroup == null){
throw (new ArgumentError("Please set portal"));
};
return (_countryGroup);
}
private function initCountries():void{
var _local1:CountryItem;
var _local2:String;
var _local3:String;
var _local4:String;
var _local5:int;
_countries = new Object();
_countryGroup = new Array();
var _local6:int;
while (_local6 < CountriesData.DATA[_portal]["country"].length()) {
_local2 = CountriesData.DATA[_portal]["country"][_local6].@name;
_local3 = CountriesData.DATA[_portal]["country"][_local6].@domain;
_local4 = CountriesData.DATA[_portal]["country"][_local6].@game;
_local5 = int(CountriesData.DATA[_portal]["country"][_local6].@language);
_local1 = new CountryItem();
_local1.name = _local2;
_local1.domain = _local3;
_local1.game = _local4;
_local1.language = _local5;
_countries[_local1.name] = _local1;
_countryGroup.push(_local2);
_local6++;
};
}
private function initPortalGroup():void{
_portalGroup = new Array();
var _local1:int;
while (_local1 < CountriesData.DATA.children().length()) {
_portalGroup.push(CountriesData.DATA.children()[_local1].name());
_local1++;
};
}
private function inArray(_arg1:String, _arg2:Array):Boolean{
var _local3:int;
while (_local3 < _arg2.length) {
if (_arg1 == _arg2[_local3]){
return (true);
};
_local3++;
};
return (false);
}
}
}//package zlong.country
Section 131
//CountriesData (zlong.country.CountriesData)
package zlong.country {
class CountriesData {
static const DATA:XML = <data>
<family>
<!-- new -->
<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="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.giocaregratis.it" game="gioco" language="9"/--><!-- Italian 2009.08.10 -->
<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.minigry.pl" game="gra" language="11"/--><!-- Polish 2009.08.10 -->
<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.mygames.co.uk" game="game" language="2"/--><!-- English UK 2009.08.28-->
<country name="en_uk" domain="www.agame.co.uk" 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="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="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="in" domain="www.girlsgogames.in" 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="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>
</data>
;
}
}//package zlong.country
Section 132
//CountryInfo (zlong.country.CountryInfo)
package zlong.country {
import zlong.domain.*;
import zlong.data.*;
public class CountryInfo {
private var countries:Countries;
private static var _instance:CountryInfo;
public function CountryInfo(){
countries = new Countries();
}
public function set portal(_arg1:String):void{
countries.portal = _arg1;
}
public function set country(_arg1:String):void{
countries.country = _arg1;
}
public function get country():String{
return (countries.current.name);
}
public function get domain():String{
return (countries.current.domain);
}
public function get language():int{
return (countries.current.language);
}
public function get countryGroup():Array{
return (countries.countryGroup);
}
public function get moreGameLink():String{
var _local1:String;
_local1 = ("http://" + domain);
if (countries.current.name != "cn"){
_local1 = (_local1 + "/");
_local1 = (_local1 + ("?utm_medium=brandedgames_" + (DomainInfo.instance.allowed) ? "internal" : "external"));
_local1 = (_local1 + ("&utm_campaign=" + GameInfo.name));
_local1 = (_local1 + ("&utm_source=" + DomainInfo.instance.domainAb));
} else {
_local1 = (_local1 + "/");
_local1 = (_local1 + "moregames");
_local1 = (_local1 + "/");
};
return (_local1);
}
public function get thisGameLink():String{
var _local1:String;
if (countries.current.name != "cn"){
_local1 = ("http://" + domain);
_local1 = (_local1 + ((("/" + countries.current.game) + "/") + GameInfo.html));
_local1 = (_local1 + ("?utm_medium=brandedgames_" + (DomainInfo.instance.allowed) ? "internal" : "external"));
_local1 = (_local1 + ("&utm_campaign=" + GameInfo.name));
_local1 = (_local1 + ("&utm_source=" + DomainInfo.instance.domainAb));
};
return (_local1);
}
public function get sendToFriendLink():String{
var _local1:String = thisGameLink;
if (countries.current.name != "cn"){
_local1 = (_local1 + "&utm_content=send_to_friend");
};
return (_local1);
}
public static function get instance():CountryInfo{
if (_instance == null){
_instance = new (CountryInfo);
};
return (_instance);
}
}
}//package zlong.country
Section 133
//CountryItem (zlong.country.CountryItem)
package zlong.country {
final class CountryItem {
var name:String;
var domain:String;
var game:String;
var language:int;
}
}//package zlong.country
Section 134
//CountryCookie (zlong.data.CountryCookie)
package zlong.data {
import flash.net.*;
public class CountryCookie {
private static const name:String = "spilgames_language_v100";
private static const countryName:String = "savedLang";
private static var so:SharedObject;
public function CountryCookie():void{
so = SharedObject.getLocal(name, "/");
}
public static function set country(_arg1:String):void{
so.data[countryName] = _arg1;
}
public static function get country():String{
return (so.data[countryName]);
}
}
}//package zlong.data
Section 135
//GameInfo (zlong.data.GameInfo)
package zlong.data {
public class GameInfo {
public static var cnversion:Boolean = false;
public static var portal:String = "family";
public static var name:String = "game_name";
public static var html:String = "Game-Name.html";
public static var width:int = 550;
public static var height:int = 400;
}
}//package zlong.data
Section 136
//Copyright (zlong.display.Copyright)
package zlong.display {
import flash.display.*;
import flash.events.*;
import zlong.navigate.*;
public class Copyright extends MovieClip {
public function Copyright(){
this.stop();
this.buttonMode = true;
this.mouseChildren = false;
initEvent();
}
private function initEvent():void{
this.addEventListener(MouseEvent.CLICK, Handler.click_copyright);
this.addEventListener(MouseEvent.ROLL_OVER, rollOverHandler);
this.addEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler);
this.addEventListener(MouseEvent.MOUSE_UP, mouseUpHandler);
this.addEventListener(MouseEvent.ROLL_OUT, rollOutHandler);
this.addEventListener(Event.REMOVED_FROM_STAGE, removeFromStageHandler);
}
private function delEvent():void{
this.removeEventListener(MouseEvent.CLICK, Handler.click_copyright);
this.removeEventListener(MouseEvent.ROLL_OVER, rollOverHandler);
this.removeEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler);
this.removeEventListener(MouseEvent.MOUSE_UP, mouseUpHandler);
this.removeEventListener(MouseEvent.ROLL_OUT, rollOutHandler);
this.removeEventListener(Event.REMOVED_FROM_STAGE, removeFromStageHandler);
}
private function rollOverHandler(_arg1:MouseEvent):void{
this.gotoAndStop(2);
}
private function mouseDownHandler(_arg1:MouseEvent):void{
this.gotoAndStop(3);
}
private function mouseUpHandler(_arg1:MouseEvent):void{
this.gotoAndStop(2);
}
private function rollOutHandler(_arg1:MouseEvent):void{
this.gotoAndStop(1);
}
private function removeFromStageHandler(_arg1:Event):void{
delEvent();
}
}
}//package zlong.display
Section 137
//CountriesBox (zlong.display.CountriesBox)
package zlong.display {
import flash.display.*;
import flash.events.*;
import zlong.country.*;
import zlong.data.*;
import flash.geom.*;
public class CountriesBox extends Sprite {
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;
public function CountriesBox(){
nameGroup = [];
super();
obj = new Object();
addEventListener(Event.ADDED_TO_STAGE, addToStageHandler);
addEventListener(Event.REMOVED_FROM_STAGE, removeFromStageHandler);
}
private function init():void{
initPos();
setFlag();
setPop();
initEvent();
initPoPEvent();
if (GameInfo.cnversion){
this.visible = false;
setLanguage("cn");
};
}
private function initPos():void{
var _local1:Point = new Point();
_local1 = this.localToGlobal(new Point(x, y));
if (_local1.y > (GameInfo.height / 2)){
mul = 1;
} else {
mul = -1;
};
}
private function setFlag():void{
country_name = (getChildByName("countryName") as MovieClip);
flagMc = (getChildByName("flag") as MovieClip);
flagMc.gotoAndStop(CountryInfo.instance.country);
country_name.gotoAndStop(CountryInfo.instance.country);
}
private function setPop():void{
var _local1:Number;
var _local2:Number;
var _local5:MovieClip;
var _local6:String;
var _local3:Number = 0;
var _local4:Number = 0;
pop = (getChildByName("popList") as Sprite);
selectBox = (getChildByName("selectbox") as MovieClip);
_local1 = pop["_blank"].width;
_local2 = (pop["_blank"].height - 1);
baseX = selectBox.x;
nameGroup = CountryInfo.instance.countryGroup;
var _local7:int = nameGroup.length;
if (mul == 1){
baseY = ((selectBox.y - (Math.round((_local7 / 2)) * _local2)) + _local2);
} else {
baseY = ((selectBox.y + selectBox.height) + _local2);
};
pop.y = baseY;
pop.visible = false;
pop["_blank"].visible = false;
i = 0;
while (i < _local7) {
_local6 = nameGroup[i];
if (pop.getChildByName(("l_" + _local6)) != null){
_local5 = (pop.getChildByName(("l_" + _local6)) as MovieClip);
_local5.mouseChildren = false;
_local5.buttonMode = true;
_local5.stop();
_local5["flag"].mouseEnable = false;
_local5["flag"].mouseChildren = false;
_local5["flag"].gotoAndStop(_local6);
obj[("l_" + _local6)] = true;
_local3 = (((i % 2) == 0)) ? 0 : 1;
_local5.x = ((_local1 * (i % 2)) - _local3);
_local5.y = ((_local2 * Math.floor((i / 2))) - _local2);
};
i++;
};
i = 0;
while (i < pop.numChildren) {
if (pop.getChildAt(i).name.indexOf("l_") != -1){
if (obj[pop.getChildAt(i).name] == undefined){
pop.getChildAt(i).visible = false;
};
};
i++;
};
if ((nameGroup.length % 2) == 0){
pop["_blank"].visible = false;
} else {
pop["_blank"].visible = true;
pop["_blank"].x = (_local1 - 1);
pop["_blank"].y = (((_local2 * Math.floor((nameGroup.length / 2))) - _local2) - _local4);
};
}
private function initEvent():void{
addEventListener(MouseEvent.ROLL_OVER, overHandler, false, 0, true);
addEventListener(MouseEvent.ROLL_OUT, outHandler, false, 0, true);
addEventListener(MouseEvent.CLICK, clickHandler, false, 0, true);
}
private function clickHandler(_arg1:MouseEvent):void{
var _local3:MovieClip;
var _local2:String = _arg1.target["name"];
if (_local2 == "_blank"){
return;
};
if (_local2.indexOf("l_") != -1){
_local3 = (_arg1.target["getChildByName"]("flag") as MovieClip);
flagMc.gotoAndStop(_local2.substr(2));
country_name.gotoAndStop(_local3.currentFrame);
setLanguage(_local2.substr(2));
pop.visible = false;
};
}
private function setLanguage(_arg1:String):void{
CountryInfo.instance.country = _arg1;
CountryCookie.country = _arg1;
Dispatcher.langChanged();
}
private function overHandler(_arg1:MouseEvent):void{
pop.visible = true;
}
private function outHandler(_arg1:MouseEvent):void{
pop.visible = false;
}
private function addToStageHandler(_arg1:Event):void{
init();
}
private function initPoPEvent():void{
pop.addEventListener(MouseEvent.MOUSE_OVER, overPoPHandler);
pop.addEventListener(MouseEvent.MOUSE_OUT, outPoPHandler);
}
private function delPoPEvent():void{
pop.removeEventListener(MouseEvent.MOUSE_OVER, overPoPHandler);
pop.removeEventListener(MouseEvent.MOUSE_OUT, outPoPHandler);
}
private function overPoPHandler(_arg1:MouseEvent):void{
var _local2 = _arg1.target;
_local2["gotoAndStop"](2);
}
private function outPoPHandler(_arg1:MouseEvent):void{
var _local2 = _arg1.target;
_local2["gotoAndStop"](1);
}
private function removeFromStageHandler(_arg1:Event):void{
removeEventListener(MouseEvent.ROLL_OVER, overHandler);
removeEventListener(MouseEvent.ROLL_OUT, outHandler);
removeEventListener(MouseEvent.CLICK, clickHandler);
removeEventListener(Event.ADDED_TO_STAGE, addToStageHandler);
removeEventListener(Event.REMOVED_FROM_STAGE, removeFromStageHandler);
delPoPEvent();
}
}
}//package zlong.display
Section 138
//Dispatcher (zlong.display.Dispatcher)
package zlong.display {
import flash.events.*;
class Dispatcher {
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 139
//ExtButton (zlong.display.ExtButton)
package zlong.display {
import flash.display.*;
import flash.events.*;
import zlong.navigate.*;
public class ExtButton extends MovieClip {
private var _type:String;// = "moregames"
private var _position:String;// = "button_preloader"
public function ExtButton(){
this.stop();
this.buttonMode = true;
this.mouseChildren = false;
initEvent();
}
public function set position(_arg1:String):void{
_position = _arg1;
}
public function set type(_arg1:String):void{
_type = _arg1;
}
private function initEvent():void{
this.addEventListener(MouseEvent.CLICK, clickHandler);
this.addEventListener(MouseEvent.ROLL_OVER, rollOverHandler);
this.addEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler);
this.addEventListener(MouseEvent.MOUSE_UP, mouseUpHandler);
this.addEventListener(MouseEvent.ROLL_OUT, rollOutHandler);
this.addEventListener(Event.REMOVED_FROM_STAGE, removeFromStageHandler);
}
private function delEvent():void{
this.removeEventListener(MouseEvent.CLICK, clickHandler);
this.removeEventListener(MouseEvent.ROLL_OVER, rollOverHandler);
this.removeEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler);
this.removeEventListener(MouseEvent.MOUSE_UP, mouseUpHandler);
this.removeEventListener(MouseEvent.ROLL_OUT, rollOutHandler);
this.removeEventListener(Event.REMOVED_FROM_STAGE, removeFromStageHandler);
}
private function clickHandler(_arg1:MouseEvent):void{
if (_type == "moregames"){
Handler.click_moregames(_position);
} else {
Handler.click_thisgame(_position);
};
}
private function rollOverHandler(_arg1:MouseEvent):void{
this.gotoAndStop(2);
}
private function mouseDownHandler(_arg1:MouseEvent):void{
this.gotoAndStop(3);
}
private function mouseUpHandler(_arg1:MouseEvent):void{
this.gotoAndStop(2);
}
private function rollOutHandler(_arg1:MouseEvent):void{
this.gotoAndStop(1);
}
private function removeFromStageHandler(_arg1:Event):void{
delEvent();
}
}
}//package zlong.display
Section 140
//Logo (zlong.display.Logo)
package zlong.display {
import flash.display.*;
import flash.events.*;
import zlong.country.*;
import zlong.navigate.*;
public class Logo extends MovieClip {
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
public function Logo(){
initDis();
addEventListener(Event.ADDED_TO_STAGE, initEvent, false, 0, true);
}
private function destroy():void{
delDis();
delEvent();
}
public function set position(_arg1:String):void{
_position = _arg1;
}
public function set alignHorizontal(_arg1:String):void{
_alignHorizontal = _arg1;
}
public function set alignVertical(_arg1:String):void{
_alignVertical = _arg1;
}
public function set maxWidth(_arg1:Number):void{
if (_arg1 < 0){
_arg1 = 0;
} else {
if (_arg1 > MAX_WIDTH){
_arg1 = MAX_WIDTH;
};
};
_maxWidth = _arg1;
}
public function set maxHeight(_arg1:Number):void{
if (_arg1 < 0){
_arg1 = 0;
} else {
if (_arg1 > Max_HEIGHT){
_arg1 = Max_HEIGHT;
};
};
_maxHeight = _arg1;
}
private function updateView():void{
var _local1:Sprite = (this.getChildAt(0) as Sprite);
_local1.scaleX = 1;
_local1.scaleY = 1;
var _local2:Number = (_maxHeight / _local1.height);
var _local3:Number = (_maxWidth / _local1.width);
var _local4:Number = ((_local2 > _local3)) ? _local3 : _local2;
_local1.scaleX = _local4;
_local1.scaleY = _local4;
switch (_alignHorizontal){
case "Left":
_local1.x = 0;
break;
case "Right":
_local1.x = (MAX_WIDTH - _local1.width);
break;
case "Center":
_local1.x = ((MAX_WIDTH - _local1.width) / 2);
break;
};
switch (_alignVertical){
case "Up":
_local1.y = 0;
break;
case "Down":
_local1.y = (Max_HEIGHT - _local1.height);
break;
case "Center":
_local1.y = ((Max_HEIGHT - _local1.height) / 2);
break;
};
_hitArea.width = _local1.width;
_hitArea.height = _local1.height;
_hitArea.x = _local1.x;
_hitArea.y = _local1.y;
}
private function initDis():void{
buttonMode = true;
_hitArea = new Sprite();
this.addChild(_hitArea);
_hitArea.graphics.beginFill(3368601, 0);
_hitArea.graphics.drawRect(0, 0, 10, 10);
_hitArea.graphics.endFill();
this["displayArea_mc"].visible = false;
var _local1:int;
while (_local1 < this.totalFrames) {
this.addFrameScript(_local1, updateView);
_local1++;
};
gotoAndStop(CountryInfo.instance.domain);
}
private function delDis():void{
stop();
}
private function initEvent(_arg1:Event=null):void{
this.addEventListener(Event.REMOVED_FROM_STAGE, removeFromStageHandler);
this.addEventListener(MouseEvent.CLICK, clickHandler);
Dispatcher.dispatcher.addEventListener(Dispatcher.LANGUAGE_CHANGED, langChangeHandler);
}
private function delEvent():void{
this.removeEventListener(Event.REMOVED_FROM_STAGE, removeFromStageHandler);
this.removeEventListener(MouseEvent.CLICK, clickHandler);
Dispatcher.dispatcher.removeEventListener(Dispatcher.LANGUAGE_CHANGED, langChangeHandler);
}
private function clickHandler(_arg1:MouseEvent):void{
Handler.click_moregames(_position);
}
private function langChangeHandler(_arg1:Event):void{
gotoAndStop(CountryInfo.instance.domain);
}
private function removeFromStageHandler(_arg1:Event):void{
destroy();
}
}
}//package zlong.display
Section 141
//Menu (zlong.display.Menu)
package zlong.display {
import flash.display.*;
import flash.events.*;
import zlong.country.*;
import zlong.navigate.*;
import flash.ui.*;
public class Menu {
private var displayObject:InteractiveObject;
private var menu:ContextMenu;
private var item:ContextMenuItem;
public function Menu(_arg1:InteractiveObject){
displayObject = _arg1;
init();
initEvent();
}
private function init():void{
menu = new ContextMenu();
menu.hideBuiltInItems();
var _local1:ContextMenuBuiltInItems = menu.builtInItems;
_local1.print = true;
_local1.zoom = true;
_local1.quality = true;
item = new ContextMenuItem(("MoreGame: " + CountryInfo.instance.domain));
menu.customItems.push(item);
displayObject.contextMenu = menu;
}
private function initEvent():void{
item.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, clickItemHandler);
Dispatcher.dispatcher.addEventListener(Dispatcher.LANGUAGE_CHANGED, changeLang);
}
private function changeLang(_arg1:Event):void{
item.caption = CountryInfo.instance.domain;
}
private function clickItemHandler(_arg1:ContextMenuEvent):void{
Handler.click_moregames("Contex_Menu");
}
}
}//package zlong.display
Section 142
//TranText (zlong.display.TranText)
package zlong.display {
import flash.display.*;
import flash.events.*;
import zlong.country.*;
public class TranText extends MovieClip {
private var isChange:Boolean;// = true
public function TranText(){
changeLang();
addEventListener(Event.ADDED_TO_STAGE, initEvent, false, 0, true);
}
public function set change(_arg1:Boolean):void{
isChange = _arg1;
}
private function changeLang():void{
gotoAndStop(CountryInfo.instance.language);
}
private function initEvent(_arg1:Event=null):void{
addEventListener(Event.REMOVED_FROM_STAGE, removeHandler);
Dispatcher.dispatcher.addEventListener(Dispatcher.LANGUAGE_CHANGED, langChangeHandler);
}
private function langChangeHandler(_arg1:Event):void{
if (isChange){
changeLang();
};
}
private function removeHandler(_arg1:Event):void{
removeEventListener(Event.REMOVED_FROM_STAGE, removeHandler);
Dispatcher.dispatcher.removeEventListener(Dispatcher.LANGUAGE_CHANGED, langChangeHandler);
}
}
}//package zlong.display
Section 143
//DomainData (zlong.domain.DomainData)
package zlong.domain {
final class DomainData {
static const allowedDomain:Array = ["www8.agame.com", "www.zlonggamestest.com", "gamedev.dev.spilgames.com", "localhost"];
}
}//package zlong.domain
Section 144
//DomainInfo (zlong.domain.DomainInfo)
package zlong.domain {
import flash.net.*;
public final class DomainInfo {
private var _allowed:Boolean;
private var _domain:String;
private var _domainAb:String;
private static var _instance:DomainInfo;
public function DomainInfo(){
_domain = new LocalConnection().domain;
initAllowed();
initAb();
}
public function get allowed():Boolean{
return (_allowed);
}
public function get domain():String{
return (_domain);
}
public function get domainAb():String{
return (_domainAb);
}
private function initAllowed():void{
var _local1:int;
while (_local1 < DomainData.allowedDomain.length) {
if (_domain == DomainData.allowedDomain[_local1]){
_allowed = true;
break;
};
_local1++;
};
}
private function initAb():void{
var _local1:Array;
var _local2:int;
var _local3:int;
if (_domain != "localhost"){
_local1 = _domain.split(".");
_local2 = (_local1.length - 1);
_local3 = (_local1.length - 2);
_domainAb = ((_local1[_local3] + ".") + _local1[_local2]);
} else {
_domainAb = "offline_play";
};
}
public static function get instance():DomainInfo{
if (_instance == null){
_instance = new (DomainInfo);
};
return (_instance);
}
}
}//package zlong.domain
Section 145
//Handler (zlong.navigate.Handler)
package zlong.navigate {
import flash.net.*;
import flash.events.*;
import zlong.country.*;
import flash.external.*;
public class Handler {
public static function click_gamecn(_arg1:Event=null):void{
var _local2:URLRequest = new URLRequest("http://www.game.com.cn");
navigateToURL(_local2, "_blank");
}
public static function click_copyright(_arg1:Event=null):void{
var _local2:URLRequest;
if (CountryInfo.instance.country == "cn"){
_local2 = new URLRequest("http://www.game.com.cn");
} else {
_local2 = new URLRequest("http://www.gameportal.net");
};
navigateToURL(_local2, "_blank");
}
public static function refurbish(_arg1:Event=null):void{
var e = _arg1;
try {
ExternalInterface.call("location.reload");
navigateToURL(new URLRequest(ExternalInterface.call("window.location.href.toString")), "_top");
} catch(myError:Error) {
};
}
public static function click_thisgame(_arg1:String):void{
var _local2:URLRequest;
if (CountryInfo.instance.country == "cn"){
_local2 = new URLRequest(CountryInfo.instance.moreGameLink);
} else {
_local2 = new URLRequest(((CountryInfo.instance.thisGameLink + "&utm_content=") + _arg1));
};
navigateToURL(_local2, "_blank");
}
public static function click_moregames(_arg1:String):void{
var _local2:URLRequest;
if (CountryInfo.instance.country == "cn"){
_local2 = new URLRequest(CountryInfo.instance.moreGameLink);
} else {
_local2 = new URLRequest(((CountryInfo.instance.moreGameLink + "&utm_content=") + _arg1));
};
navigateToURL(_local2, "_blank");
}
}
}//package zlong.navigate
Section 146
//GameSetting (zlong.GameSetting)
package zlong {
import flash.display.*;
import zlong.country.*;
import zlong.data.*;
import zlong.display.*;
public class GameSetting {
public function GameSetting(_arg1:InteractiveObject, _arg2:Boolean, _arg3:String, _arg4:String, _arg5:String, _arg6:int, _arg7:int){
GameInfo.cnversion = _arg2;
GameInfo.portal = _arg3;
GameInfo.name = _arg4;
GameInfo.html = _arg5;
GameInfo.width = _arg6;
GameInfo.height = _arg7;
init();
initMenu(_arg1);
}
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(_arg1:InteractiveObject):void{
new Menu(_arg1);
}
}
}//package zlong
Section 147
//AddScoreEffect (AddScoreEffect)
package {
import com.lisong.Items.*;
public dynamic class AddScoreEffect extends AddScore {
}
}//package
Section 148
//BTN_back (BTN_back)
package {
import code.tool.*;
public dynamic class BTN_back extends McButton {
}
}//package
Section 149
//BTN_back_HowToPlay (BTN_back_HowToPlay)
package {
import code.tool.*;
public dynamic class BTN_back_HowToPlay extends McButton {
}
}//package
Section 150
//BTN_challenge (BTN_challenge)
package {
import code.tool.*;
public dynamic class BTN_challenge extends McButton {
}
}//package
Section 151
//BTN_credits (BTN_credits)
package {
import code.tool.*;
public dynamic class BTN_credits extends McButton {
}
}//package
Section 152
//Btn_highScores (Btn_highScores)
package {
import code.tool.*;
public dynamic class Btn_highScores extends McButton {
}
}//package
Section 153
//BTN_HOWTOPLAY (BTN_HOWTOPLAY)
package {
import code.tool.*;
public dynamic class BTN_HOWTOPLAY extends McButton {
}
}//package
Section 154
//Btn_NO (Btn_NO)
package {
import olduncle.*;
public dynamic class Btn_NO extends BtnBase {
}
}//package
Section 155
//BTN_start (BTN_start)
package {
import code.tool.*;
public dynamic class BTN_start extends McButton {
}
}//package
Section 156
//BTN_Submit (BTN_Submit)
package {
import code.tool.*;
public dynamic class BTN_Submit extends McButton {
}
}//package
Section 157
//BTN_try (BTN_try)
package {
import code.tool.*;
public dynamic class BTN_try extends McButton {
}
}//package
Section 158
//Btn_YES (Btn_YES)
package {
import olduncle.*;
public dynamic class Btn_YES extends BtnBase {
}
}//package
Section 159
//CountriesBox (CountriesBox)
package {
import zlong.display.*;
public dynamic class CountriesBox extends CountriesBox {
}
}//package
Section 160
//Document (Document)
package {
import flash.display.*;
import code.ui.*;
import code.*;
import zlong.data.*;
import zlong.*;
public class Document extends MovieClip {
public function Document(){
this.stop();
new GameSetting(this, false, "family", "SHEEPTASTIC", "SHEEPTASTIC.html", 640, 480);
if (GameInfo.cnversion == false){
SpilSystem.instance.init(this);
};
initDoc();
}
private function initDoc():void{
trace("Manager.instance.init(this);");
Manager.instance.init(this);
}
}
}//package
Section 161
//game_com_cn_logo_music (game_com_cn_logo_music)
package {
import flash.media.*;
public dynamic class game_com_cn_logo_music extends Sound {
}
}//package
Section 162
//game_com_cn_logo_music_end (game_com_cn_logo_music_end)
package {
import flash.media.*;
public dynamic class game_com_cn_logo_music_end extends Sound {
}
}//package
Section 163
//GameChina (GameChina)
package {
import flash.net.*;
import flash.display.*;
import flash.events.*;
public dynamic class GameChina extends MovieClip {
public function GameChina(){
addFrameScript(0, frame1, 7, frame8, 152, frame153, 239, frame240);
}
public function onRemove(_arg1:Event){
this.removeEventListener("click", onPressLogo);
this.removeEventListener(Event.REMOVED_FROM_STAGE, onRemove);
}
public function onPressLogo(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.game.com.cn"), "_blank");
}
function frame1(){
this.addEventListener("click", onPressLogo);
this.buttonMode = true;
this.addEventListener(Event.REMOVED_FROM_STAGE, onRemove);
}
function frame8(){
}
function frame153(){
}
function frame240(){
stop();
}
}
}//package
Section 164
//loadingMC (loadingMC)
package {
import flash.net.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.media.*;
import flash.utils.*;
import flash.ui.*;
import flash.geom.*;
import flash.system.*;
import flash.external.*;
import flash.errors.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.filters.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.xml.*;
public dynamic class loadingMC extends MovieClip {
public var loadingMc:MovieClip;
public var percentText:TextField;
public var __id8_:MoreGamesLogo;
public function loadingMC(){
__setProp___id8__UI_loading_();
}
function __setProp___id8__UI_loading_(){
try {
__id8_["componentInspectorSetting"] = true;
} catch(e:Error) {
};
__id8_.position = "button_preloader";
__id8_.type = "moregames";
try {
__id8_["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package
Section 165
//Logo (Logo)
package {
import zlong.display.*;
public dynamic class Logo extends Logo {
}
}//package
Section 166
//LoseScoreEffect (LoseScoreEffect)
package {
import com.lisong.Items.*;
public dynamic class LoseScoreEffect extends AddScore {
}
}//package
Section 167
//MoreGamesLogo (MoreGamesLogo)
package {
import flash.net.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.media.*;
import flash.utils.*;
import zlong.display.*;
import flash.ui.*;
import flash.geom.*;
import flash.system.*;
import flash.external.*;
import flash.errors.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.filters.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.xml.*;
public dynamic class MoreGamesLogo extends ExtButton {
public var __id4_:Logo;
public function MoreGamesLogo(){
__setProp___id4__MoreGamesLogo_Layer4_0();
}
function __setProp___id4__MoreGamesLogo_Layer4_0(){
try {
__id4_["componentInspectorSetting"] = true;
} catch(e:Error) {
};
__id4_.alignHorizontal = "Center";
__id4_.alignVertical = "Down";
__id4_.maxHeight = 20;
__id4_.maxWidth = 150;
__id4_.position = "logo_preloader";
try {
__id4_["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package
Section 168
//MouseCursor (MouseCursor)
package {
import flash.display.*;
public dynamic class MouseCursor extends MovieClip {
public var cassor:MovieClip;
}
}//package
Section 169
//music_game_over (music_game_over)
package {
import flash.media.*;
public dynamic class music_game_over extends Sound {
}
}//package
Section 170
//music_game_win (music_game_win)
package {
import flash.media.*;
public dynamic class music_game_win extends Sound {
}
}//package
Section 171
//music_in_game (music_in_game)
package {
import flash.media.*;
public dynamic class music_in_game extends Sound {
}
}//package
Section 172
//music_main_menu (music_main_menu)
package {
import flash.media.*;
public dynamic class music_main_menu extends Sound {
}
}//package
Section 173
//SheepCutting (SheepCutting)
package {
import flash.display.*;
public dynamic class SheepCutting extends MovieClip {
}
}//package
Section 174
//SheepShadow (SheepShadow)
package {
import flash.display.*;
public dynamic class SheepShadow extends MovieClip {
}
}//package
Section 175
//sound_cut (sound_cut)
package {
import flash.media.*;
public dynamic class sound_cut extends Sound {
}
}//package
Section 176
//sound_menu_press (sound_menu_press)
package {
import flash.media.*;
public dynamic class sound_menu_press extends Sound {
}
}//package
Section 177
//sound_menu_touch (sound_menu_touch)
package {
import flash.media.*;
public dynamic class sound_menu_touch extends Sound {
}
}//package
Section 178
//sound_sheep_1 (sound_sheep_1)
package {
import flash.media.*;
public dynamic class sound_sheep_1 extends Sound {
}
}//package
Section 179
//sound_sheep_2 (sound_sheep_2)
package {
import flash.media.*;
public dynamic class sound_sheep_2 extends Sound {
}
}//package
Section 180
//sound_sheep_cut (sound_sheep_cut)
package {
import flash.media.*;
public dynamic class sound_sheep_cut extends Sound {
}
}//package
Section 181
//soundMC (soundMC)
package {
import flash.display.*;
public dynamic class soundMC extends MovieClip {
}
}//package
Section 182
//SubmitterProxy (SubmitterProxy)
package {
import flash.display.*;
import flash.events.*;
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 183
//TempBackGround (TempBackGround)
package {
import flash.display.*;
public dynamic class TempBackGround extends MovieClip {
}
}//package
Section 184
//title (title)
package {
import zlong.display.*;
public dynamic class title extends TranText {
}
}//package
Section 185
//txt_BACK_gamewin (txt_BACK_gamewin)
package {
import zlong.display.*;
public dynamic class txt_BACK_gamewin extends TranText {
}
}//package
Section 186
//txt_CHALLENGE_gamewin (txt_CHALLENGE_gamewin)
package {
import zlong.display.*;
public dynamic class txt_CHALLENGE_gamewin extends TranText {
}
}//package
Section 187
//txt_clickRepeatluOnlambToShear_tutorial (txt_clickRepeatluOnlambToShear_tutorial)
package {
import zlong.display.*;
public dynamic class txt_clickRepeatluOnlambToShear_tutorial extends TranText {
}
}//package
Section 188
//txt_clickToCountinue_countscore (txt_clickToCountinue_countscore)
package {
import zlong.display.*;
public dynamic class txt_clickToCountinue_countscore extends TranText {
}
}//package
Section 189
//txt_clickToStartNextRound_levelpass (txt_clickToStartNextRound_levelpass)
package {
import zlong.display.*;
public dynamic class txt_clickToStartNextRound_levelpass extends TranText {
}
}//package
Section 190
//txt_Congratulations_gamewin (txt_Congratulations_gamewin)
package {
import zlong.display.*;
public dynamic class txt_Congratulations_gamewin extends TranText {
}
}//package
Section 191
//txt_dontClickTheBlackLamb_tutorial (txt_dontClickTheBlackLamb_tutorial)
package {
import zlong.display.*;
public dynamic class txt_dontClickTheBlackLamb_tutorial extends TranText {
}
}//package
Section 192
//txt_GAME_OVER_gameover (txt_GAME_OVER_gameover)
package {
import zlong.display.*;
public dynamic class txt_GAME_OVER_gameover extends TranText {
}
}//package
Section 193
//txt_GRADE_countscore (txt_GRADE_countscore)
package {
import zlong.display.*;
public dynamic class txt_GRADE_countscore extends TranText {
}
}//package
Section 194
//txt_HOW_TO_PLAY_mainmenu_1 (txt_HOW_TO_PLAY_mainmenu_1)
package {
import zlong.display.*;
public dynamic class txt_HOW_TO_PLAY_mainmenu_1 extends TranText {
}
}//package
Section 195
//txt_HOW_TO_PLAY_tutorial (txt_HOW_TO_PLAY_tutorial)
package {
import zlong.display.*;
public dynamic class txt_HOW_TO_PLAY_tutorial extends TranText {
}
}//package
Section 196
//txt_lambWillBeDizzyIfFallFromHeight_tutorial (txt_lambWillBeDizzyIfFallFromHeight_tutorial)
package {
import zlong.display.*;
public dynamic class txt_lambWillBeDizzyIfFallFromHeight_tutorial extends TranText {
}
}//package
Section 197
//txt_MONEY_countscore (txt_MONEY_countscore)
package {
import zlong.display.*;
public dynamic class txt_MONEY_countscore extends TranText {
}
}//package
Section 198
//txt_MORE_GAMES_mainmenu_1 (txt_MORE_GAMES_mainmenu_1)
package {
import zlong.display.*;
public dynamic class txt_MORE_GAMES_mainmenu_1 extends TranText {
}
}//package
Section 199
//txt_NEXT_levelpass (txt_NEXT_levelpass)
package {
import zlong.display.*;
public dynamic class txt_NEXT_levelpass extends TranText {
}
}//package
Section 200
//txt_ROUND_countscore (txt_ROUND_countscore)
package {
import zlong.display.*;
public dynamic class txt_ROUND_countscore extends TranText {
}
}//package
Section 201
//txt_ROUND_ingame (txt_ROUND_ingame)
package {
import zlong.display.*;
public dynamic class txt_ROUND_ingame extends TranText {
}
}//package
Section 202
//txt_ROUND_levelpass (txt_ROUND_levelpass)
package {
import zlong.display.*;
public dynamic class txt_ROUND_levelpass extends TranText {
}
}//package
Section 203
//txt_START_mainmenu_1 (txt_START_mainmenu_1)
package {
import zlong.display.*;
public dynamic class txt_START_mainmenu_1 extends TranText {
}
}//package
Section 204
//txt_TIME_countscore (txt_TIME_countscore)
package {
import zlong.display.*;
public dynamic class txt_TIME_countscore extends TranText {
}
}//package
Section 205
//txt_TOTAL_countscore (txt_TOTAL_countscore)
package {
import zlong.display.*;
public dynamic class txt_TOTAL_countscore extends TranText {
}
}//package
Section 206
//txt_TRY_AGAIN (txt_TRY_AGAIN)
package {
import zlong.display.*;
public dynamic class txt_TRY_AGAIN extends TranText {
}
}//package
Section 207
//txt_youCanHoldAndDragToLiftALamb_tutorial (txt_youCanHoldAndDragToLiftALamb_tutorial)
package {
import zlong.display.*;
public dynamic class txt_youCanHoldAndDragToLiftALamb_tutorial extends TranText {
}
}//package
Section 208
//txt_YOUR_GRADE_countscore (txt_YOUR_GRADE_countscore)
package {
import zlong.display.*;
public dynamic class txt_YOUR_GRADE_countscore extends TranText {
}
}//package
Section 209
//txt_YOUR_SCORE_gameover (txt_YOUR_SCORE_gameover)
package {
import zlong.display.*;
public dynamic class txt_YOUR_SCORE_gameover extends TranText {
}
}//package
Section 210
//txt_YOUR_SCORE_gamewin (txt_YOUR_SCORE_gamewin)
package {
import zlong.display.*;
public dynamic class txt_YOUR_SCORE_gamewin extends TranText {
}
}//package
Section 211
//UI_GameOverMC (UI_GameOverMC)
package {
import flash.display.*;
public dynamic class UI_GameOverMC extends MovieClip {
public var contrlMC:MovieClip;
public function UI_GameOverMC(){
addFrameScript(9, frame10);
}
function frame10(){
stop();
}
}
}//package
Section 212
//UI_GameWinMC (UI_GameWinMC)
package {
import flash.display.*;
public dynamic class UI_GameWinMC extends MovieClip {
public var contrlMC:MovieClip;
public function UI_GameWinMC(){
addFrameScript(9, frame10);
}
function frame10(){
stop();
}
}
}//package
Section 213
//UI_HighScoresMC (UI_HighScoresMC)
package {
import flash.display.*;
public dynamic class UI_HighScoresMC extends MovieClip {
public var backBtn:BTN_back;
}
}//package
Section 214
//UI_HowToPlayMC (UI_HowToPlayMC)
package {
import flash.display.*;
public dynamic class UI_HowToPlayMC extends MovieClip {
public var backBtn:BTN_back_HowToPlay;
}
}//package
Section 215
//UI_InGame_BackGround (UI_InGame_BackGround)
package {
import flash.display.*;
public dynamic class UI_InGame_BackGround extends MovieClip {
}
}//package
Section 216
//UI_LevelPass_Effect (UI_LevelPass_Effect)
package {
import flash.display.*;
import flash.text.*;
public dynamic class UI_LevelPass_Effect extends MovieClip {
public var timeTxt:TextField;
public var waveTxt:TextField;
}
}//package
Section 217
//UI_MainMenuMC (UI_MainMenuMC)
package {
import flash.net.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.media.*;
import flash.utils.*;
import flash.ui.*;
import flash.geom.*;
import flash.system.*;
import flash.external.*;
import flash.errors.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.filters.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.xml.*;
public dynamic class UI_MainMenuMC extends MovieClip {
public var howToPlayBtn:BTN_HOWTOPLAY;
public var soundBtn:MovieClip;
public var gameQualityBtn:MovieClip;
public var musicBtn:MovieClip;
public var __id6_:MoreGamesLogo;
public var startBtn:BTN_start;
public var highScoresBtn:Btn_highScores;
public function UI_MainMenuMC(){
__setProp___id6__UI_mainscreen_();
}
function __setProp___id6__UI_mainscreen_(){
try {
__id6_["componentInspectorSetting"] = true;
} catch(e:Error) {
};
__id6_.position = "button_mainscreen_moregames";
__id6_.type = "moregames";
try {
__id6_["componentInspectorSetting"] = false;
} catch(e:Error) {
};
}
}
}//package