Section 1
//AuxFunctions (caurina.transitions.AuxFunctions)
package caurina.transitions {
public class AuxFunctions {
public static function concatObjects(... _args):Object{
var _local2:Object;
var _local3:Object;
var _local4:int;
var _local5:String;
_local2 = {};
_local4 = 0;
while (_local4 < _args.length) {
_local3 = _args[_local4];
for (_local5 in _local3) {
if (_local3[_local5] == null){
delete _local2[_local5];
} else {
_local2[_local5] = _local3[_local5];
};
};
_local4++;
};
return (_local2);
}
public static function numberToG(_arg1:Number):Number{
return (((_arg1 & 0xFF00) >> 8));
}
public static function numberToR(_arg1:Number):Number{
return (((_arg1 & 0xFF0000) >> 16));
}
public static function isInArray(_arg1:String, _arg2:Array):Boolean{
var _local3:uint;
var _local4:uint;
_local3 = _arg2.length;
_local4 = 0;
while (_local4 < _local3) {
if (_arg2[_local4] == _arg1){
return (true);
};
_local4++;
};
return (false);
}
public static function getObjectLength(_arg1:Object):uint{
var _local2:uint;
var _local3:String;
_local2 = 0;
for (_local3 in _arg1) {
_local2++;
};
return (_local2);
}
public static function numberToB(_arg1:Number):Number{
return ((_arg1 & 0xFF));
}
}
}//package caurina.transitions
Section 2
//Equations (caurina.transitions.Equations)
package caurina.transitions {
public class Equations {
public function Equations(){
trace("Equations is a static class and should not be instantiated.");
}
public static function easeOutBounce(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / _arg4);
if (_arg1 < (1 / 2.75)){
return (((_arg3 * ((7.5625 * _arg1) * _arg1)) + _arg2));
};
if (_arg1 < (2 / 2.75)){
_arg1 = (_arg1 - (1.5 / 2.75));
return (((_arg3 * (((7.5625 * _arg1) * _arg1) + 0.75)) + _arg2));
};
if (_arg1 < (2.5 / 2.75)){
_arg1 = (_arg1 - (2.25 / 2.75));
return (((_arg3 * (((7.5625 * _arg1) * _arg1) + 0.9375)) + _arg2));
};
_arg1 = (_arg1 - (2.625 / 2.75));
return (((_arg3 * (((7.5625 * _arg1) * _arg1) + 0.984375)) + _arg2));
}
public static function easeInOutElastic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN, _arg6:Number=NaN):Number{
var _local7:Number;
if (_arg1 == 0){
return (_arg2);
};
_arg1 = (_arg1 / (_arg4 / 2));
if (_arg1 == 2){
return ((_arg2 + _arg3));
};
if (!_arg6){
_arg6 = (_arg4 * (0.3 * 1.5));
};
if (((!(_arg5)) || ((_arg5 < Math.abs(_arg3))))){
_arg5 = _arg3;
_local7 = (_arg6 / 4);
} else {
_local7 = ((_arg6 / (2 * Math.PI)) * Math.asin((_arg3 / _arg5)));
};
if (_arg1 < 1){
--_arg1;
return (((-0.5 * ((_arg5 * Math.pow(2, (10 * _arg1))) * Math.sin(((((_arg1 * _arg4) - _local7) * (2 * Math.PI)) / _arg6)))) + _arg2));
};
--_arg1;
return ((((((_arg5 * Math.pow(2, (-10 * _arg1))) * Math.sin(((((_arg1 * _arg4) - _local7) * (2 * Math.PI)) / _arg6))) * 0.5) + _arg3) + _arg2));
}
public static function easeInOutQuad(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / (_arg4 / 2));
if (_arg1 < 1){
return (((((_arg3 / 2) * _arg1) * _arg1) + _arg2));
};
--_arg1;
return ((((-(_arg3) / 2) * ((_arg1 * (_arg1 - 2)) - 1)) + _arg2));
}
public static function easeInOutBounce(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
if (_arg1 < (_arg4 / 2)){
return (((easeInBounce((_arg1 * 2), 0, _arg3, _arg4) * 0.5) + _arg2));
};
return ((((easeOutBounce(((_arg1 * 2) - _arg4), 0, _arg3, _arg4) * 0.5) + (_arg3 * 0.5)) + _arg2));
}
public static function easeInOutBack(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN):Number{
if (!_arg5){
_arg5 = 1.70158;
};
_arg1 = (_arg1 / (_arg4 / 2));
if (_arg1 < 1){
_arg5 = (_arg5 * 1.525);
return ((((_arg3 / 2) * ((_arg1 * _arg1) * (((_arg5 + 1) * _arg1) - _arg5))) + _arg2));
};
_arg1 = (_arg1 - 2);
_arg5 = (_arg5 * 1.525);
return ((((_arg3 / 2) * (((_arg1 * _arg1) * (((_arg5 + 1) * _arg1) + _arg5)) + 2)) + _arg2));
}
public static function easeOutInCubic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
if (_arg1 < (_arg4 / 2)){
return (easeOutCubic((_arg1 * 2), _arg2, (_arg3 / 2), _arg4));
};
return (easeInCubic(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4));
}
public static function easeNone(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return ((((_arg3 * _arg1) / _arg4) + _arg2));
}
public static function easeOutBack(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN):Number{
if (!_arg5){
_arg5 = 1.70158;
};
_arg1 = ((_arg1 / _arg4) - 1);
return (((_arg3 * (((_arg1 * _arg1) * (((_arg5 + 1) * _arg1) + _arg5)) + 1)) + _arg2));
}
public static function easeInOutSine(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return ((((-(_arg3) / 2) * (Math.cos(((Math.PI * _arg1) / _arg4)) - 1)) + _arg2));
}
public static function easeInBack(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN):Number{
if (!_arg5){
_arg5 = 1.70158;
};
_arg1 = (_arg1 / _arg4);
return (((((_arg3 * _arg1) * _arg1) * (((_arg5 + 1) * _arg1) - _arg5)) + _arg2));
}
public static function easeInQuart(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / _arg4);
return ((((((_arg3 * _arg1) * _arg1) * _arg1) * _arg1) + _arg2));
}
public static function easeOutInQuint(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
if (_arg1 < (_arg4 / 2)){
return (easeOutQuint((_arg1 * 2), _arg2, (_arg3 / 2), _arg4));
};
return (easeInQuint(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4));
}
public static function easeOutInBounce(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
if (_arg1 < (_arg4 / 2)){
return (easeOutBounce((_arg1 * 2), _arg2, (_arg3 / 2), _arg4));
};
return (easeInBounce(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4));
}
public static function init():void{
Tweener.registerTransition("easenone", easeNone);
Tweener.registerTransition("linear", easeNone);
Tweener.registerTransition("easeinquad", easeInQuad);
Tweener.registerTransition("easeoutquad", easeOutQuad);
Tweener.registerTransition("easeinoutquad", easeInOutQuad);
Tweener.registerTransition("easeoutinquad", easeOutInQuad);
Tweener.registerTransition("easeincubic", easeInCubic);
Tweener.registerTransition("easeoutcubic", easeOutCubic);
Tweener.registerTransition("easeinoutcubic", easeInOutCubic);
Tweener.registerTransition("easeoutincubic", easeOutInCubic);
Tweener.registerTransition("easeinquart", easeInQuart);
Tweener.registerTransition("easeoutquart", easeOutQuart);
Tweener.registerTransition("easeinoutquart", easeInOutQuart);
Tweener.registerTransition("easeoutinquart", easeOutInQuart);
Tweener.registerTransition("easeinquint", easeInQuint);
Tweener.registerTransition("easeoutquint", easeOutQuint);
Tweener.registerTransition("easeinoutquint", easeInOutQuint);
Tweener.registerTransition("easeoutinquint", easeOutInQuint);
Tweener.registerTransition("easeinsine", easeInSine);
Tweener.registerTransition("easeoutsine", easeOutSine);
Tweener.registerTransition("easeinoutsine", easeInOutSine);
Tweener.registerTransition("easeoutinsine", easeOutInSine);
Tweener.registerTransition("easeincirc", easeInCirc);
Tweener.registerTransition("easeoutcirc", easeOutCirc);
Tweener.registerTransition("easeinoutcirc", easeInOutCirc);
Tweener.registerTransition("easeoutincirc", easeOutInCirc);
Tweener.registerTransition("easeinexpo", easeInExpo);
Tweener.registerTransition("easeoutexpo", easeOutExpo);
Tweener.registerTransition("easeinoutexpo", easeInOutExpo);
Tweener.registerTransition("easeoutinexpo", easeOutInExpo);
Tweener.registerTransition("easeinelastic", easeInElastic);
Tweener.registerTransition("easeoutelastic", easeOutElastic);
Tweener.registerTransition("easeinoutelastic", easeInOutElastic);
Tweener.registerTransition("easeoutinelastic", easeOutInElastic);
Tweener.registerTransition("easeinback", easeInBack);
Tweener.registerTransition("easeoutback", easeOutBack);
Tweener.registerTransition("easeinoutback", easeInOutBack);
Tweener.registerTransition("easeoutinback", easeOutInBack);
Tweener.registerTransition("easeinbounce", easeInBounce);
Tweener.registerTransition("easeoutbounce", easeOutBounce);
Tweener.registerTransition("easeinoutbounce", easeInOutBounce);
Tweener.registerTransition("easeoutinbounce", easeOutInBounce);
}
public static function easeOutExpo(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return (((_arg1)==_arg4) ? (_arg2 + _arg3) : (((_arg3 * 1.001) * (-(Math.pow(2, ((-10 * _arg1) / _arg4))) + 1)) + _arg2));
}
public static function easeOutInBack(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN):Number{
if (_arg1 < (_arg4 / 2)){
return (easeOutBack((_arg1 * 2), _arg2, (_arg3 / 2), _arg4, _arg5));
};
return (easeInBack(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4, _arg5));
}
public static function easeInExpo(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return (((_arg1)==0) ? _arg2 : (((_arg3 * Math.pow(2, (10 * ((_arg1 / _arg4) - 1)))) + _arg2) - (_arg3 * 0.001)));
}
public static function easeInCubic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / _arg4);
return (((((_arg3 * _arg1) * _arg1) * _arg1) + _arg2));
}
public static function easeInQuint(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / _arg4);
return (((((((_arg3 * _arg1) * _arg1) * _arg1) * _arg1) * _arg1) + _arg2));
}
public static function easeInOutCirc(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / (_arg4 / 2));
if (_arg1 < 1){
return ((((-(_arg3) / 2) * (Math.sqrt((1 - (_arg1 * _arg1))) - 1)) + _arg2));
};
_arg1 = (_arg1 - 2);
return ((((_arg3 / 2) * (Math.sqrt((1 - (_arg1 * _arg1))) + 1)) + _arg2));
}
public static function easeInQuad(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / _arg4);
return ((((_arg3 * _arg1) * _arg1) + _arg2));
}
public static function easeInBounce(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return (((_arg3 - easeOutBounce((_arg4 - _arg1), 0, _arg3, _arg4)) + _arg2));
}
public static function easeOutInExpo(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
if (_arg1 < (_arg4 / 2)){
return (easeOutExpo((_arg1 * 2), _arg2, (_arg3 / 2), _arg4));
};
return (easeInExpo(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4));
}
public static function easeOutQuart(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = ((_arg1 / _arg4) - 1);
return (((-(_arg3) * ((((_arg1 * _arg1) * _arg1) * _arg1) - 1)) + _arg2));
}
public static function easeInSine(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return ((((-(_arg3) * Math.cos(((_arg1 / _arg4) * (Math.PI / 2)))) + _arg3) + _arg2));
}
public static function easeInOutQuart(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / (_arg4 / 2));
if (_arg1 < 1){
return (((((((_arg3 / 2) * _arg1) * _arg1) * _arg1) * _arg1) + _arg2));
};
_arg1 = (_arg1 - 2);
return ((((-(_arg3) / 2) * ((((_arg1 * _arg1) * _arg1) * _arg1) - 2)) + _arg2));
}
public static function easeOutQuad(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / _arg4);
return ((((-(_arg3) * _arg1) * (_arg1 - 2)) + _arg2));
}
public static function easeOutInElastic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN, _arg6:Number=NaN):Number{
if (_arg1 < (_arg4 / 2)){
return (easeOutElastic((_arg1 * 2), _arg2, (_arg3 / 2), _arg4, _arg5, _arg6));
};
return (easeInElastic(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4, _arg5, _arg6));
}
public static function easeInElastic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN, _arg6:Number=NaN):Number{
var _local7:Number;
if (_arg1 == 0){
return (_arg2);
};
_arg1 = (_arg1 / _arg4);
if (_arg1 == 1){
return ((_arg2 + _arg3));
};
if (!_arg6){
_arg6 = (_arg4 * 0.3);
};
if (((!(_arg5)) || ((_arg5 < Math.abs(_arg3))))){
_arg5 = _arg3;
_local7 = (_arg6 / 4);
} else {
_local7 = ((_arg6 / (2 * Math.PI)) * Math.asin((_arg3 / _arg5)));
};
--_arg1;
return ((-(((_arg5 * Math.pow(2, (10 * _arg1))) * Math.sin(((((_arg1 * _arg4) - _local7) * (2 * Math.PI)) / _arg6)))) + _arg2));
}
public static function easeOutCubic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = ((_arg1 / _arg4) - 1);
return (((_arg3 * (((_arg1 * _arg1) * _arg1) + 1)) + _arg2));
}
public static function easeOutQuint(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = ((_arg1 / _arg4) - 1);
return (((_arg3 * (((((_arg1 * _arg1) * _arg1) * _arg1) * _arg1) + 1)) + _arg2));
}
public static function easeOutInQuad(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
if (_arg1 < (_arg4 / 2)){
return (easeOutQuad((_arg1 * 2), _arg2, (_arg3 / 2), _arg4));
};
return (easeInQuad(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4));
}
public static function easeOutSine(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return (((_arg3 * Math.sin(((_arg1 / _arg4) * (Math.PI / 2)))) + _arg2));
}
public static function easeInOutCubic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / (_arg4 / 2));
if (_arg1 < 1){
return ((((((_arg3 / 2) * _arg1) * _arg1) * _arg1) + _arg2));
};
_arg1 = (_arg1 - 2);
return ((((_arg3 / 2) * (((_arg1 * _arg1) * _arg1) + 2)) + _arg2));
}
public static function easeInOutQuint(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / (_arg4 / 2));
if (_arg1 < 1){
return ((((((((_arg3 / 2) * _arg1) * _arg1) * _arg1) * _arg1) * _arg1) + _arg2));
};
_arg1 = (_arg1 - 2);
return ((((_arg3 / 2) * (((((_arg1 * _arg1) * _arg1) * _arg1) * _arg1) + 2)) + _arg2));
}
public static function easeInCirc(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / _arg4);
return (((-(_arg3) * (Math.sqrt((1 - (_arg1 * _arg1))) - 1)) + _arg2));
}
public static function easeOutInSine(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
if (_arg1 < (_arg4 / 2)){
return (easeOutSine((_arg1 * 2), _arg2, (_arg3 / 2), _arg4));
};
return (easeInSine(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4));
}
public static function easeInOutExpo(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
if (_arg1 == 0){
return (_arg2);
};
if (_arg1 == _arg4){
return ((_arg2 + _arg3));
};
_arg1 = (_arg1 / (_arg4 / 2));
if (_arg1 < 1){
return (((((_arg3 / 2) * Math.pow(2, (10 * (_arg1 - 1)))) + _arg2) - (_arg3 * 0.0005)));
};
--_arg1;
return (((((_arg3 / 2) * 1.0005) * (-(Math.pow(2, (-10 * _arg1))) + 2)) + _arg2));
}
public static function easeOutElastic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN, _arg6:Number=NaN):Number{
var _local7:Number;
if (_arg1 == 0){
return (_arg2);
};
_arg1 = (_arg1 / _arg4);
if (_arg1 == 1){
return ((_arg2 + _arg3));
};
if (!_arg6){
_arg6 = (_arg4 * 0.3);
};
if (((!(_arg5)) || ((_arg5 < Math.abs(_arg3))))){
_arg5 = _arg3;
_local7 = (_arg6 / 4);
} else {
_local7 = ((_arg6 / (2 * Math.PI)) * Math.asin((_arg3 / _arg5)));
};
return (((((_arg5 * Math.pow(2, (-10 * _arg1))) * Math.sin(((((_arg1 * _arg4) - _local7) * (2 * Math.PI)) / _arg6))) + _arg3) + _arg2));
}
public static function easeOutCirc(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = ((_arg1 / _arg4) - 1);
return (((_arg3 * Math.sqrt((1 - (_arg1 * _arg1)))) + _arg2));
}
public static function easeOutInQuart(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
if (_arg1 < (_arg4 / 2)){
return (easeOutQuart((_arg1 * 2), _arg2, (_arg3 / 2), _arg4));
};
return (easeInQuart(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4));
}
public static function easeOutInCirc(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
if (_arg1 < (_arg4 / 2)){
return (easeOutCirc((_arg1 * 2), _arg2, (_arg3 / 2), _arg4));
};
return (easeInCirc(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4));
}
}
}//package caurina.transitions
Section 3
//PropertyInfoObj (caurina.transitions.PropertyInfoObj)
package caurina.transitions {
public class PropertyInfoObj {
public var modifierParameters:Array;
public var valueComplete:Number;
public var modifierFunction:Function;
public var hasModifier:Boolean;
public var valueStart:Number;
public function PropertyInfoObj(_arg1:Number, _arg2:Number, _arg3:Function, _arg4:Array){
valueStart = _arg1;
valueComplete = _arg2;
hasModifier = Boolean(_arg3);
modifierFunction = _arg3;
modifierParameters = _arg4;
}
public function toString():String{
var _local1:String;
_local1 = "\n[PropertyInfoObj ";
_local1 = (_local1 + ("valueStart:" + String(valueStart)));
_local1 = (_local1 + ", ");
_local1 = (_local1 + ("valueComplete:" + String(valueComplete)));
_local1 = (_local1 + ", ");
_local1 = (_local1 + ("modifierFunction:" + String(modifierFunction)));
_local1 = (_local1 + ", ");
_local1 = (_local1 + ("modifierParameters:" + String(modifierParameters)));
_local1 = (_local1 + "]\n");
return (_local1);
}
public function clone():PropertyInfoObj{
var _local1:PropertyInfoObj;
_local1 = new PropertyInfoObj(valueStart, valueComplete, modifierFunction, modifierParameters);
return (_local1);
}
}
}//package caurina.transitions
Section 4
//SpecialPropertiesDefault (caurina.transitions.SpecialPropertiesDefault)
package caurina.transitions {
import flash.filters.*;
import flash.media.*;
import flash.geom.*;
public class SpecialPropertiesDefault {
public function SpecialPropertiesDefault(){
trace("SpecialProperties is a static class and should not be instantiated.");
}
public static function _sound_volume_get(_arg1:Object):Number{
return (_arg1.soundTransform.volume);
}
public static function _color_splitter(_arg1, _arg2:Array):Array{
var _local3:Array;
_local3 = new Array();
if (_arg1 == null){
_local3.push({name:"_color_ra", value:1});
_local3.push({name:"_color_rb", value:0});
_local3.push({name:"_color_ga", value:1});
_local3.push({name:"_color_gb", value:0});
_local3.push({name:"_color_ba", value:1});
_local3.push({name:"_color_bb", value:0});
} else {
_local3.push({name:"_color_ra", value:0});
_local3.push({name:"_color_rb", value:AuxFunctions.numberToR(_arg1)});
_local3.push({name:"_color_ga", value:0});
_local3.push({name:"_color_gb", value:AuxFunctions.numberToG(_arg1)});
_local3.push({name:"_color_ba", value:0});
_local3.push({name:"_color_bb", value:AuxFunctions.numberToB(_arg1)});
};
return (_local3);
}
public static function frame_get(_arg1:Object):Number{
return (_arg1.currentFrame);
}
public static function _sound_pan_get(_arg1:Object):Number{
return (_arg1.soundTransform.pan);
}
public static function _color_property_get(_arg1:Object, _arg2:Array):Number{
return (_arg1.transform.colorTransform[_arg2[0]]);
}
public static function _sound_volume_set(_arg1:Object, _arg2:Number):void{
var _local3:SoundTransform;
_local3 = _arg1.soundTransform;
_local3.volume = _arg2;
_arg1.soundTransform = _local3;
}
public static function _autoAlpha_get(_arg1:Object):Number{
return (_arg1.alpha);
}
public static function _filter_splitter(_arg1:BitmapFilter, _arg2:Array):Array{
var _local3:Array;
_local3 = new Array();
if ((_arg1 is BlurFilter)){
_local3.push({name:"_blur_blurX", value:BlurFilter(_arg1).blurX});
_local3.push({name:"_blur_blurY", value:BlurFilter(_arg1).blurY});
_local3.push({name:"_blur_quality", value:BlurFilter(_arg1).quality});
} else {
trace("??");
};
return (_local3);
}
public static function init():void{
Tweener.registerSpecialProperty("_frame", frame_get, frame_set);
Tweener.registerSpecialProperty("_sound_volume", _sound_volume_get, _sound_volume_set);
Tweener.registerSpecialProperty("_sound_pan", _sound_pan_get, _sound_pan_set);
Tweener.registerSpecialProperty("_color_ra", _color_property_get, _color_property_set, ["redMultiplier"]);
Tweener.registerSpecialProperty("_color_rb", _color_property_get, _color_property_set, ["redOffset"]);
Tweener.registerSpecialProperty("_color_ga", _color_property_get, _color_property_set, ["greenMultiplier"]);
Tweener.registerSpecialProperty("_color_gb", _color_property_get, _color_property_set, ["greenOffset"]);
Tweener.registerSpecialProperty("_color_ba", _color_property_get, _color_property_set, ["blueMultiplier"]);
Tweener.registerSpecialProperty("_color_bb", _color_property_get, _color_property_set, ["blueOffset"]);
Tweener.registerSpecialProperty("_color_aa", _color_property_get, _color_property_set, ["alphaMultiplier"]);
Tweener.registerSpecialProperty("_color_ab", _color_property_get, _color_property_set, ["alphaOffset"]);
Tweener.registerSpecialProperty("_autoAlpha", _autoAlpha_get, _autoAlpha_set);
Tweener.registerSpecialPropertySplitter("_color", _color_splitter);
Tweener.registerSpecialPropertySplitter("_colorTransform", _colorTransform_splitter);
Tweener.registerSpecialPropertySplitter("_scale", _scale_splitter);
Tweener.registerSpecialProperty("_blur_blurX", _filter_property_get, _filter_property_set, [BlurFilter, "blurX"]);
Tweener.registerSpecialProperty("_blur_blurY", _filter_property_get, _filter_property_set, [BlurFilter, "blurY"]);
Tweener.registerSpecialProperty("_blur_quality", _filter_property_get, _filter_property_set, [BlurFilter, "quality"]);
Tweener.registerSpecialPropertySplitter("_filter", _filter_splitter);
Tweener.registerSpecialPropertyModifier("_bezier", _bezier_modifier, _bezier_get);
}
public static function _sound_pan_set(_arg1:Object, _arg2:Number):void{
var _local3:SoundTransform;
_local3 = _arg1.soundTransform;
_local3.pan = _arg2;
_arg1.soundTransform = _local3;
}
public static function _color_property_set(_arg1:Object, _arg2:Number, _arg3:Array):void{
var _local4:ColorTransform;
_local4 = _arg1.transform.colorTransform;
_local4[_arg3[0]] = _arg2;
_arg1.transform.colorTransform = _local4;
}
public static function _filter_property_get(_arg1:Object, _arg2:Array):Number{
var _local3:Array;
var _local4:uint;
var _local5:Object;
var _local6:String;
var _local7:Object;
_local3 = _arg1.filters;
_local5 = _arg2[0];
_local6 = _arg2[1];
_local4 = 0;
while (_local4 < _local3.length) {
if ((((_local3[_local4] is BlurFilter)) && ((_local5 == BlurFilter)))){
return (_local3[_local4][_local6]);
};
_local4++;
};
switch (_local5){
case BlurFilter:
_local7 = {blurX:0, blurY:0, quality:NaN};
break;
};
return (_local7[_local6]);
}
public static function _bezier_get(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Array):Number{
var _local5:uint;
var _local6:Number;
var _local7:Number;
var _local8:Number;
if (_arg4.length == 1){
return ((_arg1 + (_arg3 * (((2 * (1 - _arg3)) * (_arg4[0] - _arg1)) + (_arg3 * (_arg2 - _arg1))))));
};
_local5 = Math.floor((_arg3 * _arg4.length));
_local6 = ((_arg3 - (_local5 * (1 / _arg4.length))) * _arg4.length);
if (_local5 == 0){
_local7 = _arg1;
_local8 = ((_arg4[0] + _arg4[1]) / 2);
} else {
if (_local5 == (_arg4.length - 1)){
_local7 = ((_arg4[(_local5 - 1)] + _arg4[_local5]) / 2);
_local8 = _arg2;
} else {
_local7 = ((_arg4[(_local5 - 1)] + _arg4[_local5]) / 2);
_local8 = ((_arg4[_local5] + _arg4[(_local5 + 1)]) / 2);
};
};
return ((_local7 + (_local6 * (((2 * (1 - _local6)) * (_arg4[_local5] - _local7)) + (_local6 * (_local8 - _local7))))));
}
public static function frame_set(_arg1:Object, _arg2:Number):void{
_arg1.gotoAndStop(Math.round(_arg2));
}
public static function _filter_property_set(_arg1:Object, _arg2:Number, _arg3:Array):void{
var _local4:Array;
var _local5:uint;
var _local6:Object;
var _local7:String;
var _local8:BitmapFilter;
_local4 = _arg1.filters;
_local6 = _arg3[0];
_local7 = _arg3[1];
_local5 = 0;
while (_local5 < _local4.length) {
if ((((_local4[_local5] is BlurFilter)) && ((_local6 == BlurFilter)))){
_local4[_local5][_local7] = _arg2;
_arg1.filters = _local4;
return;
};
_local5++;
};
if (_local4 == null){
_local4 = new Array();
};
switch (_local6){
case BlurFilter:
_local8 = new BlurFilter(0, 0);
break;
};
_local8[_local7] = _arg2;
_local4.push(_local8);
_arg1.filters = _local4;
}
public static function _autoAlpha_set(_arg1:Object, _arg2:Number):void{
_arg1.alpha = _arg2;
_arg1.visible = (_arg2 > 0);
}
public static function _scale_splitter(_arg1:Number, _arg2:Array):Array{
var _local3:Array;
_local3 = new Array();
_local3.push({name:"scaleX", value:_arg1});
_local3.push({name:"scaleY", value:_arg1});
return (_local3);
}
public static function _colorTransform_splitter(_arg1, _arg2:Array):Array{
var _local3:Array;
_local3 = new Array();
if (_arg1 == null){
_local3.push({name:"_color_ra", value:1});
_local3.push({name:"_color_rb", value:0});
_local3.push({name:"_color_ga", value:1});
_local3.push({name:"_color_gb", value:0});
_local3.push({name:"_color_ba", value:1});
_local3.push({name:"_color_bb", value:0});
} else {
if (_arg1.ra != undefined){
_local3.push({name:"_color_ra", value:_arg1.ra});
};
if (_arg1.rb != undefined){
_local3.push({name:"_color_rb", value:_arg1.rb});
};
if (_arg1.ga != undefined){
_local3.push({name:"_color_ba", value:_arg1.ba});
};
if (_arg1.gb != undefined){
_local3.push({name:"_color_bb", value:_arg1.bb});
};
if (_arg1.ba != undefined){
_local3.push({name:"_color_ga", value:_arg1.ga});
};
if (_arg1.bb != undefined){
_local3.push({name:"_color_gb", value:_arg1.gb});
};
if (_arg1.aa != undefined){
_local3.push({name:"_color_aa", value:_arg1.aa});
};
if (_arg1.ab != undefined){
_local3.push({name:"_color_ab", value:_arg1.ab});
};
};
return (_local3);
}
public static function _bezier_modifier(_arg1):Array{
var _local2:Array;
var _local3:Array;
var _local4:uint;
var _local5:String;
var _local6:Object;
_local2 = [];
if ((_arg1 is Array)){
_local3 = _arg1;
} else {
_local3 = [_arg1];
};
_local6 = {};
_local4 = 0;
while (_local4 < _local3.length) {
for (_local5 in _local3[_local4]) {
if (_local6[_local5] == undefined){
_local6[_local5] = [];
};
_local6[_local5].push(_local3[_local4][_local5]);
};
_local4++;
};
for (_local5 in _local6) {
_local2.push({name:_local5, parameters:_local6[_local5]});
};
return (_local2);
}
}
}//package caurina.transitions
Section 5
//SpecialProperty (caurina.transitions.SpecialProperty)
package caurina.transitions {
public class SpecialProperty {
public var parameters:Array;
public var getValue:Function;
public var setValue:Function;
public function SpecialProperty(_arg1:Function, _arg2:Function, _arg3:Array=null){
getValue = _arg1;
setValue = _arg2;
parameters = _arg3;
}
public function toString():String{
var _local1:String;
_local1 = "";
_local1 = (_local1 + "[SpecialProperty ");
_local1 = (_local1 + ("getValue:" + String(getValue)));
_local1 = (_local1 + ", ");
_local1 = (_local1 + ("setValue:" + String(setValue)));
_local1 = (_local1 + ", ");
_local1 = (_local1 + ("parameters:" + String(parameters)));
_local1 = (_local1 + "]");
return (_local1);
}
}
}//package caurina.transitions
Section 6
//SpecialPropertyModifier (caurina.transitions.SpecialPropertyModifier)
package caurina.transitions {
public class SpecialPropertyModifier {
public var getValue:Function;
public var modifyValues:Function;
public function SpecialPropertyModifier(_arg1:Function, _arg2:Function){
modifyValues = _arg1;
getValue = _arg2;
}
public function toString():String{
var _local1:String;
_local1 = "";
_local1 = (_local1 + "[SpecialPropertyModifier ");
_local1 = (_local1 + ("modifyValues:" + String(modifyValues)));
_local1 = (_local1 + ", ");
_local1 = (_local1 + ("getValue:" + String(getValue)));
_local1 = (_local1 + "]");
return (_local1);
}
}
}//package caurina.transitions
Section 7
//SpecialPropertySplitter (caurina.transitions.SpecialPropertySplitter)
package caurina.transitions {
public class SpecialPropertySplitter {
public var parameters:Array;
public var splitValues:Function;
public function SpecialPropertySplitter(_arg1:Function, _arg2:Array){
splitValues = _arg1;
}
public function toString():String{
var _local1:String;
_local1 = "";
_local1 = (_local1 + "[SpecialPropertySplitter ");
_local1 = (_local1 + ("splitValues:" + String(splitValues)));
_local1 = (_local1 + ", ");
_local1 = (_local1 + ("parameters:" + String(parameters)));
_local1 = (_local1 + "]");
return (_local1);
}
}
}//package caurina.transitions
Section 8
//Tweener (caurina.transitions.Tweener)
package caurina.transitions {
import flash.events.*;
import flash.display.*;
import flash.utils.*;
public class Tweener {
private static var _timeScale:Number = 1;
private static var _specialPropertySplitterList:Object;
private static var _engineExists:Boolean = false;
private static var _specialPropertyModifierList:Object;
private static var _currentTime:Number;
private static var _tweenList:Array;
private static var _specialPropertyList:Object;
private static var _transitionList:Object;
private static var _inited:Boolean = false;
private static var __tweener_controller__:MovieClip;
public function Tweener(){
trace("Tweener is a static class and should not be instantiated.");
}
public static function registerSpecialPropertyModifier(_arg1:String, _arg2:Function, _arg3:Function):void{
var _local4:SpecialPropertyModifier;
if (!_inited){
init();
};
_local4 = new SpecialPropertyModifier(_arg2, _arg3);
_specialPropertyModifierList[_arg1] = _local4;
}
public static function registerSpecialProperty(_arg1:String, _arg2:Function, _arg3:Function, _arg4:Array=null):void{
var _local5:SpecialProperty;
if (!_inited){
init();
};
_local5 = new SpecialProperty(_arg2, _arg3, _arg4);
_specialPropertyList[_arg1] = _local5;
}
public static function addCaller(_arg1:Object=null, _arg2:Object=null):Boolean{
var _local4:Array;
var _local5:Number;
var _local6:Number;
var _local7:Object;
var _local8:Number;
var _local9:Number;
var _local10:Function;
var _local11:TweenListObj;
var _local12:Number;
var _local13:String;
if ((((arguments.length < 2)) || ((arguments[0] == undefined)))){
return (false);
};
_local4 = new Array();
if ((arguments[0] is Array)){
_local5 = 0;
while (_local5 < arguments[0].length) {
_local4.push(arguments[0][_local5]);
_local5++;
};
} else {
_local5 = 0;
while (_local5 < (arguments.length - 1)) {
_local4.push(arguments[_local5]);
_local5++;
};
};
_local7 = arguments[(arguments.length - 1)];
if (!_inited){
init();
};
if (((!(_engineExists)) || (!(Boolean(__tweener_controller__))))){
startEngine();
};
_local8 = (isNaN(_local7.time)) ? 0 : _local7.time;
_local9 = (isNaN(_local7.delay)) ? 0 : _local7.delay;
if (typeof(_local7.transition) == "string"){
_local13 = _local7.transition.toLowerCase();
_local10 = _transitionList[_local13];
} else {
_local10 = _local7.transition;
};
if (!Boolean(_local10)){
_local10 = _transitionList["easeoutexpo"];
};
_local5 = 0;
while (_local5 < _local4.length) {
_local11 = new TweenListObj(_local4[_local5], (_currentTime + ((_local9 * 1000) / _timeScale)), (_currentTime + (((_local9 * 1000) + (_local8 * 1000)) / _timeScale)), (_local7.useFrames == true), _local10);
_local11.properties = null;
_local11.onStart = _local7.onStart;
_local11.onUpdate = _local7.onUpdate;
_local11.onComplete = _local7.onComplete;
_local11.onOverwrite = _local7.onOverwrite;
_local11.onStartParams = _local7.onStartParams;
_local11.onUpdateParams = _local7.onUpdateParams;
_local11.onCompleteParams = _local7.onCompleteParams;
_local11.onOverwriteParams = _local7.onOverwriteParams;
_local11.isCaller = true;
_local11.count = _local7.count;
_local11.waitFrames = _local7.waitFrames;
_tweenList.push(_local11);
if ((((_local8 == 0)) && ((_local9 == 0)))){
_local12 = (_tweenList.length - 1);
updateTweenByIndex(_local12);
removeTweenByIndex(_local12);
};
_local5++;
};
return (true);
}
public static function init(_arg1=null):void{
_inited = true;
_transitionList = new Object();
Equations.init();
_specialPropertyList = new Object();
_specialPropertyModifierList = new Object();
_specialPropertySplitterList = new Object();
SpecialPropertiesDefault.init();
}
private static function updateTweens():Boolean{
var _local1:int;
if (_tweenList.length == 0){
return (false);
};
_local1 = 0;
while (_local1 < _tweenList.length) {
if ((((_tweenList[_local1] == undefined)) || (!(_tweenList[_local1].isPaused)))){
if (!updateTweenByIndex(_local1)){
removeTweenByIndex(_local1);
};
if (_tweenList[_local1] == null){
removeTweenByIndex(_local1, true);
_local1--;
};
};
_local1++;
};
return (true);
}
public static function removeTweens(_arg1:Object, ... _args):Boolean{
var _local3:Array;
var _local4:uint;
_local3 = new Array();
_local4 = 0;
while (_local4 < _args.length) {
if ((((typeof(_args[_local4]) == "string")) && (!(AuxFunctions.isInArray(_args[_local4], _local3))))){
_local3.push(_args[_local4]);
};
_local4++;
};
return (affectTweens(removeTweenByIndex, _arg1, _local3));
}
public static function pauseAllTweens():Boolean{
var _local1:Boolean;
var _local2:uint;
if (!Boolean(_tweenList)){
return (false);
};
_local1 = false;
_local2 = 0;
while (_local2 < _tweenList.length) {
pauseTweenByIndex(_local2);
_local1 = true;
_local2++;
};
return (_local1);
}
public static function splitTweens(_arg1:Number, _arg2:Array):uint{
var _local3:TweenListObj;
var _local4:TweenListObj;
var _local5:uint;
var _local6:String;
var _local7:Boolean;
_local3 = _tweenList[_arg1];
_local4 = _local3.clone(false);
_local5 = 0;
while (_local5 < _arg2.length) {
_local6 = _arg2[_local5];
if (Boolean(_local3.properties[_local6])){
_local3.properties[_local6] = undefined;
delete _local3.properties[_local6];
};
_local5++;
};
for (_local6 in _local4.properties) {
_local7 = false;
_local5 = 0;
while (_local5 < _arg2.length) {
if (_arg2[_local5] == _local6){
_local7 = true;
break;
};
_local5++;
};
if (!_local7){
_local4.properties[_local6] = undefined;
delete _local4.properties[_local6];
};
};
_tweenList.push(_local4);
return ((_tweenList.length - 1));
}
public static function resumeTweenByIndex(_arg1:Number):Boolean{
var _local2:TweenListObj;
_local2 = _tweenList[_arg1];
if ((((_local2 == null)) || (!(_local2.isPaused)))){
return (false);
};
_local2.timeStart = (_local2.timeStart + (_currentTime - _local2.timePaused));
_local2.timeComplete = (_local2.timeComplete + (_currentTime - _local2.timePaused));
_local2.timePaused = undefined;
_local2.isPaused = false;
return (true);
}
public static function debug_getList():String{
var _local1:String;
var _local2:uint;
var _local3:uint;
_local1 = "";
_local2 = 0;
while (_local2 < _tweenList.length) {
_local1 = (_local1 + (("[" + _local2) + "] ::\n"));
_local3 = 0;
while (_local3 < _tweenList[_local2].properties.length) {
_local1 = (_local1 + ((((" " + _tweenList[_local2].properties[_local3].name) + " -> ") + _tweenList[_local2].properties[_local3].valueComplete) + "\n"));
_local3++;
};
_local2++;
};
return (_local1);
}
public static function getVersion():String{
return ("AS3 1.26.62");
}
public static function onEnterFrame(_arg1:Event):void{
var _local2:Boolean;
updateTime();
_local2 = false;
_local2 = updateTweens();
if (!_local2){
stopEngine();
};
}
public static function updateTime():void{
_currentTime = getTimer();
}
private static function updateTweenByIndex(_arg1:Number):Boolean{
var tTweening:TweenListObj;
var isOver:Boolean;
var mustUpdate:Boolean;
var nv:Number;
var t:Number;
var b:Number;
var c:Number;
var d:Number;
var pName:String;
var tScope:Object;
var tProperty:Object;
var pv:Number;
var i = _arg1;
tTweening = _tweenList[i];
if ((((tTweening == null)) || (!(Boolean(tTweening.scope))))){
return (false);
};
isOver = false;
if (_currentTime >= tTweening.timeStart){
tScope = tTweening.scope;
if (tTweening.isCaller){
do {
t = (((tTweening.timeComplete - tTweening.timeStart) / tTweening.count) * (tTweening.timesCalled + 1));
b = tTweening.timeStart;
c = (tTweening.timeComplete - tTweening.timeStart);
d = (tTweening.timeComplete - tTweening.timeStart);
nv = tTweening.transition(t, b, c, d);
} while (!(_currentTime >= nv));
} else {
mustUpdate = (((((tTweening.skipUpdates < 1)) || (!(tTweening.skipUpdates)))) || ((tTweening.updatesSkipped >= tTweening.skipUpdates)));
if (_currentTime >= tTweening.timeComplete){
isOver = true;
mustUpdate = true;
};
if (!tTweening.hasStarted){
if (Boolean(tTweening.onStart)){
try {
tTweening.onStart.apply(tScope, tTweening.onStartParams);
} catch(e:Error) {
handleError(tTweening, e, "onStart");
};
};
for (pName in tTweening.properties) {
pv = getPropertyValue(tScope, pName);
tTweening.properties[pName].valueStart = (isNaN(pv)) ? tTweening.properties[pName].valueComplete : pv;
};
mustUpdate = true;
tTweening.hasStarted = true;
};
if (mustUpdate){
for (pName in tTweening.properties) {
tProperty = tTweening.properties[pName];
if (isOver){
nv = tProperty.valueComplete;
} else {
if (tProperty.hasModifier){
t = (_currentTime - tTweening.timeStart);
d = (tTweening.timeComplete - tTweening.timeStart);
nv = tTweening.transition(t, 0, 1, d);
nv = tProperty.modifierFunction(tProperty.valueStart, tProperty.valueComplete, nv, tProperty.modifierParameters);
} else {
t = (_currentTime - tTweening.timeStart);
b = tProperty.valueStart;
c = (tProperty.valueComplete - tProperty.valueStart);
d = (tTweening.timeComplete - tTweening.timeStart);
nv = tTweening.transition(t, b, c, d);
};
};
if (tTweening.rounded){
nv = Math.round(nv);
};
setPropertyValue(tScope, pName, nv);
};
tTweening.updatesSkipped = 0;
if (Boolean(tTweening.onUpdate)){
try {
tTweening.onUpdate.apply(tScope, tTweening.onUpdateParams);
} catch(e:Error) {
handleError(tTweening, e, "onUpdate");
};
};
} else {
tTweening.updatesSkipped++;
};
};
if (((isOver) && (Boolean(tTweening.onComplete)))){
try {
tTweening.onComplete.apply(tScope, tTweening.onCompleteParams);
} catch(e:Error) {
handleError(tTweening, e, "onComplete");
};
};
return (!(isOver));
};
return (true);
}
public static function setTimeScale(_arg1:Number):void{
var _local2:Number;
if (isNaN(_arg1)){
_arg1 = 1;
};
if (_arg1 < 1E-5){
_arg1 = 1E-5;
};
if (_arg1 != _timeScale){
if (_tweenList != null){
_local2 = 0;
while (_local2 < _tweenList.length) {
_tweenList[_local2].timeStart = (_currentTime - (((_currentTime - _tweenList[_local2].timeStart) * _timeScale) / _arg1));
_tweenList[_local2].timeComplete = (_currentTime - (((_currentTime - _tweenList[_local2].timeComplete) * _timeScale) / _arg1));
if (_tweenList[_local2].timePaused != undefined){
_tweenList[_local2].timePaused = (_currentTime - (((_currentTime - _tweenList[_local2].timePaused) * _timeScale) / _arg1));
};
_local2++;
};
};
_timeScale = _arg1;
};
}
public static function resumeAllTweens():Boolean{
var _local1:Boolean;
var _local2:uint;
if (!Boolean(_tweenList)){
return (false);
};
_local1 = false;
_local2 = 0;
while (_local2 < _tweenList.length) {
resumeTweenByIndex(_local2);
_local1 = true;
_local2++;
};
return (_local1);
}
private static function handleError(_arg1:TweenListObj, _arg2:Error, _arg3:String):void{
var pTweening = _arg1;
var pError = _arg2;
var pCallBackName = _arg3;
if (((Boolean(pTweening.onError)) && ((pTweening.onError is Function)))){
try {
pTweening.onError.apply(pTweening.scope, [pTweening.scope, pError]);
} catch(metaError:Error) {
trace("## [Tweener] Error:", pTweening.scope, "raised an error while executing the 'onError' handler. Original error:\n", pError.getStackTrace(), "\nonError error:", metaError.getStackTrace());
};
} else {
if (!Boolean(pTweening.onError)){
trace("## [Tweener] Error: :", pTweening.scope, (("raised an error while executing the'" + pCallBackName) + "'handler. \n"), pError.getStackTrace());
};
};
}
private static function startEngine():void{
_engineExists = true;
_tweenList = new Array();
__tweener_controller__ = new MovieClip();
__tweener_controller__.addEventListener(Event.ENTER_FRAME, Tweener.onEnterFrame);
updateTime();
}
public static function removeAllTweens():Boolean{
var _local1:Boolean;
var _local2:uint;
if (!Boolean(_tweenList)){
return (false);
};
_local1 = false;
_local2 = 0;
while (_local2 < _tweenList.length) {
removeTweenByIndex(_local2);
_local1 = true;
_local2++;
};
return (_local1);
}
public static function addTween(_arg1:Object=null, _arg2:Object=null):Boolean{
var _local4:Array;
var _local5:Number;
var _local6:Number;
var _local7:String;
var _local8:String;
var _local9:Object;
var _local10:Number;
var _local11:Number;
var _local12:Array;
var _local13:Object;
var _local14:Object;
var _local15:Function;
var _local16:Object;
var _local17:TweenListObj;
var _local18:Number;
var _local19:Array;
var _local20:Array;
var _local21:String;
if ((((arguments.length < 2)) || ((arguments[0] == undefined)))){
return (false);
};
_local4 = new Array();
if ((arguments[0] is Array)){
_local5 = 0;
while (_local5 < arguments[0].length) {
_local4.push(arguments[0][_local5]);
_local5++;
};
} else {
_local5 = 0;
while (_local5 < (arguments.length - 1)) {
_local4.push(arguments[_local5]);
_local5++;
};
};
_local9 = TweenListObj.makePropertiesChain(arguments[(arguments.length - 1)]);
if (!_inited){
init();
};
if (((!(_engineExists)) || (!(Boolean(__tweener_controller__))))){
startEngine();
};
_local10 = (isNaN(_local9.time)) ? 0 : _local9.time;
_local11 = (isNaN(_local9.delay)) ? 0 : _local9.delay;
_local12 = new Array();
_local13 = {time:true, delay:true, useFrames:true, skipUpdates:true, transition:true, onStart:true, onUpdate:true, onComplete:true, onOverwrite:true, rounded:true, onStartParams:true, onUpdateParams:true, onCompleteParams:true, onOverwriteParams:true};
_local14 = new Object();
for (_local7 in _local9) {
if (!_local13[_local7]){
if (_specialPropertySplitterList[_local7]){
_local19 = _specialPropertySplitterList[_local7].splitValues(_local9[_local7], _specialPropertySplitterList[_local7].parameters);
_local5 = 0;
while (_local5 < _local19.length) {
_local12[_local19[_local5].name] = {valueStart:undefined, valueComplete:_local19[_local5].value};
_local5++;
};
} else {
if (_specialPropertyModifierList[_local7] != undefined){
_local20 = _specialPropertyModifierList[_local7].modifyValues(_local9[_local7]);
_local5 = 0;
while (_local5 < _local20.length) {
_local14[_local20[_local5].name] = {modifierParameters:_local20[_local5].parameters, modifierFunction:_specialPropertyModifierList[_local7].getValue};
_local5++;
};
} else {
_local12[_local7] = {valueStart:undefined, valueComplete:_local9[_local7]};
};
};
};
};
for (_local7 in _local14) {
if (_local12[_local7] != undefined){
_local12[_local7].modifierParameters = _local14[_local7].modifierParameters;
_local12[_local7].modifierFunction = _local14[_local7].modifierFunction;
};
};
if (typeof(_local9.transition) == "string"){
_local21 = _local9.transition.toLowerCase();
_local15 = _transitionList[_local21];
} else {
_local15 = _local9.transition;
};
if (!Boolean(_local15)){
_local15 = _transitionList["easeoutexpo"];
};
_local5 = 0;
while (_local5 < _local4.length) {
_local16 = new Object();
for (_local7 in _local12) {
_local16[_local7] = new PropertyInfoObj(_local12[_local7].valueStart, _local12[_local7].valueComplete, _local12[_local7].modifierFunction, _local12[_local7].modifierParameters);
};
_local17 = new TweenListObj(_local4[_local5], (_currentTime + ((_local11 * 1000) / _timeScale)), (_currentTime + (((_local11 * 1000) + (_local10 * 1000)) / _timeScale)), (_local9.useFrames == true), _local15);
_local17.properties = _local16;
_local17.onStart = _local9.onStart;
_local17.onUpdate = _local9.onUpdate;
_local17.onComplete = _local9.onComplete;
_local17.onOverwrite = _local9.onOverwrite;
_local17.onError = _local9.onError;
_local17.onStartParams = _local9.onStartParams;
_local17.onUpdateParams = _local9.onUpdateParams;
_local17.onCompleteParams = _local9.onCompleteParams;
_local17.onOverwriteParams = _local9.onOverwriteParams;
_local17.rounded = _local9.rounded;
_local17.skipUpdates = _local9.skipUpdates;
removeTweensByTime(_local17.scope, _local17.properties, _local17.timeStart, _local17.timeComplete);
_tweenList.push(_local17);
if ((((_local10 == 0)) && ((_local11 == 0)))){
_local18 = (_tweenList.length - 1);
updateTweenByIndex(_local18);
removeTweenByIndex(_local18);
};
_local5++;
};
return (true);
}
public static function registerTransition(_arg1:String, _arg2:Function):void{
if (!_inited){
init();
};
_transitionList[_arg1] = _arg2;
}
private static function affectTweens(_arg1:Function, _arg2:Object, _arg3:Array):Boolean{
var _local4:Boolean;
var _local5:uint;
var _local6:Array;
var _local7:uint;
var _local8:uint;
var _local9:uint;
_local4 = false;
if (!Boolean(_tweenList)){
return (false);
};
_local5 = 0;
while (_local5 < _tweenList.length) {
if (((_tweenList[_local5]) && ((_tweenList[_local5].scope == _arg2)))){
if (_arg3.length == 0){
_arg1(_local5);
_local4 = true;
} else {
_local6 = new Array();
_local7 = 0;
while (_local7 < _arg3.length) {
if (Boolean(_tweenList[_local5].properties[_arg3[_local7]])){
_local6.push(_arg3[_local7]);
};
_local7++;
};
if (_local6.length > 0){
_local8 = AuxFunctions.getObjectLength(_tweenList[_local5].properties);
if (_local8 == _local6.length){
_arg1(_local5);
_local4 = true;
} else {
_local9 = splitTweens(_local5, _local6);
_arg1(_local9);
_local4 = true;
};
};
};
};
_local5++;
};
return (_local4);
}
public static function getTweens(_arg1:Object):Array{
var _local2:uint;
var _local3:String;
var _local4:Array;
if (!Boolean(_tweenList)){
return ([]);
};
_local4 = new Array();
_local2 = 0;
while (_local2 < _tweenList.length) {
if (_tweenList[_local2].scope == _arg1){
for (_local3 in _tweenList[_local2].properties) {
_local4.push(_local3);
};
};
_local2++;
};
return (_local4);
}
private static function setPropertyValue(_arg1:Object, _arg2:String, _arg3:Number):void{
if (_specialPropertyList[_arg2] != undefined){
if (Boolean(_specialPropertyList[_arg2].parameters)){
_specialPropertyList[_arg2].setValue(_arg1, _arg3, _specialPropertyList[_arg2].parameters);
} else {
_specialPropertyList[_arg2].setValue(_arg1, _arg3);
};
} else {
_arg1[_arg2] = _arg3;
};
}
private static function getPropertyValue(_arg1:Object, _arg2:String):Number{
if (_specialPropertyList[_arg2] != undefined){
if (Boolean(_specialPropertyList[_arg2].parameters)){
return (_specialPropertyList[_arg2].getValue(_arg1, _specialPropertyList[_arg2].parameters));
};
return (_specialPropertyList[_arg2].getValue(_arg1));
} else {
};
return (!NULL!);
}
public static function isTweening(_arg1:Object):Boolean{
var _local2:uint;
if (!Boolean(_tweenList)){
return (false);
};
_local2 = 0;
while (_local2 < _tweenList.length) {
if (_tweenList[_local2].scope == _arg1){
return (true);
};
_local2++;
};
return (false);
}
public static function getTweenCount(_arg1:Object):Number{
var _local2:uint;
var _local3:Number;
if (!Boolean(_tweenList)){
return (0);
};
_local3 = 0;
_local2 = 0;
while (_local2 < _tweenList.length) {
if (_tweenList[_local2].scope == _arg1){
_local3 = (_local3 + AuxFunctions.getObjectLength(_tweenList[_local2].properties));
};
_local2++;
};
return (_local3);
}
private static function stopEngine():void{
_engineExists = false;
_tweenList = null;
_currentTime = 0;
__tweener_controller__.removeEventListener(Event.ENTER_FRAME, Tweener.onEnterFrame);
__tweener_controller__ = null;
}
public static function pauseTweenByIndex(_arg1:Number):Boolean{
var _local2:TweenListObj;
_local2 = _tweenList[_arg1];
if ((((_local2 == null)) || (_local2.isPaused))){
return (false);
};
_local2.timePaused = _currentTime;
_local2.isPaused = true;
return (true);
}
public static function removeTweensByTime(_arg1:Object, _arg2:Object, _arg3:Number, _arg4:Number):Boolean{
var removed:Boolean;
var removedLocally:Boolean;
var i:uint;
var tl:uint;
var pName:String;
var p_scope = _arg1;
var p_properties = _arg2;
var p_timeStart = _arg3;
var p_timeComplete = _arg4;
removed = false;
tl = _tweenList.length;
i = 0;
while (i < tl) {
if (((Boolean(_tweenList[i])) && ((p_scope == _tweenList[i].scope)))){
if ((((p_timeComplete > _tweenList[i].timeStart)) && ((p_timeStart < _tweenList[i].timeComplete)))){
removedLocally = false;
for (pName in _tweenList[i].properties) {
if (Boolean(p_properties[pName])){
if (Boolean(_tweenList[i].onOverwrite)){
try {
_tweenList[i].onOverwrite.apply(_tweenList[i].scope, _tweenList[i].onOverwriteParams);
} catch(e:Error) {
handleError(_tweenList[i], e, "onOverwrite");
};
};
_tweenList[i].properties[pName] = undefined;
delete _tweenList[i].properties[pName];
removedLocally = true;
removed = true;
};
};
if (removedLocally){
if (AuxFunctions.getObjectLength(_tweenList[i].properties) == 0){
removeTweenByIndex(i);
};
};
};
};
i = (i + 1);
};
return (removed);
}
public static function registerSpecialPropertySplitter(_arg1:String, _arg2:Function, _arg3:Array=null):void{
var _local4:SpecialPropertySplitter;
if (!_inited){
init();
};
_local4 = new SpecialPropertySplitter(_arg2, _arg3);
_specialPropertySplitterList[_arg1] = _local4;
}
public static function removeTweenByIndex(_arg1:Number, _arg2:Boolean=false):Boolean{
_tweenList[_arg1] = null;
if (_arg2){
_tweenList.splice(_arg1, 1);
};
return (true);
}
public static function resumeTweens(_arg1:Object, ... _args):Boolean{
var _local3:Array;
var _local4:uint;
_local3 = new Array();
_local4 = 0;
while (_local4 < _args.length) {
if ((((typeof(_args[_local4]) == "string")) && (!(AuxFunctions.isInArray(_args[_local4], _local3))))){
_local3.push(_args[_local4]);
};
_local4++;
};
return (affectTweens(resumeTweenByIndex, _arg1, _local3));
}
public static function pauseTweens(_arg1:Object, ... _args):Boolean{
var _local3:Array;
var _local4:uint;
_local3 = new Array();
_local4 = 0;
while (_local4 < _args.length) {
if ((((typeof(_args[_local4]) == "string")) && (!(AuxFunctions.isInArray(_args[_local4], _local3))))){
_local3.push(_args[_local4]);
};
_local4++;
};
return (affectTweens(pauseTweenByIndex, _arg1, _local3));
}
}
}//package caurina.transitions
Section 9
//TweenListObj (caurina.transitions.TweenListObj)
package caurina.transitions {
public class TweenListObj {
public var onUpdate:Function;
public var useFrames:Boolean;
public var hasStarted:Boolean;
public var onOverwriteParams:Array;
public var timeStart:Number;
public var count:Number;
public var auxProperties:Object;
public var timeComplete:Number;
public var onStartParams:Array;
public var rounded:Boolean;
public var properties:Object;
public var onUpdateParams:Array;
public var onComplete:Function;
public var updatesSkipped:Number;
public var onStart:Function;
public var skipUpdates:Number;
public var scope:Object;
public var isCaller:Boolean;
public var timePaused:Number;
public var transition:Function;
public var onCompleteParams:Array;
public var onError:Function;
public var timesCalled:Number;
public var onOverwrite:Function;
public var isPaused:Boolean;
public var waitFrames:Boolean;
public function TweenListObj(_arg1:Object, _arg2:Number, _arg3:Number, _arg4:Boolean, _arg5:Function){
scope = _arg1;
timeStart = _arg2;
timeComplete = _arg3;
useFrames = _arg4;
transition = _arg5;
auxProperties = new Object();
properties = new Object();
isPaused = false;
timePaused = undefined;
isCaller = false;
updatesSkipped = 0;
timesCalled = 0;
skipUpdates = 0;
hasStarted = false;
}
public function clone(_arg1:Boolean):TweenListObj{
var _local2:TweenListObj;
var _local3:String;
_local2 = new TweenListObj(scope, timeStart, timeComplete, useFrames, transition);
_local2.properties = new Array();
for (_local3 in properties) {
_local2.properties[_local3] = properties[_local3].clone();
};
_local2.skipUpdates = skipUpdates;
_local2.updatesSkipped = updatesSkipped;
if (!_arg1){
_local2.onStart = onStart;
_local2.onUpdate = onUpdate;
_local2.onComplete = onComplete;
_local2.onOverwrite = onOverwrite;
_local2.onError = onError;
_local2.onStartParams = onStartParams;
_local2.onUpdateParams = onUpdateParams;
_local2.onCompleteParams = onCompleteParams;
_local2.onOverwriteParams = onOverwriteParams;
};
_local2.rounded = rounded;
_local2.isPaused = isPaused;
_local2.timePaused = timePaused;
_local2.isCaller = isCaller;
_local2.count = count;
_local2.timesCalled = timesCalled;
_local2.waitFrames = waitFrames;
_local2.hasStarted = hasStarted;
return (_local2);
}
public function toString():String{
var _local1:String;
var _local2:uint;
_local1 = "\n[TweenListObj ";
_local1 = (_local1 + ("scope:" + String(scope)));
_local1 = (_local1 + ", properties:");
_local2 = 0;
while (_local2 < properties.length) {
if (_local2 > 0){
_local1 = (_local1 + ",");
};
_local1 = (_local1 + ("[name:" + properties[_local2].name));
_local1 = (_local1 + (",valueStart:" + properties[_local2].valueStart));
_local1 = (_local1 + (",valueComplete:" + properties[_local2].valueComplete));
_local1 = (_local1 + "]");
_local2++;
};
_local1 = (_local1 + (", timeStart:" + String(timeStart)));
_local1 = (_local1 + (", timeComplete:" + String(timeComplete)));
_local1 = (_local1 + (", useFrames:" + String(useFrames)));
_local1 = (_local1 + (", transition:" + String(transition)));
if (skipUpdates){
_local1 = (_local1 + (", skipUpdates:" + String(skipUpdates)));
};
if (updatesSkipped){
_local1 = (_local1 + (", updatesSkipped:" + String(updatesSkipped)));
};
if (Boolean(onStart)){
_local1 = (_local1 + (", onStart:" + String(onStart)));
};
if (Boolean(onUpdate)){
_local1 = (_local1 + (", onUpdate:" + String(onUpdate)));
};
if (Boolean(onComplete)){
_local1 = (_local1 + (", onComplete:" + String(onComplete)));
};
if (Boolean(onOverwrite)){
_local1 = (_local1 + (", onOverwrite:" + String(onOverwrite)));
};
if (Boolean(onError)){
_local1 = (_local1 + (", onError:" + String(onError)));
};
if (onStartParams){
_local1 = (_local1 + (", onStartParams:" + String(onStartParams)));
};
if (onUpdateParams){
_local1 = (_local1 + (", onUpdateParams:" + String(onUpdateParams)));
};
if (onCompleteParams){
_local1 = (_local1 + (", onCompleteParams:" + String(onCompleteParams)));
};
if (onOverwriteParams){
_local1 = (_local1 + (", onOverwriteParams:" + String(onOverwriteParams)));
};
if (rounded){
_local1 = (_local1 + (", rounded:" + String(rounded)));
};
if (isPaused){
_local1 = (_local1 + (", isPaused:" + String(isPaused)));
};
if (timePaused){
_local1 = (_local1 + (", timePaused:" + String(timePaused)));
};
if (isCaller){
_local1 = (_local1 + (", isCaller:" + String(isCaller)));
};
if (count){
_local1 = (_local1 + (", count:" + String(count)));
};
if (timesCalled){
_local1 = (_local1 + (", timesCalled:" + String(timesCalled)));
};
if (waitFrames){
_local1 = (_local1 + (", waitFrames:" + String(waitFrames)));
};
if (hasStarted){
_local1 = (_local1 + (", hasStarted:" + String(hasStarted)));
};
_local1 = (_local1 + "]\n");
return (_local1);
}
public static function makePropertiesChain(_arg1:Object):Object{
var _local2:Object;
var _local3:Object;
var _local4:Object;
var _local5:Object;
var _local6:Number;
var _local7:Number;
var _local8:Number;
_local2 = _arg1.base;
if (_local2){
_local3 = {};
if ((_local2 is Array)){
_local4 = [];
_local8 = 0;
while (_local8 < _local2.length) {
_local4.push(_local2[_local8]);
_local8++;
};
} else {
_local4 = [_local2];
};
_local4.push(_arg1);
_local6 = _local4.length;
_local7 = 0;
while (_local7 < _local6) {
if (_local4[_local7]["base"]){
_local5 = AuxFunctions.concatObjects(makePropertiesChain(_local4[_local7]["base"]), _local4[_local7]);
} else {
_local5 = _local4[_local7];
};
_local3 = AuxFunctions.concatObjects(_local3, _local5);
_local7++;
};
if (_local3["base"]){
delete _local3["base"];
};
return (_local3);
//unresolved jump
};
return (_arg1);
}
}
}//package caurina.transitions
Section 10
//SoundManager (com.hydrotik.utils.SoundManager)
package com.hydrotik.utils {
import flash.events.*;
import caurina.transitions.*;
import flash.media.*;
import flash.utils.*;
public class SoundManager {
private var _currPos:int;
private var _itemArray:Array;
private var _seqIsManual:Boolean;
private var _seqArray:Array;
private var _isMuted:Boolean;// = false
private var _currSequenceItem:String;// = ""
private var _nextSequenceItem:String;// = ""
private var _xFadeNext:Boolean;
public static const AUTHOR:String = "Donovan Adams - donovan[(at)]hydrotik.com - http://blog.hydrotik.com";
public static const VERSION:String = "SoundManager 0.0.2";
private static var _oSoundManager:SoundManager;
private static var _sndArray:Dictionary;
private static var _channelArray:Dictionary;
private static var _soundTransform:SoundTransform;
public function SoundManager(_arg1:SingletonEnforcer):void{
_seqArray = new Array();
_currSequenceItem = "";
_nextSequenceItem = "";
_itemArray = new Array();
_isMuted = false;
super();
if (_arg1 == null){
throw (new Error("SoundManager: Instantiation failed - Use SoundManager.getInstance() instead of new."));
};
_sndArray = new Dictionary(true);
_channelArray = new Dictionary(true);
}
public function stop(_arg1:String):void{
var snd = _arg1;
try {
_channelArray[snd].stop();
} catch(e:Error) {
throw (new Error((("SoundManager: " + snd) + " has not been loaded into the SoundManager.")));
};
}
public function getItem(_arg1:String){
return (_sndArray[_arg1]);
}
private function soundCompleteHandler(_arg1:Event):void{
}
public function addItem(_arg1):void{
_sndArray[getQualifiedClassName(_arg1)] = (_arg1 as Sound);
_itemArray.push(getQualifiedClassName(_arg1));
}
public function startSequencer(_arg1):void{
if ((_arg1 is Array)){
_seqArray = _arg1;
_seqIsManual = false;
} else {
_seqIsManual = true;
_currSequenceItem = _arg1;
};
enableAll();
advanceSequencer();
}
private function stopAllComplete(_arg1:String):void{
stop(_arg1);
}
public function pan(_arg1:String, _arg2:Number, _arg3:Number=0.5, _arg4:String="linear"):void{
var snd = _arg1;
var pan = _arg2;
var t = _arg3;
var ease = _arg4;
try {
Tweener.addTween(_channelArray[snd], {_sound_pan:pan, time:t, transition:ease});
} catch(e:Error) {
throw (new Error((("SoundManager: " + snd) + " has not been loaded into the SoundManager.")));
};
}
public function enableAll():void{
_isMuted = false;
}
public function dispose():void{
var _local1:int;
_nextSequenceItem = null;
_xFadeNext = false;
_local1 = 0;
while (_local1 < _itemArray.length) {
_channelArray[_itemArray[_local1]] = null;
_sndArray[_itemArray[_local1]] = null;
_local1++;
};
_isMuted = false;
}
public function get muted():Boolean{
return (_isMuted);
}
private function advanceSequencer(_arg1:Event=null):void{
if (_seqIsManual){
if (_nextSequenceItem != ""){
play(_nextSequenceItem, 0, (_xFadeNext) ? 0 : 0.8, true);
if (_xFadeNext){
play(_currSequenceItem, 0, 0.8, false);
fade(_currSequenceItem, 0, (_sndArray[_currSequenceItem].length * 0.001), "easeinquad");
fade(_nextSequenceItem, 0.8, (_sndArray[_nextSequenceItem].length * 0.001), "easeoutquad");
};
_currSequenceItem = _nextSequenceItem;
_nextSequenceItem = "";
_xFadeNext = false;
} else {
play(_currSequenceItem, 0, 0.8, true);
};
} else {
_currPos++;
play(_seqArray[(_currPos - 1)], 0, 0.8, ((_currPos)==_seqArray.length) ? false : true);
if (_seqArray[_currPos] != _seqArray[(_currPos - 1)]){
play(_seqArray[_currPos], 0, 0, false);
fade(_seqArray[(_currPos - 1)], 0, (_sndArray[_seqArray[(_currPos - 1)]].length * 0.001), "easeinquad");
fade(_seqArray[_currPos], 0.8, (_sndArray[_seqArray[_currPos]].length * 0.001), "easeoutquad");
};
};
}
public function play(_arg1:String, _arg2:int=0, _arg3:Number=1, _arg4:Boolean=false):void{
var snd = _arg1;
var l = _arg2;
var vol = _arg3;
var isSeq = _arg4;
if (!_isMuted){
try {
_channelArray[snd] = _sndArray[snd].play(0, l);
if (vol != -1){
_soundTransform = _channelArray[snd].soundTransform;
_soundTransform.volume = vol;
_channelArray[snd].soundTransform = _soundTransform;
};
if (isSeq){
_channelArray[snd].addEventListener(Event.SOUND_COMPLETE, advanceSequencer, false, 0, true);
} else {
_channelArray[snd].addEventListener(Event.SOUND_COMPLETE, soundCompleteHandler, false, 0, true);
};
_soundTransform = null;
} catch(e:Error) {
throw (new Error((("SoundManager: " + snd) + " has not been loaded into the SoundManager.")));
};
};
}
public function addSequenceItem(_arg1:String, _arg2:Boolean=false):void{
_nextSequenceItem = _arg1;
_xFadeNext = _arg2;
}
public function removeItem(_arg1:String):void{
_channelArray[_arg1] = null;
_sndArray[_arg1] = null;
_itemArray.splice(_itemArray.indexOf(_arg1), 1);
}
public function fade(_arg1:String, _arg2:Number, _arg3:Number=0.5, _arg4:String="linear"):void{
var snd = _arg1;
var vol = _arg2;
var t = _arg3;
var ease = _arg4;
try {
Tweener.addTween(_channelArray[snd], {_sound_volume:vol, time:t, transition:ease});
} catch(e:Error) {
throw (new Error((("SoundManager: " + snd) + " has not been loaded into the SoundManager.")));
};
}
public function stopAll(_arg1:Number=0):void{
var _local2:int;
_channelArray[_currSequenceItem].removeEventListener(Event.SOUND_COMPLETE, advanceSequencer);
_nextSequenceItem = "";
_xFadeNext = false;
_local2 = 0;
while (_local2 < _itemArray.length) {
Tweener.addTween(_channelArray[_itemArray[_local2]], {_sound_volume:0, time:_arg1, transition:"linear", onComplete:stopAllComplete});
_local2++;
};
_isMuted = true;
}
public static function getInstance():SoundManager{
if (_oSoundManager == null){
_oSoundManager = new SoundManager(new SingletonEnforcer());
};
return (_oSoundManager);
}
}
}//package com.hydrotik.utils
class SingletonEnforcer {
private function SingletonEnforcer(){
}
}
Section 11
//Armegalogo1_229 (Random_Stuff_Defence_fla.Armegalogo1_229)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Armegalogo1_229 extends MovieClip {
public var squigler:MovieClip;
}
}//package Random_Stuff_Defence_fla
Section 12
//Armegalogo3_227 (Random_Stuff_Defence_fla.Armegalogo3_227)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Armegalogo3_227 extends MovieClip {
public var armegaButton:SimpleButton;
public var a2:MovieClip;
public var a3:MovieClip;
public var a1:MovieClip;
}
}//package Random_Stuff_Defence_fla
Section 13
//ControlScreen_40 (Random_Stuff_Defence_fla.ControlScreen_40)
package Random_Stuff_Defence_fla {
import flash.display.*;
import flash.text.*;
public dynamic class ControlScreen_40 extends MovieClip {
public var towername:TextField;
public var towercost:TextField;
public var ct:TextField;
public var Towerb20:SimpleButton;
public var Towerb21:SimpleButton;
public var Towerb22:SimpleButton;
public var Towerb23:SimpleButton;
public var Towerb24:SimpleButton;
public var Towerb2:SimpleButton;
public var Towerb3:SimpleButton;
public var Towerb4:SimpleButton;
public var Towerb6:SimpleButton;
public var Towerb5:SimpleButton;
public var Towerb7:SimpleButton;
public var Info:TextField;
public var Towerb1:SimpleButton;
public var Towerb8:SimpleButton;
public var quitGameBut:SimpleButton;
}
}//package Random_Stuff_Defence_fla
Section 14
//eefunnysting_234 (Random_Stuff_Defence_fla.eefunnysting_234)
package Random_Stuff_Defence_fla {
import flash.events.*;
import flash.display.*;
import flash.net.*;
public dynamic class eefunnysting_234 extends MovieClip {
public var funBut:SimpleButton;
public function eefunnysting_234(){
addFrameScript(0, frame1, 40, frame41);
}
function frame1(){
funBut.addEventListener(MouseEvent.CLICK, callFunnylishus, false, 0, true);
}
public function callFunnylishus(_arg1:MouseEvent):void{
var url:String;
var request:URLRequest;
var event = _arg1;
url = "http://www.funnylishus.com";
request = new URLRequest(url);
try {
navigateToURL(request, "_blank");
} catch(e:Error) {
};
}
function frame41(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 15
//efSymbol18_239 (Random_Stuff_Defence_fla.efSymbol18_239)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class efSymbol18_239 extends MovieClip {
public var a6:MovieClip;
public var a4:MovieClip;
public var a9:MovieClip;
public var a5:MovieClip;
public var a8:MovieClip;
public var a11:MovieClip;
public var a10:MovieClip;
public var a2:MovieClip;
public var a3:MovieClip;
public var a7:MovieClip;
public var a1:MovieClip;
}
}//package Random_Stuff_Defence_fla
Section 16
//efSymbol180_6 (Random_Stuff_Defence_fla.efSymbol180_6)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class efSymbol180_6 extends MovieClip {
public var a6:MovieClip;
public var a4:MovieClip;
public var a9:MovieClip;
public var a5:MovieClip;
public var a8:MovieClip;
public var a11:MovieClip;
public var a10:MovieClip;
public var a2:MovieClip;
public var a3:MovieClip;
public var a7:MovieClip;
public var a1:MovieClip;
}
}//package Random_Stuff_Defence_fla
Section 17
//fls_Symbol169_232 (Random_Stuff_Defence_fla.fls_Symbol169_232)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class fls_Symbol169_232 extends MovieClip {
public var stingState:String;
public function fls_Symbol169_232(){
addFrameScript(0, frame1, 100, frame101);
}
function frame1(){
stingState = "playing";
}
function frame101(){
stingState = "finished";
}
}
}//package Random_Stuff_Defence_fla
Section 18
//Loader_1 (Random_Stuff_Defence_fla.Loader_1)
package Random_Stuff_Defence_fla {
import flash.display.*;
import flash.text.*;
public dynamic class Loader_1 extends MovieClip {
public var lpc:TextField;
public var gob:MovieClip;
public var gob3:MovieClip;
public var gob2:MovieClip;
}
}//package Random_Stuff_Defence_fla
Section 19
//MineTower_106 (Random_Stuff_Defence_fla.MineTower_106)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class MineTower_106 extends MovieClip {
public var TowerWep:MovieClip;
public function MineTower_106(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 20
//mute_208 (Random_Stuff_Defence_fla.mute_208)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class mute_208 extends MovieClip {
public var thisOff:SimpleButton;
}
}//package Random_Stuff_Defence_fla
Section 21
//mute_209 (Random_Stuff_Defence_fla.mute_209)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class mute_209 extends MovieClip {
public var on_mc:MovieClip;
}
}//package Random_Stuff_Defence_fla
Section 22
//mute_213 (Random_Stuff_Defence_fla.mute_213)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class mute_213 extends MovieClip {
public var thisOff:SimpleButton;
}
}//package Random_Stuff_Defence_fla
Section 23
//NO_193 (Random_Stuff_Defence_fla.NO_193)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class NO_193 extends MovieClip {
public function NO_193(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 24
//Symbol11_69 (Random_Stuff_Defence_fla.Symbol11_69)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol11_69 extends MovieClip {
public var TowerWep:MovieClip;
public var emptymc:MovieClip;
public var base:MovieClip;
}
}//package Random_Stuff_Defence_fla
Section 25
//Symbol122_204 (Random_Stuff_Defence_fla.Symbol122_204)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol122_204 extends MovieClip {
public function Symbol122_204(){
addFrameScript(0, frame1);
}
function frame1(){
play();
}
}
}//package Random_Stuff_Defence_fla
Section 26
//Symbol130_300 (Random_Stuff_Defence_fla.Symbol130_300)
package Random_Stuff_Defence_fla {
import flash.display.*;
import flash.text.*;
public dynamic class Symbol130_300 extends MovieClip {
public var message:TextField;
}
}//package Random_Stuff_Defence_fla
Section 27
//Symbol138_261 (Random_Stuff_Defence_fla.Symbol138_261)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol138_261 extends MovieClip {
public function Symbol138_261(){
addFrameScript(24, frame25);
}
function frame25(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 28
//Symbol139_132 (Random_Stuff_Defence_fla.Symbol139_132)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol139_132 extends MovieClip {
public var holder:MovieClip;
public function Symbol139_132(){
addFrameScript(0, frame1, 100, frame101);
}
function frame1(){
stop();
}
function frame101(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 29
//Symbol184_296 (Random_Stuff_Defence_fla.Symbol184_296)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol184_296 extends MovieClip {
public function Symbol184_296(){
addFrameScript(0, frame1, 15, frame16);
}
function frame16(){
gotoAndPlay(2);
}
function frame1(){
gotoAndPlay(int((Math.random() * 20)));
}
}
}//package Random_Stuff_Defence_fla
Section 30
//Symbol20_98 (Random_Stuff_Defence_fla.Symbol20_98)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol20_98 extends MovieClip {
public function Symbol20_98(){
addFrameScript(0, frame1);
}
function frame1(){
this.rotation = (Math.random() * 360);
}
}
}//package Random_Stuff_Defence_fla
Section 31
//Symbol201_133 (Random_Stuff_Defence_fla.Symbol201_133)
package Random_Stuff_Defence_fla {
import flash.display.*;
import flash.text.*;
public dynamic class Symbol201_133 extends MovieClip {
public var ErrorMessage:TextField;
}
}//package Random_Stuff_Defence_fla
Section 32
//Symbol212_305 (Random_Stuff_Defence_fla.Symbol212_305)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol212_305 extends MovieClip {
public function Symbol212_305(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 33
//Symbol217_258 (Random_Stuff_Defence_fla.Symbol217_258)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol217_258 extends MovieClip {
public var stingState:String;
public function Symbol217_258(){
addFrameScript(0, frame1);
}
function frame1(){
stingState = "finished";
}
}
}//package Random_Stuff_Defence_fla
Section 34
//Symbol3_141 (Random_Stuff_Defence_fla.Symbol3_141)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol3_141 extends MovieClip {
public function Symbol3_141(){
addFrameScript(20, frame21);
}
function frame21(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 35
//Symbol4_81 (Random_Stuff_Defence_fla.Symbol4_81)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol4_81 extends MovieClip {
public function Symbol4_81(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 36
//Symbol5_135 (Random_Stuff_Defence_fla.Symbol5_135)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol5_135 extends MovieClip {
public function Symbol5_135(){
addFrameScript(5, frame6);
}
function frame6(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 37
//Symbol5_90 (Random_Stuff_Defence_fla.Symbol5_90)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol5_90 extends MovieClip {
public function Symbol5_90(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 38
//Symbol6_60 (Random_Stuff_Defence_fla.Symbol6_60)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol6_60 extends MovieClip {
public function Symbol6_60(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 39
//Symbol7_73 (Random_Stuff_Defence_fla.Symbol7_73)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol7_73 extends MovieClip {
public function Symbol7_73(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 40
//Symbol7copy_95 (Random_Stuff_Defence_fla.Symbol7copy_95)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol7copy_95 extends MovieClip {
public function Symbol7copy_95(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 41
//Symbol85_263 (Random_Stuff_Defence_fla.Symbol85_263)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbol85_263 extends MovieClip {
public var detect:MovieClip;
}
}//package Random_Stuff_Defence_fla
Section 42
//Symbols6_256 (Random_Stuff_Defence_fla.Symbols6_256)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symbols6_256 extends MovieClip {
public function Symbols6_256(){
addFrameScript(0, frame1);
}
function frame1(){
gotoAndStop(int(((Math.random() * totalFrames) + 1)));
}
}
}//package Random_Stuff_Defence_fla
Section 43
//Symdbol4_254 (Random_Stuff_Defence_fla.Symdbol4_254)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Symdbol4_254 extends MovieClip {
public function Symdbol4_254(){
addFrameScript(9, frame10);
}
function frame10(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 44
//Tower1_83 (Random_Stuff_Defence_fla.Tower1_83)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Tower1_83 extends MovieClip {
public var TowerWep:MovieClip;
public var base:MovieClip;
public function Tower1_83(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 45
//Tower1Weapon_85 (Random_Stuff_Defence_fla.Tower1Weapon_85)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Tower1Weapon_85 extends MovieClip {
public function Tower1Weapon_85(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 46
//Tower2_79 (Random_Stuff_Defence_fla.Tower2_79)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Tower2_79 extends MovieClip {
public var TowerWep:MovieClip;
public var base:MovieClip;
public function Tower2_79(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 47
//Tower3_88 (Random_Stuff_Defence_fla.Tower3_88)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Tower3_88 extends MovieClip {
public var weap:MovieClip;
public var TowerWep:MovieClip;
public var base:MovieClip;
public function Tower3_88(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 48
//Tower4_58 (Random_Stuff_Defence_fla.Tower4_58)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Tower4_58 extends MovieClip {
public var TowerWep:MovieClip;
public var base:MovieClip;
public function Tower4_58(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 49
//Tower5_63 (Random_Stuff_Defence_fla.Tower5_63)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Tower5_63 extends MovieClip {
public var TowerWep:MovieClip;
public var base:MovieClip;
public function Tower5_63(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 50
//Tower6_93 (Random_Stuff_Defence_fla.Tower6_93)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Tower6_93 extends MovieClip {
public var TowerWep:MovieClip;
public var base:MovieClip;
public function Tower6_93(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 51
//Wep5Holder_65 (Random_Stuff_Defence_fla.Wep5Holder_65)
package Random_Stuff_Defence_fla {
import flash.display.*;
public dynamic class Wep5Holder_65 extends MovieClip {
public function Wep5Holder_65(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package Random_Stuff_Defence_fla
Section 52
//APRESEXPLO1 (APRESEXPLO1)
package {
import flash.media.*;
public dynamic class APRESEXPLO1 extends Sound {
}
}//package
Section 53
//AreYouSure (AreYouSure)
package {
import flash.display.*;
public dynamic class AreYouSure extends MovieClip {
public var nobut:SimpleButton;
public var yesbut:SimpleButton;
}
}//package
Section 54
//ArmegaloStingy (ArmegaloStingy)
package {
public dynamic class ArmegaloStingy extends sting_controller {
public var stingState:String;
public function ArmegaloStingy(){
addFrameScript(0, frame1, 69, frame70);
}
function frame70(){
stingState = "finished";
}
function frame1(){
stingState = "playing";
}
}
}//package
Section 55
//BIGGUN (BIGGUN)
package {
import flash.media.*;
public dynamic class BIGGUN extends Sound {
}
}//package
Section 56
//BOOM1 (BOOM1)
package {
import flash.media.*;
public dynamic class BOOM1 extends Sound {
}
}//package
Section 57
//BOOM2 (BOOM2)
package {
import flash.media.*;
public dynamic class BOOM2 extends Sound {
}
}//package
Section 58
//BOOM3 (BOOM3)
package {
import flash.media.*;
public dynamic class BOOM3 extends Sound {
}
}//package
Section 59
//BOOM4 (BOOM4)
package {
import flash.media.*;
public dynamic class BOOM4 extends Sound {
}
}//package
Section 60
//BOOM5 (BOOM5)
package {
import flash.media.*;
public dynamic class BOOM5 extends Sound {
}
}//package
Section 61
//BOOM6 (BOOM6)
package {
import flash.media.*;
public dynamic class BOOM6 extends Sound {
}
}//package
Section 62
//border (border)
package {
import flash.display.*;
public dynamic class border extends MovieClip {
}
}//package
Section 63
//BottomPanel (BottomPanel)
package {
import flash.display.*;
public dynamic class BottomPanel extends MovieClip {
public var armegaButton:SimpleButton;
public var siteButton:SimpleButton;
public var agButton_btn:SimpleButton;
}
}//package
Section 64
//bubblishus (bubblishus)
package {
import flash.events.*;
import flash.display.*;
public class bubblishus extends MovieClip {
private var ox:Number;// = 0
public var a6:MovieClip;
public var a4:MovieClip;
public var a9:MovieClip;
private var oy:Number;// = 0
public var a5:MovieClip;
public var a8:MovieClip;
public var a11:MovieClip;
private var maxxs:Number;// = 1.5
public var a10:MovieClip;
private var maxys:Number;// = 1.5
public var a2:MovieClip;
public var a3:MovieClip;
public var a7:MovieClip;
public var a1:MovieClip;
public function bubblishus(){
maxxs = 1.5;
maxys = 1.5;
ox = 0;
oy = 0;
super();
ox = this.x;
oy = this.y;
addEventListener(Event.ENTER_FRAME, onEnterFrame);
}
private function onEnterFrame(_arg1:Event){
this.x = ((ox + ((Math.random() * maxxs) * 2)) - maxxs);
this.y = ((oy + ((Math.random() * maxys) * 2)) - maxys);
}
}
}//package
Section 65
//BUILDFIN (BUILDFIN)
package {
import flash.media.*;
public dynamic class BUILDFIN extends Sound {
}
}//package
Section 66
//BUILDINGDOWNTHUMP (BUILDINGDOWNTHUMP)
package {
import flash.media.*;
public dynamic class BUILDINGDOWNTHUMP extends Sound {
}
}//package
Section 67
//BUILDINGUP (BUILDINGUP)
package {
import flash.media.*;
public dynamic class BUILDINGUP extends Sound {
}
}//package
Section 68
//CashReadout (CashReadout)
package {
import flash.display.*;
import flash.text.*;
public dynamic class CashReadout extends MovieClip {
public var Message:TextField;
}
}//package
Section 69
//CLICK (CLICK)
package {
import flash.media.*;
public dynamic class CLICK extends Sound {
}
}//package
Section 70
//ClockTimer (ClockTimer)
package {
import flash.display.*;
public dynamic class ClockTimer extends MovieClip {
}
}//package
Section 71
//ControlScreenControl (ControlScreenControl)
package {
import flash.display.*;
public dynamic class ControlScreenControl extends MovieClip {
public var OpenControlButton:SimpleButton;
public var Screen:MovieClip;
public function ControlScreenControl(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package
Section 72
//Creep_controller (Creep_controller)
package {
import flash.events.*;
import flash.display.*;
import flash.text.*;
public class Creep_controller extends Sprite {
public var CurrentNode:Number;// = 1
public var NodeRange:Number;// = 6
public var CurrentHP:Number;
public var MaxHP:Number;
public var TXpos:Number;
public var SlowResist:Number;
public var Worth:Number;
public var CurrentSP:Number;
public var Armour:Number;
public var MaxSP:Number;
public var RecoverSP:Number;
public var TYpos:Number;
public var Creep:CreepControl;
public var Message:TextField;
public function Creep_controller(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:Number, _arg7:Number, _arg8:Number, _arg9:Number, _arg10:Number, _arg11:Number, _arg12:Number, _arg13:Number){
CurrentNode = 1;
NodeRange = 6;
Message = new TextField();
Creep = new CreepControl();
super();
addChild(Creep);
this.x = _arg1;
this.y = _arg2;
Creep.gotoAndStop(_arg5);
CurrentHP = _arg6;
MaxHP = _arg7;
CurrentSP = _arg8;
MaxSP = _arg9;
RecoverSP = _arg10;
SlowResist = _arg11;
Armour = _arg12;
Worth = _arg13;
TXpos = _arg3;
TYpos = _arg4;
addEventListener(Event.ENTER_FRAME, onEnterFrame, false, 0, true);
}
private function onEnterFrame(_arg1:Event):void{
var _local2:Number;
_local2 = (CurrentHP / MaxHP);
if (_local2 < 0){
_local2 = 0;
};
Creep.hpb.bar.scaleX = _local2;
}
public function killme():void{
removeEventListener(Event.ENTER_FRAME, onEnterFrame);
this.parent.removeChild(this);
}
}
}//package
Section 73
//CreepControl (CreepControl)
package {
import flash.display.*;
public dynamic class CreepControl extends MovieClip {
public var hpb:HitPointsBar;
public var detect:MovieClip;
public var dude:MovieClip;
}
}//package
Section 74
//CreepReadout (CreepReadout)
package {
import flash.display.*;
import flash.text.*;
public dynamic class CreepReadout extends MovieClip {
public var CreepMessage:TextField;
}
}//package
Section 75
//CROWD (CROWD)
package {
import flash.media.*;
public dynamic class CROWD extends Sound {
}
}//package
Section 76
//Defender3 (Defender3)
package {
import flash.events.*;
import flash.display.*;
import flash.text.*;
import flash.utils.*;
import flash.net.*;
import flash.ui.*;
public class Defender3 extends MovieClip {
private var LevelFinishedOutputting:Boolean;// = true
private var ControlScreen:MovieClip;
private var Explosions:Array;
public var subBut:SimpleButton;
private var Missiles:Array;
private var endGameCondition:String;
private var TGH:MovieClip;
private var EndGameClip:MovieClip;
public var bd:MovieClip;
private var Border:MovieClip;
private var boardMinY:uint;// = 0
private var boardMinX:uint;// = 0
private var creepcounterstop:Number;// = -1
private var p:Array;
private var CashTechLevel:Number;// = -1
public var goBut:SimpleButton;
private var endGameAt:int;// = 100
public var endGameFlag:int;// = -1
private var waveDispatchTimer:Timer;
public var messageHolder:MovieClip;
public var agButton_btn:SimpleButton;
private var ldr_centreY:Number;// = 200
private var gotCashResearch:Boolean;// = false
private var ldr_centreX:Number;// = 275
private var ldr_SGH:MovieClip;
private var RGH:MovieClip;
private var PauseBut:SimpleButton;
private var GH:MovieClip;
private var creeptimerstop:Number;// = 0
private var Lives:int;
private var userName:String;// = "Default"
private var gotBombResearch:Boolean;// = false
public var pgBut:SimpleButton;
private var GamePanel:MovieClip;
private var SelectedTower:Number;// = -1
private var tunePlaying;// = "None"
public var namerror:MovieClip;
private var ScoreSubmit:MovieClip;
public var armegaButton:SimpleButton;
private var BaseInterest:Number;// = 0.02
private var Err:MovieClip;
private var TPC:MovieClip;
private var GunTechLevel:Number;// = -1
private var GAMEON:Boolean;// = false
private var SlowTechLevel:Number;// = -1
private var gotSlowResearch:Boolean;// = false
public var siteButton:SimpleButton;
private var ldr_startScale:Number;
private var DTGH:MovieClip;
private var towersKilledThisFrame:Array;
private var PathData:path_definitions;
public var sbBut:SimpleButton;
private var ldr_startPoint:Number;// = 5
private var ldr_minSpeed;
public var p0:SimpleButton;
private var _root;
public var p2:SimpleButton;
public var p3:SimpleButton;
public var p5:SimpleButton;
public var p1:SimpleButton;
private var ResearchMenu:MovieClip;
private var Crr:MovieClip;
public var p6:SimpleButton;
public var p7:SimpleButton;
public var p8:SimpleButton;
public var p9:SimpleButton;
private var gotMineResearch:Boolean;// = false
public var p4:SimpleButton;
private var PathSel:MovieClip;
private var ldr_starCount:uint;// = 200
private var creepcounter:Number;// = 0
private var permission:Boolean;// = true
private var DBGH:MovieClip;
public var sting:ArmegaloStingy;
private var ldr_stars:Array;
private var MissileData:missile_definitions;
private var BombTechLevel:Number;// = -1
private var ldr_bottomEdge:int;
private var MGH:MovieClip;
public var PathHighlight:MovieClip;
private var ldr_rightEdge:int;
private var wavetimerstop:Number;// = 100
public var ldr:MovieClip;
private var ldr_frameCounter:uint;// = 0
private var errorTimer:Timer;
private var MaxLives:uint;// = 20
private var TowerData:tower_definitions;
public var details:TextField;
private var mineFuseLength:uint;// = 10
private var WaveData:wave_definitions;
private var ldr_universalAccel;// = 1.1
public var sting2:MovieClip;
public var sting3:MovieClip;
public var mgBut:SimpleButton;
public var theName:TextField;
private var Towers:Array;
private var ldr_starXS:Number;
private var finalScore:Number;// = 0
private var gotGunResearch:Boolean;// = false
private var ldr_starYS:Number;
private var endGameFlag2:String;// = "Bad"
private var creeptimer:Number;// = 0
private var StartBut:SimpleButton;
private var ldr_leftEdge:int;
private var yn:MovieClip;
private var CrrTimer:Timer;
private var Cash:Number;
private var GamePath:Number;// = 0
private var MineTechLevel:Number;// = -1
private var ldr_topEdge:int;
private var soundMod;
private var boardMaxX:uint;// = 550
private var CashDisp:TextField;
private var boardMaxY:uint;// = 400
private var WaveTimer;// = 300
private var Creeps:Array;
private var Car:MovieClip;
private var gamePaused:Boolean;// = false
private var total_towers:Number;// = 0
private var EGH:MovieClip;
private var wavetimer:Number;// = 0
private var CurrentWave:Number;// = -1
private var rangeCirc:Sprite;
private var TowerMenu:MovieClip;
public function Defender3(){
total_towers = 0;
_root = this;
SelectedTower = -1;
TowerData = new tower_definitions();
PathData = new path_definitions();
WaveData = new wave_definitions();
MissileData = new missile_definitions();
MaxLives = 20;
Lives = MaxLives;
BaseInterest = 0.02;
CashDisp = new TextField();
GamePath = 0;
CurrentWave = -1;
wavetimer = 0;
wavetimerstop = 100;
creeptimer = 0;
creeptimerstop = 0;
creepcounter = 0;
creepcounterstop = -1;
GAMEON = false;
WaveTimer = 300;
rangeCirc = new Sprite();
waveDispatchTimer = new Timer(WaveData.myXml.WaveTimer, WaveData.myXml.WaveCount);
errorTimer = new Timer(4000);
CrrTimer = new Timer(20000);
GunTechLevel = -1;
BombTechLevel = -1;
SlowTechLevel = -1;
MineTechLevel = -1;
CashTechLevel = -1;
gotGunResearch = false;
gotBombResearch = false;
gotSlowResearch = false;
gotMineResearch = false;
gotCashResearch = false;
towersKilledThisFrame = new Array();
LevelFinishedOutputting = true;
boardMinX = 0;
boardMaxX = 550;
boardMinY = 0;
boardMaxY = 400;
endGameFlag = -1;
endGameFlag2 = "Bad";
endGameAt = 100;
mineFuseLength = 10;
p = [];
ldr_starCount = 200;
ldr_stars = [];
ldr_startPoint = 5;
ldr_starXS = (0.25 * ldr_startPoint);
ldr_starYS = (0.25 * ldr_startPoint);
ldr_minSpeed = (0.01 * ldr_startPoint);
ldr_startScale = (0.005 * ldr_startPoint);
ldr_SGH = new MovieClip();
ldr_centreX = (550 / 2);
ldr_centreY = (400 / 2);
ldr_universalAccel = 1.1;
ldr_leftEdge = -((ldr_centreX * 1.5));
ldr_rightEdge = (ldr_centreX * 1.5);
ldr_topEdge = -((ldr_centreY * 1.5));
ldr_bottomEdge = (ldr_centreY * 1.5);
ldr_frameCounter = 0;
permission = true;
userName = "Default";
finalScore = 0;
gamePaused = false;
tunePlaying = "None";
super();
addFrameScript(0, frame1, 5, frame6, 6, frame7, 8, frame9);
setupContextMenu();
_root.stop();
ldr_init();
}
private function pauseUnPause(_arg1:KeyboardEvent){
if (_arg1.keyCode == 32){
if (GAMEON == false){
startGame2();
} else {
if (gamePaused == false){
pauseGame2();
} else {
reStartGame2();
};
};
};
}
private function rotateBoredTower(_arg1:Object){
if ((Math.random() * 50) < 1){
_arg1.rotDir = 0;
};
if ((Math.random() * 200) < 1){
_arg1.rotDir = int(((Math.random() * 7) - 3));
};
_arg1.Tower.tow.TowerWep.rotation = (_arg1.Tower.tow.TowerWep.rotation + _arg1.rotDir);
}
function onContextMenuHandler(_arg1:ContextMenuEvent):void{
}
private function towerWait(_arg1:uint, _arg2:uint){
Towers[_arg1].Tower.detect.removeEventListener(MouseEvent.CLICK, TowerClicked);
Towers[_arg1].Tower.detect.buttonMode = false;
Towers[_arg1].WaitingFrom = _arg2;
Towers[_arg1].WaitingTimer = _arg2;
Towers[_arg1].addChild(Towers[_arg1].CT);
if (Towers[_arg1].Size < 35){
Towers[_arg1].CT.scaleX = 0.63;
Towers[_arg1].CT.scaleY = 0.63;
} else {
if (Towers[_arg1].Size < 45){
Towers[_arg1].CT.scaleX = 0.9;
Towers[_arg1].CT.scaleY = 0.9;
};
};
Towers[_arg1].CT.stop();
}
private function removeErrorDisplay(_arg1:TimerEvent):void{
DTGH.removeChild(Err);
errorTimer.removeEventListener(TimerEvent.TIMER, removeErrorDisplay);
}
private function showRange(_arg1:Object, _arg2:Number){
RGH.addChild(rangeCirc);
rangeCirc.x = _arg1.x;
rangeCirc.y = _arg1.y;
rangeCirc.graphics.clear();
rangeCirc.graphics.lineStyle(1, 0);
rangeCirc.graphics.beginFill(0xFFFFFF, 0.15);
rangeCirc.graphics.drawCircle(0, 0, _arg2);
}
private function killCreep(_arg1:Number){
var _local2:uint;
GH.removeChild(Creeps[_arg1]);
Creeps.splice(_arg1, 1);
_local2 = 0;
while (_local2 < Towers.length) {
if (Towers[_local2].Target == _arg1){
Towers[_local2].Target = -1;
} else {
if (Towers[_local2].Target > _arg1){
Towers[_local2].Target = (Towers[_local2].Target - 1);
};
};
_local2++;
};
_local2 = 0;
while (_local2 < Missiles.length) {
if (Missiles[_local2].Target == _arg1){
if (!findMissileATarget(Missiles[_local2])){
Missiles[_local2].Target = -1;
};
} else {
if (Missiles[_local2].Target > _arg1){
if (Creeps.length < 1){
killMissile(_local2);
} else {
Missiles[_local2].Target = (Missiles[_local2].Target - 1);
};
};
};
_local2++;
};
}
private function initEndGame():void{
soundMod.stopMusic();
soundMod.musicScene = "Silent";
pauseGameForEnd();
endGameFlag = 0;
endGameFlag2 = endGameCondition;
CloseResearchMenu2();
CloseTowerMenu2();
if ((((endGameCondition == "Bad")) || ((endGameCondition == "Quit")))){
EndGameClip = new EndGame();
soundMod.soundEndGameBad();
} else {
EndGameClip = new EndGameGood();
soundMod.soundEndGameGood();
};
addChild(EndGameClip);
EndGameClip.gotoAndPlay(2);
EndGameClip.x = 275;
EndGameClip.y = 200;
}
public function ldr_init():void{
var _local1:Array;
var _local2:String;
var _local3:Number;
addChild(ldr_SGH);
setChildIndex(ldr_SGH, 0);
ldr_SGH.x = ldr_centreX;
ldr_SGH.y = ldr_centreY;
addEventListener(Event.ENTER_FRAME, ldr_onEnterFrame);
addEventListener(Event.ENTER_FRAME, ldr_checkLoad);
if (stage.contains(armegaButton)){
armegaButton.addEventListener(MouseEvent.CLICK, callArmegalo, false, 0, true);
};
if (stage.contains(agButton_btn)){
agButton_btn.addEventListener(MouseEvent.CLICK, callAdGa, false, 0, true);
};
siteButton.addEventListener(MouseEvent.CLICK, callFunnylishus);
_local1 = [];
_local1.push("http://www.armegalo.com");
_local1.push("http://armegalo.com");
_local1.push("http://www.funnylishus.com");
_local1.push("http://funnylishus.com");
_local1.push("file:///D|/MAIN/Flash/");
_local1.push("D:/MAIN/Flash/D%2DFence/D%2DFence3.swf");
_local1.push("file:///C|/My%20Crap/DDrive/MAIN/Flash/");
_local1.push("C:/My%20Crap/DDrive/MAIN/Flash/");
_local2 = this.loaderInfo.url;
trace(_local2);
_local3 = 0;
while (_local3 < _local1.length) {
if (_local2.substr(0, _local1[_local3].length) == _local1[_local3]){
permission = true;
};
_local3++;
};
}
function frame1(){
stop();
}
private function ldr_processRot():void{
ldr_SGH.rotation = (ldr_SGH.rotation + Math.sin((ldr_frameCounter / 200)));
}
private function initMenuScreenDisplay():void{
p.push(p0);
p.push(p1);
p.push(p2);
p.push(p3);
p.push(p4);
p.push(p5);
p.push(p6);
p.push(p7);
p.push(p8);
p.push(p9);
p0.addEventListener(MouseEvent.CLICK, pathSelected);
p1.addEventListener(MouseEvent.CLICK, pathSelected);
p2.addEventListener(MouseEvent.CLICK, pathSelected);
p3.addEventListener(MouseEvent.CLICK, pathSelected);
p4.addEventListener(MouseEvent.CLICK, pathSelected);
p5.addEventListener(MouseEvent.CLICK, pathSelected);
p6.addEventListener(MouseEvent.CLICK, pathSelected);
p7.addEventListener(MouseEvent.CLICK, pathSelected);
p8.addEventListener(MouseEvent.CLICK, pathSelected);
p9.addEventListener(MouseEvent.CLICK, pathSelected);
p0.addEventListener(MouseEvent.ROLL_OVER, pathOver);
p1.addEventListener(MouseEvent.ROLL_OVER, pathOver);
p2.addEventListener(MouseEvent.ROLL_OVER, pathOver);
p3.addEventListener(MouseEvent.ROLL_OVER, pathOver);
p4.addEventListener(MouseEvent.ROLL_OVER, pathOver);
p5.addEventListener(MouseEvent.ROLL_OVER, pathOver);
p6.addEventListener(MouseEvent.ROLL_OVER, pathOver);
p7.addEventListener(MouseEvent.ROLL_OVER, pathOver);
p8.addEventListener(MouseEvent.ROLL_OVER, pathOver);
p9.addEventListener(MouseEvent.ROLL_OVER, pathOver);
goBut.addEventListener(MouseEvent.CLICK, gameGo);
if (stage.contains(armegaButton)){
armegaButton.addEventListener(MouseEvent.CLICK, callArmegalo, false, 0, true);
};
if (stage.contains(agButton_btn)){
agButton_btn.addEventListener(MouseEvent.CLICK, callAdGa, false, 0, true);
};
siteButton.addEventListener(MouseEvent.CLICK, callFunnylishus);
pgBut.addEventListener(MouseEvent.CLICK, callInstructions);
mgBut.addEventListener(MouseEvent.CLICK, callLatestVersion);
sbBut.addEventListener(MouseEvent.CLICK, callScoreboards);
PathHighlight.x = p[GamePath].x;
PathHighlight.y = p[GamePath].y;
displaySelectedPathName();
setChildIndex(bd, 0);
}
function frame6(){
globalInit();
gotoAndStop("menu");
}
private function killMissile(_arg1:uint){
Missiles[_arg1].meDead = true;
}
private function rotateCreep(_arg1:Object, _arg2:Number, _arg3:Number){
var _local4:Number;
var _local5:Number;
var _local6:Number;
_local4 = (_arg1.x - _arg2);
_local5 = (_arg1.y - _arg3);
_local6 = Math.atan2(_local5, _local4);
_arg1.Creep.dude.rotation = ((_local6 * 180) / Math.PI);
}
function frame7(){
initMenuScreenDisplay();
}
function frame9(){
initGrats();
}
public function gameGo(_arg1:Event):void{
p0.removeEventListener(MouseEvent.CLICK, pathSelected);
p1.removeEventListener(MouseEvent.CLICK, pathSelected);
p2.removeEventListener(MouseEvent.CLICK, pathSelected);
p3.removeEventListener(MouseEvent.CLICK, pathSelected);
p4.removeEventListener(MouseEvent.CLICK, pathSelected);
p5.removeEventListener(MouseEvent.CLICK, pathSelected);
p6.removeEventListener(MouseEvent.CLICK, pathSelected);
p7.removeEventListener(MouseEvent.CLICK, pathSelected);
p8.removeEventListener(MouseEvent.CLICK, pathSelected);
p9.removeEventListener(MouseEvent.CLICK, pathSelected);
p0.removeEventListener(MouseEvent.ROLL_OVER, pathOver);
p1.removeEventListener(MouseEvent.ROLL_OVER, pathOver);
p2.removeEventListener(MouseEvent.ROLL_OVER, pathOver);
p3.removeEventListener(MouseEvent.ROLL_OVER, pathOver);
p4.removeEventListener(MouseEvent.ROLL_OVER, pathOver);
p5.removeEventListener(MouseEvent.ROLL_OVER, pathOver);
p6.removeEventListener(MouseEvent.ROLL_OVER, pathOver);
p7.removeEventListener(MouseEvent.ROLL_OVER, pathOver);
p8.removeEventListener(MouseEvent.ROLL_OVER, pathOver);
p9.removeEventListener(MouseEvent.ROLL_OVER, pathOver);
goBut.removeEventListener(MouseEvent.CLICK, gameGo);
if (stage.contains(armegaButton)){
armegaButton.removeEventListener(MouseEvent.CLICK, callArmegalo);
};
if (stage.contains(agButton_btn)){
agButton_btn.removeEventListener(MouseEvent.CLICK, callAdGa);
};
siteButton.removeEventListener(MouseEvent.CLICK, callFunnylishus);
pgBut.removeEventListener(MouseEvent.CLICK, callInstructions);
mgBut.removeEventListener(MouseEvent.CLICK, callLatestVersion);
sbBut.removeEventListener(MouseEvent.CLICK, callScoreboards);
gotoAndStop("game");
p.splice(0);
init();
}
private function checkMoveOn(_arg1:Event):void{
if (currentLabel == "Intro1"){
if (sting.stingState == "finished"){
gotoAndStop("Intro2");
};
} else {
if (currentLabel == "Intro2"){
if (sting2.stingState == "finished"){
gotoAndStop("Intro3");
};
} else {
if (currentLabel == "Intro3"){
if (sting3.stingState == "finished"){
gotoAndStop("firstRun");
removeEventListener(Event.ENTER_FRAME, checkMoveOn);
};
};
};
};
}
private function cancelTower(_arg1:KeyboardEvent){
var _local2:Number;
if (_arg1.keyCode == 27){
_local2 = TPC.towersHolder.currentFrame;
if (TowerData.myXml.Tower[(_local2 - 1)].Func == "Weapon"){
if (TPC.contains(rangeCirc)){
TPC.removeChild(rangeCirc);
};
};
if (stage.contains(TPC)){
removeChild(TPC);
};
removeEventListener(Event.ENTER_FRAME, onEnterFrameTowerCheck);
stage.removeEventListener(KeyboardEvent.KEY_DOWN, cancelTower);
};
}
private function pauseGameForEnd():void{
var _local1:uint;
PauseBut.removeEventListener(MouseEvent.CLICK, pauseGame);
removeEventListener(KeyboardEvent.KEY_DOWN, pauseUnPause);
_local1 = 0;
while (_local1 < Missiles.length) {
Missiles[_local1].Missile.mis.stop();
_local1++;
};
removeEventListener(Event.ENTER_FRAME, onEnterFrame);
addEventListener(Event.ENTER_FRAME, pauseManagement);
}
private function onEnterFrame(_arg1:Event):void{
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:Number;
var _local8:Number;
var _local9:Number;
var _local10:Number;
var _local11:Number;
var _local12:uint;
var _local13:Number;
var _local14:Number;
var _local15:uint;
var _local16:uint;
var _local17:Boolean;
var _local18:Number;
var _local19:String;
var _local20:Number;
var _local21:Number;
var _local22:Missile_controller;
if (permission){
stage.focus = this;
towersKilledThisFrame = new Array();
if ((((GAMEON == true)) && ((endGameFlag < 0)))){
wavetimer = (wavetimer + 1);
if ((((Creeps.length == 0)) && ((LevelFinishedOutputting == true)))){
LevelFinishedOutputting = false;
wavetimer = 0;
creepcounter = 0;
CurrentWave = (CurrentWave + 1);
if (WaveData.myXml.Wave[CurrentWave].Name != "NAN"){
creeptimerstop = WaveData.myXml.Wave[CurrentWave].Timing;
creepcounterstop = WaveData.myXml.Wave[CurrentWave].Quantity;
creeptimer = (creeptimerstop + 1);
_local19 = ((((("NOW: " + (CurrentWave + 1)) + " ") + WaveData.myXml.Wave[CurrentWave].Name) + " - HP=") + WaveData.myXml.Wave[CurrentWave].HP);
if (WaveData.myXml.Wave[CurrentWave].Speed > 2){
_local19 = (_local19 + " - FAST");
};
_local19 = (_local19 + String.fromCharCode(13));
if (WaveData.myXml.Wave[(CurrentWave + 1)].Name != "NAN"){
_local19 = (_local19 + ((((("NEXT: " + (CurrentWave + 2)) + " ") + WaveData.myXml.Wave[(CurrentWave + 1)].Name) + " - HP=") + WaveData.myXml.Wave[(CurrentWave + 1)].HP));
if (WaveData.myXml.Wave[(CurrentWave + 1)].Speed > 2){
_local19 = (_local19 + " - FAST");
};
} else {
_local19 = (_local19 + "NEXT: YOU WIN!!!");
};
DisplayCrr(_local19);
_local20 = (1 + BaseInterest);
if (CashTechLevel > 0){
_local20 = (_local20 + (BaseInterest * CashTechLevel));
};
Cash = int((Cash * _local20));
UpdateDisplay();
} else {
endGameCondition = "Good";
initEndGame();
};
};
creeptimer = (creeptimer + 1);
if ((((creeptimer > creeptimerstop)) && ((creepcounter < creepcounterstop)))){
initcreep();
creepcounter = (creepcounter + 1);
creeptimer = 0;
};
if (creepcounter == creepcounterstop){
LevelFinishedOutputting = true;
};
};
_local16 = 0;
while (_local16 < Towers.length) {
if (Towers[_local16].WaitingTimer < 1){
if (Towers[_local16].Func == "Weapon"){
if (Towers[_local16].FireCount > 0){
Towers[_local16].FireCount = (Towers[_local16].FireCount - 1);
};
if (Towers[_local16].Target == -1){
_local21 = 0;
while (_local21 < Creeps.length) {
if (((isInRange((Creeps[_local21].x - Towers[_local16].x), (Creeps[_local21].y - Towers[_local16].y), Towers[_local16].Range)) && (isOnBoard(Creeps[_local21])))){
Towers[_local16].Target = _local21;
break;
};
_local21++;
};
};
if (Towers[_local16].Target != -1){
if (Towers[_local16].TechType != "Shock"){
rotateTower(Towers[_local16], Creeps[Towers[_local16].Target]);
};
if (Towers[_local16].TechType == "Mine"){
if ((((Towers[_local16].fuse == 0)) && (isInRange((Creeps[Towers[_local16].Target].x - Towers[_local16].x), (Creeps[Towers[_local16].Target].y - Towers[_local16].y), Towers[_local16].Range)))){
Towers[_local16].fuse = mineFuseLength;
Towers[_local16].Tower.tow.play();
};
if (Towers[_local16].fuse > 0){
Towers[_local16].fuse = (Towers[_local16].fuse - 1);
if (Towers[_local16].fuse == 0){
towersKilledThisFrame.push(_local16);
blowObject(Towers[_local16]);
explodeObject(Towers[_local16]);
};
};
} else {
if (isInRange((Creeps[Towers[_local16].Target].x - Towers[_local16].x), (Creeps[Towers[_local16].Target].y - Towers[_local16].y), Towers[_local16].Range)){
if (Towers[_local16].FireCount < 1){
if (Towers[_local16].UGTechType == "Bomb"){
_local13 = MissileData.myXml.child(Towers[_local16].TechType).Level[Towers[_local16].Level].StartSpeed;
_local10 = MissileData.myXml.child(Towers[_local16].TechType).Level[Towers[_local16].Level].Accel;
_local11 = MissileData.myXml.child(Towers[_local16].TechType).Level[Towers[_local16].Level].Friction;
_local12 = MissileData.myXml.child(Towers[_local16].TechType).Level[Towers[_local16].Level].Graphic;
_local15 = MissileData.myXml.child(Towers[_local16].TechType).Guided;
_local8 = Creeps[Towers[_local16].Target].x;
_local9 = Creeps[Towers[_local16].Target].y;
_local2 = (Creeps[Towers[_local16].Target].x - Towers[_local16].x);
_local3 = (Creeps[Towers[_local16].Target].y - Towers[_local16].y);
_local14 = rangeIs(_local2, _local3);
_local4 = (Towers[_local16].x + (((_local2 / _local14) * Towers[_local16].Size) / 3));
_local5 = (Towers[_local16].y + (((_local3 / _local14) * Towers[_local16].Size) / 3));
_local6 = (-((_local2 / _local14)) * _local13);
_local7 = (-((_local3 / _local14)) * _local13);
_local22 = new Missile_controller(_local4, _local5, _local6, _local7, _local8, _local9, _local12, Towers[_local16].Range, Towers[_local16].Damage, Towers[_local16].Splash, Towers[_local16].Slow, _local10, _local11, Missiles.length, Towers[_local16].Target, _local15);
MGH.addChild(_local22);
Missiles.push(_local22);
if (Towers[_local16].Name == "Missile Turret"){
soundMod.soundMissile();
};
} else {
if (Towers[_local16].TechType == "Shock"){
soundMod.soundShock();
_local21 = 0;
while (_local21 < Creeps.length) {
if (((isInRange((Creeps[_local21].x - Towers[_local16].x), (Creeps[_local21].y - Towers[_local16].y), Towers[_local16].Range)) && (isOnBoard(Creeps[_local21])))){
damageCreep(Towers[_local16], Creeps[_local21]);
};
_local21++;
};
} else {
if (Towers[_local16].TechType == "GunShock"){
laserCreep(Towers[_local16], Creeps[Towers[_local16].Target]);
} else {
if (Towers[_local16].TechType != "Mine"){
damageCreep(Towers[_local16], Creeps[Towers[_local16].Target]);
};
};
};
};
Towers[_local16].Tower.tow.TowerWep.gotoAndPlay(2);
if (Towers[_local16].Name == "Gun Tower"){
soundMod.soundLittleGun();
} else {
if (Towers[_local16].Name == "Big Gun Tower"){
soundMod.soundBigGun();
} else {
if (Towers[_local16].Name == "Slow Tower"){
soundMod.soundSlowDown();
};
};
};
Towers[_local16].FireCount = Towers[_local16].FireSP;
};
} else {
Towers[_local16].Target = -1;
};
};
} else {
rotateBoredTower(Towers[_local16]);
};
};
} else {
Towers[_local16].WaitingTimer = (Towers[_local16].WaitingTimer - 1);
Towers[_local16].CT.gotoAndStop(int(((Towers[_local16].WaitingTimer / Towers[_local16].WaitingFrom) * 500)));
if (Towers[_local16].WaitingTimer < 1){
towerOn(_local16);
};
};
_local16++;
};
towersKilledThisFrame.forEach(killMultipleTowers);
_local16 = 0;
while (_local16 < Creeps.length) {
_local2 = (Creeps[_local16].x - Creeps[_local16].TXpos);
_local3 = (Creeps[_local16].y - Creeps[_local16].TYpos);
_local14 = rangeIs(_local2, _local3);
Creeps[_local16].x = (Creeps[_local16].x - ((_local2 / _local14) * Creeps[_local16].CurrentSP));
Creeps[_local16].y = (Creeps[_local16].y - ((_local3 / _local14) * Creeps[_local16].CurrentSP));
if (Creeps[_local16].CurrentSP < (Creeps[_local16].MaxSP / 2)){
Creeps[_local16].CurrentSP = (Creeps[_local16].MaxSP / 2);
};
if (Creeps[_local16].CurrentSP < Creeps[_local16].MaxSP){
Creeps[_local16].CurrentSP = (Creeps[_local16].CurrentSP * Creeps[_local16].RecoverSP);
};
if (Creeps[_local16].CurrentSP > Creeps[_local16].MaxSP){
Creeps[_local16].CurrentSP = Creeps[_local16].MaxSP;
};
if ((((((((Creeps[_local16].CurrentNode > 1)) && ((((((((Creeps[_local16].x > 560)) || ((Creeps[_local16].x < -10)))) || ((Creeps[_local16].y > 410)))) || ((Creeps[_local16].y < -10)))))) || ((((Creeps[_local16].TXpos == -1)) && ((Creeps[_local16].TYpos == -1)))))) || ((Creeps[_local16].CurrentHP <= 0)))){
if (Creeps[_local16].CurrentHP <= 0){
Cash = (Cash + Creeps[_local16].Worth);
UpdateDisplay();
killCreep(_local16);
} else {
Lives = (Lives - 1);
UpdateDisplay();
killCreep(_local16);
};
} else {
if (_local14 < Creeps[_local16].NodeRange){
Creeps[_local16].CurrentNode = (Creeps[_local16].CurrentNode + 1);
Creeps[_local16].TXpos = PathData.myXml.Path[GamePath].Node[Creeps[_local16].CurrentNode].Xpos;
Creeps[_local16].TYpos = PathData.myXml.Path[GamePath].Node[Creeps[_local16].CurrentNode].Ypos;
rotateCreep(Creeps[_local16], Creeps[_local16].TXpos, Creeps[_local16].TYpos);
};
};
_local16++;
};
_local16 = 0;
while (_local16 < Missiles.length) {
if (!Missiles[_local16].meDead){
if (Missiles[_local16].Guided == 1){
if (Missiles[_local16].Target != -1){
_local2 = (Creeps[Missiles[_local16].Target].x - Missiles[_local16].x);
_local3 = (Creeps[Missiles[_local16].Target].y - Missiles[_local16].y);
_local14 = rangeIs(_local2, _local3);
Missiles[_local16].xa = ((_local2 / _local14) * Missiles[_local16].Accel);
Missiles[_local16].ya = ((_local3 / _local14) * Missiles[_local16].Accel);
Missiles[_local16].xs = (Missiles[_local16].xs - Missiles[_local16].xa);
Missiles[_local16].ys = (Missiles[_local16].ys - Missiles[_local16].ya);
Missiles[_local16].xs = (Missiles[_local16].xs * Missiles[_local16].Friction);
Missiles[_local16].ys = (Missiles[_local16].ys * Missiles[_local16].Friction);
Missiles[_local16].x = (Missiles[_local16].x - Missiles[_local16].xs);
Missiles[_local16].y = (Missiles[_local16].y - Missiles[_local16].ys);
rotateObject(Missiles[_local16], Creeps[Missiles[_local16].Target]);
if (Missiles[_local16].hitTestObject(Creeps[Missiles[_local16].Target].Creep.detect)){
damageCreep(Missiles[_local16], Creeps[Missiles[_local16].Target]);
explodeObject(Creeps[Missiles[_local16].Target]);
killMissile(_local16);
soundMod.soundBoom();
_local16--;
};
} else {
if ((((Missiles[_local16].xa == 0)) && ((Missiles[_local16].ya == 0)))){
Missiles[_local16].xa = ((Math.random() * 2) - 1);
Missiles[_local16].ya = ((Math.random() * 2) - 1);
};
Missiles[_local16].xs = (Missiles[_local16].xs - Missiles[_local16].xa);
Missiles[_local16].ys = (Missiles[_local16].ys - Missiles[_local16].ya);
Missiles[_local16].xs = (Missiles[_local16].xs * Missiles[_local16].Friction);
Missiles[_local16].ys = (Missiles[_local16].ys * Missiles[_local16].Friction);
rotateObject2(Missiles[_local16], (Missiles[_local16].x + Missiles[_local16].xa), (Missiles[_local16].y + Missiles[_local16].ya));
Missiles[_local16].x = (Missiles[_local16].x - Missiles[_local16].xs);
Missiles[_local16].y = (Missiles[_local16].y - Missiles[_local16].ys);
_local17 = findMissileATarget(Missiles[_local16]);
if ((((((((Missiles[_local16].x < boardMinX)) || ((Missiles[_local16].x > boardMaxX)))) || ((Missiles[_local16].y < boardMinY)))) || ((Missiles[_local16].y > boardMaxY)))){
killMissile(_local16);
};
};
} else {
Missiles[_local16].rotation = (Missiles[_local16].rotation + Missiles[_local16].rs);
_local2 = (Missiles[_local16].xt - Missiles[_local16].x);
_local3 = (Missiles[_local16].yt - Missiles[_local16].y);
Missiles[_local16].xs = (_local2 * Missiles[_local16].Friction);
Missiles[_local16].ys = (_local3 * Missiles[_local16].Friction);
Missiles[_local16].x = (Missiles[_local16].x + Missiles[_local16].xs);
Missiles[_local16].y = (Missiles[_local16].y + Missiles[_local16].ys);
if ((((((((Missiles[_local16].xs < 0.4)) && ((Missiles[_local16].xs > -0.4)))) && ((Missiles[_local16].ys < 0.4)))) && ((Missiles[_local16].ys > -0.4)))){
blowObject(Missiles[_local16]);
explodeObject(Missiles[_local16]);
killMissile(_local16);
soundMod.soundBoom();
};
};
};
_local16++;
};
_local16 = 0;
while (_local16 < Missiles.length) {
if (Missiles[_local16].meDead == true){
MGH.removeChild(Missiles[_local16]);
Missiles.splice(_local16, 1);
};
_local16++;
};
runExplosions();
runGame();
};
soundMod.processSoundCounters();
}
private function rotateObject(_arg1:Object, _arg2:Object){
var _local3:Number;
var _local4:Number;
var _local5:Number;
_local3 = (_arg1.x - _arg2.x);
_local4 = (_arg1.y - _arg2.y);
_local5 = Math.atan2(_local4, _local3);
_arg1.rotation = ((_local5 * 180) / Math.PI);
}
private function prepTower(_arg1:MouseEvent){
var _local2:Number;
var _local3:Number;
var _local4:String;
var _local5:String;
var _local6:String;
var _local7:String;
var _local8:Boolean;
soundMod.soundClick();
if (stage.contains(ResearchMenu)){
removeChild(ResearchMenu);
};
if (stage.contains(TowerMenu)){
removeChild(TowerMenu);
};
_local2 = _arg1.currentTarget.name.slice(6, _arg1.currentTarget.name.length);
_local3 = TowerData.myXml.Tower[(_local2 - 1)].Cost;
_local4 = TowerData.myXml.Tower[(_local2 - 1)].Func;
_local5 = TowerData.myXml.Tower[(_local2 - 1)].TechType;
_local6 = TowerData.myXml.Tower[(_local2 - 1)].UGTechType;
_local7 = TowerData.myXml.Tower[(_local2 - 1)].Level[0].TechReq;
_local8 = true;
if (_local4 == "Research"){
if ((((_local5 == "Gun")) && (gotGunResearch))){
_local8 = false;
DisplayError("We already have a Gun Research Centre");
};
if ((((_local5 == "Bomb")) && (gotBombResearch))){
_local8 = false;
DisplayError("We already have an Explosives Research Centre");
};
if ((((_local5 == "Slow")) && (gotSlowResearch))){
_local8 = false;
DisplayError("We already have an Electrics Research Centre");
};
if ((((_local5 == "Cash")) && (gotCashResearch))){
_local8 = false;
DisplayError("We already have a Finance Centre");
};
if ((((_local5 == "Mine")) && (gotMineResearch))){
_local8 = false;
DisplayError("We already have a Mine Factory");
};
} else {
_local8 = TowerSelectionOKorNot(_local6, _local7);
};
if (Cash < _local3){
_local8 = false;
cantAfford();
};
if (_local8 == true){
closeControlScreen(_arg1);
placeTower(_local2);
};
}
public function displaySelectedPathName():void{
details.text = PathData.myXml.Path[GamePath].Details;
}
private function setupContextMenu():void{
var _local1:ContextMenu;
trace("cminit");
_local1 = new ContextMenu();
_local1.addEventListener(ContextMenuEvent.MENU_SELECT, onContextMenuHandler);
_local1.hideBuiltInItems();
_local1.builtInItems.quality = true;
_local1.builtInItems.zoom = true;
this.contextMenu = _local1;
}
public function pathOut(_arg1:Event):void{
_arg1.currentTarget.removeEventListener(MouseEvent.ROLL_OUT, pathOut);
displaySelectedPathName();
}
private function removeYesNo():void{
if (this.contains(yn)){
removeChild(yn);
};
yn.yesbut.removeEventListener(MouseEvent.CLICK, quitGame);
yn.nobut.removeEventListener(MouseEvent.CLICK, dontQuitGame);
yn.yesbut.removeEventListener(MouseEvent.CLICK, SellTower);
yn.nobut.removeEventListener(MouseEvent.CLICK, dontSellTower);
}
private function TowerClicked(_arg1:MouseEvent){
soundMod.soundClick();
removeYesNo();
if (endGameFlag < 0){
closeControlScreen(_arg1);
SelectedTower = _arg1.currentTarget.parent.parent.Thisis;
if (Towers[SelectedTower].Func == "Weapon"){
showRange(_arg1.currentTarget.parent.parent, _arg1.currentTarget.parent.parent.Range);
if (stage.contains(ResearchMenu)){
removeChild(ResearchMenu);
};
addChild(TowerMenu);
TowerMenu.x = (_arg1.currentTarget.parent.parent.x + 17);
TowerMenu.y = (_arg1.currentTarget.parent.parent.y + 17);
if (TowerMenu.x > (550 - 182)){
TowerMenu.x = (TowerMenu.x - 217);
};
if (TowerMenu.y > (400 - 216)){
TowerMenu.y = (TowerMenu.y - 233);
};
if (TowerMenu.y < 0){
TowerMenu.y = 0;
};
UpdateTowerMenu();
TowerMenu.closebut.addEventListener(MouseEvent.CLICK, CloseTowerMenu);
TowerMenu.upgradebut.addEventListener(MouseEvent.CLICK, TowerMenuClick);
TowerMenu.sellbut.addEventListener(MouseEvent.CLICK, confirmSellTower);
} else {
if (Towers[SelectedTower].Func == "Research"){
rangeCirc.graphics.clear();
if (stage.contains(TowerMenu)){
removeChild(TowerMenu);
};
addChild(ResearchMenu);
ResearchMenu.x = (_arg1.currentTarget.parent.parent.x + 17);
ResearchMenu.y = (_arg1.currentTarget.parent.parent.y + 17);
if (ResearchMenu.x > (550 - 182)){
ResearchMenu.x = (ResearchMenu.x - 217);
};
if (ResearchMenu.y > (400 - 216)){
ResearchMenu.y = (ResearchMenu.y - 233);
};
if (ResearchMenu.y < 0){
ResearchMenu.y = 0;
};
UpdateResearchMenu();
ResearchMenu.closebut.addEventListener(MouseEvent.CLICK, CloseResearchMenu);
ResearchMenu.upgradebut.addEventListener(MouseEvent.CLICK, ResearchMenuClick);
} else {
SelectedTower = -1;
};
};
};
}
private function laserCreep(_arg1:Object, _arg2:Object){
_arg1.myShape.graphics.clear();
_arg1.myShape.graphics.lineStyle(5, 0xFFFFFF, 1);
_arg1.myShape.graphics.lineTo((_arg2.x - _arg1.x), (_arg2.y - _arg1.y));
_arg1.framecount = 0;
_arg1.addEventListener(Event.ENTER_FRAME, _arg1.deleteLaserAfterOneFrame);
damageCreep(_arg1, _arg2);
soundMod.soundLaser();
}
private function runExplosions():void{
var _local1:uint;
_local1 = 0;
while (_local1 < Explosions.length) {
if (Explosions[_local1].boom.currentFrame == Explosions[_local1].boom.totalFrames){
EGH.removeChild(Explosions[_local1]);
Explosions.splice(_local1, 1);
};
_local1++;
};
}
private function init():void{
addEventListener(Event.ENTER_FRAME, preStartManagement);
Cash = (150 + Number(PathData.myXml.Path[GamePath].BonusCash));
Lives = MaxLives;
endGameFlag = -1;
CurrentWave = -1;
gotGunResearch = false;
gotBombResearch = false;
gotSlowResearch = false;
gotMineResearch = false;
gotCashResearch = false;
GunTechLevel = -1;
BombTechLevel = -1;
SlowTechLevel = -1;
MineTechLevel = -1;
CashTechLevel = -1;
LevelFinishedOutputting = true;
initDisplay();
initMainGameDisplay();
tops();
soundMod.soundGameStart();
}
private function CloseTowerMenu(_arg1:MouseEvent){
soundMod.soundClick();
CloseTowerMenu2();
}
private function closeControlScreen(_arg1:MouseEvent):void{
ControlScreen.gotoAndStop(1);
ControlScreen.OpenControlButton.removeEventListener(MouseEvent.MOUSE_OVER, closeControlScreen);
ControlScreen.OpenControlButton.addEventListener(MouseEvent.MOUSE_OVER, openControlScreen);
}
private function UpdateTowerMenu(){
var _local1:Number;
var _local2:*;
var _local3:Number;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:Number;
_local1 = getAdvantage(Towers[SelectedTower].UGTechType);
_local2 = Towers[SelectedTower].TowerType;
_local3 = Towers[SelectedTower].Level;
_local4 = TowerData.myXml.Tower[(_local2 - 1)].Level[(_local3 + 1)].Cost;
_local5 = TowerData.myXml.Tower[(_local2 - 1)].Level[(_local3 + 1)].TechReq;
if (_local5 < 0){
_local5 = 0;
};
TowerMenu.towertype = _local2;
TowerMenu.towerlevel.text = ("Level " + _local3.toString());
TowerMenu.towername.text = Towers[SelectedTower].Name;
_local6 = Towers[SelectedTower].Range.toFixed(2);
TowerMenu.towerrange.text = _local6;
_local6 = Towers[SelectedTower].Damage.toFixed(2);
TowerMenu.towerdamage.text = _local6;
TowerMenu.towerspeed.text = Towers[SelectedTower].FireSP;
_local7 = Towers[SelectedTower].Slow;
_local7 = (100 - (_local7 * 100));
TowerMenu.towerslow.text = (String(_local7) + "%");
_local6 = Towers[SelectedTower].Splash.toFixed(2);
TowerMenu.towersplash.text = _local6;
if (_local4 != -1){
_local6 = (TowerData.myXml.Tower[(_local2 - 1)].Level[(_local3 + 1)].Range * _local1);
trace(_local6);
_local6 = Number(_local6.toFixed(2));
trace(_local6);
TowerMenu.towerrangeu.text = _local6.toString();
_local6 = (TowerData.myXml.Tower[(_local2 - 1)].Level[(_local3 + 1)].Damage * _local1);
_local6 = Number(_local6.toFixed(2));
TowerMenu.towerdamageu.text = _local6.toString();
TowerMenu.towerspeedu.text = TowerData.myXml.Tower[(_local2 - 1)].Level[(_local3 + 1)].FireSP;
_local7 = TowerData.myXml.Tower[(_local2 - 1)].Level[(_local3 + 1)].Slow;
_local7 = (100 - (_local7 * 100));
TowerMenu.towerslowu.text = (String(_local7) + "%");
_local6 = (TowerData.myXml.Tower[(_local2 - 1)].Level[(_local3 + 1)].Splash * _local1);
_local6 = Number(_local6.toFixed(2));
TowerMenu.towersplashu.text = _local6.toString();
TowerMenu.upgradecost.text = _local4.toString();
TowerMenu.upgradetechreq.text = _local5.toString();
} else {
TowerMenu.towerrangeu.text = "N/A";
TowerMenu.towerdamageu.text = "N/A";
TowerMenu.towerspeedu.text = "N/A";
TowerMenu.towerslowu.text = "N/A";
TowerMenu.towersplashu.text = "N/A";
TowerMenu.upgradecost.text = "N/A";
TowerMenu.upgradetechreq.text = "N/A";
};
showRange(Towers[SelectedTower], Towers[SelectedTower].Range);
}
private function preStartManagement(_arg1:Event):void{
var _local2:int;
_local2 = 0;
while (_local2 < Towers.length) {
if (Towers[_local2].WaitingTimer > 0){
Towers[_local2].WaitingTimer = (Towers[_local2].WaitingTimer - 1);
Towers[_local2].CT.gotoAndStop(int(((Towers[_local2].WaitingTimer / Towers[_local2].WaitingFrom) * 500)));
if (Towers[_local2].WaitingTimer < 1){
towerOn(_local2);
};
};
_local2++;
};
}
private function CloseTowerMenu3(_arg1:MouseEvent){
CloseTowerMenu2();
}
private function runGame():void{
if ((((Lives < 1)) && ((endGameFlag == -1)))){
endGameCondition = "Bad";
initEndGame();
};
if (endGameFlag > -1){
endGameFlag = (endGameFlag + 1);
};
if (endGameFlag == 99){
clearGameScreen();
};
if (endGameFlag > endGameAt){
killExplosions();
removeEventListener(Event.ENTER_FRAME, pauseManagement);
endGameFlag = -1;
if (endGameCondition != "Quit"){
gotoAndStop("grats");
} else {
soundMod.startMusic();
gotoAndStop("menu");
};
};
}
private function CloseTowerMenu2(){
if (this.contains(TowerMenu)){
removeChild(TowerMenu);
TowerMenu.closebut.removeEventListener(MouseEvent.CLICK, CloseTowerMenu);
TowerMenu.upgradebut.removeEventListener(MouseEvent.CLICK, TowerMenuClick);
TowerMenu.sellbut.removeEventListener(MouseEvent.CLICK, confirmSellTower);
rangeCirc.graphics.clear();
SelectedTower = -1;
};
}
private function clearGameScreen():void{
var _local1:uint;
_local1 = 0;
while (_local1 < Missiles.length) {
Missiles[_local1].killme();
_local1++;
};
Missiles.splice(0);
_local1 = 0;
while (_local1 < Creeps.length) {
Creeps[_local1].killme();
_local1++;
};
Creeps.splice(0);
calculateFinalScore();
_local1 = 0;
while (_local1 < Towers.length) {
TGH.removeChild(Towers[_local1]);
_local1++;
};
Towers.splice(0);
_local1 = 0;
while (_local1 < Explosions.length) {
EGH.addChild(Explosions[_local1]);
_local1++;
};
Explosions.splice(0);
removeChild(ControlScreen);
removeChild(PathSel);
if (DTGH.contains(PauseBut)){
DTGH.removeChild(PauseBut);
};
if (DTGH.contains(StartBut)){
DTGH.removeChild(StartBut);
};
DBGH.removeChild(GamePanel);
DBGH.removeChild(Crr);
DBGH.removeChild(Car);
GAMEON = false;
removeChild(EndGameClip);
}
private function UpdateResearchMenu(){
var _local1:*;
var _local2:Number;
var _local3:Number;
_local1 = Towers[SelectedTower].TowerType;
_local2 = Towers[SelectedTower].Level;
_local3 = TowerData.myXml.Tower[(_local1 - 1)].Level[(_local2 + 1)].Cost;
ResearchMenu.towertype = _local1;
ResearchMenu.towerlevel.text = ("Level " + _local2.toString());
ResearchMenu.towername.text = TowerData.myXml.Tower[(_local1 - 1)].Name;
if (_local3 != -1){
ResearchMenu.upgradecost.text = _local3.toString();
} else {
ResearchMenu.upgradecost.text = "N/A";
};
}
private function blankControlScreenTowerDisplay():void{
var _local1:String;
_local1 = TowerData.myXml.DefaultInfo;
ControlScreen.Screen.towername.text = "";
ControlScreen.Screen.towercost.text = "";
ControlScreen.Screen.ct.text = "";
ControlScreen.Screen.Info.text = _local1;
}
private function ldr_processStars():void{
var _local1:uint;
_local1 = 0;
while (_local1 < ldr_stars.length) {
ldr_stars[_local1].star.x = (ldr_stars[_local1].star.x + ldr_stars[_local1].xs);
ldr_stars[_local1].star.y = (ldr_stars[_local1].star.y + ldr_stars[_local1].ys);
ldr_stars[_local1].xs = (ldr_stars[_local1].xs * ldr_universalAccel);
ldr_stars[_local1].ys = (ldr_stars[_local1].ys * ldr_universalAccel);
ldr_stars[_local1].scal = (ldr_stars[_local1].scal * ldr_universalAccel);
ldr_stars[_local1].star.scaleX = ldr_stars[_local1].scal;
ldr_stars[_local1].star.scaleY = ldr_stars[_local1].scal;
ldr_stars[_local1].star.rotation = -(ldr_SGH.rotation);
if (((((((((ldr_stars[_local1].star.x + (ldr_stars[_local1].star.width / 2)) < ldr_leftEdge)) || (((ldr_stars[_local1].star.y + (ldr_stars[_local1].star.height / 2)) < ldr_topEdge)))) || (((ldr_stars[_local1].star.x - (ldr_stars[_local1].star.width / 2)) > ldr_rightEdge)))) || (((ldr_stars[_local1].star.y - (ldr_stars[_local1].star.height / 2)) > ldr_bottomEdge)))){
ldr_SGH.removeChild(ldr_stars[_local1].star);
ldr_stars.splice(_local1, 1);
_local1--;
};
_local1++;
};
}
private function dropTower(_arg1:MouseEvent){
var _local2:Number;
var _local3:Boolean;
var _local4:String;
var _local5:String;
var _local6:String;
var _local7:Number;
var _local8:Number;
var _local9:Number;
var _local10:Number;
var _local11:Number;
var _local12:Number;
var _local13:Number;
var _local14:String;
var _local15:Tower_controller;
var _local16:Number;
var _local17:Number;
_local2 = TPC.towersHolder.currentFrame;
_local3 = checkTowerPos();
_local4 = TowerData.myXml.Tower[(_local2 - 1)].Func;
_local5 = TowerData.myXml.Tower[(_local2 - 1)].TechType;
_local6 = TowerData.myXml.Tower[(_local2 - 1)].UGTechType;
_local7 = 0;
if (_local3 == true){
if (_local4 == "Weapon"){
if (TPC.contains(rangeCirc)){
TPC.removeChild(rangeCirc);
};
_local7 = getAdvantage(_local6);
} else {
if (_local4 == "Research"){
if (_local5 == "Gun"){
gotGunResearch = true;
};
if (_local5 == "Bomb"){
gotBombResearch = true;
};
if (_local5 == "Slow"){
gotSlowResearch = true;
};
if (_local5 == "Mine"){
gotMineResearch = true;
};
if (_local5 == "Cash"){
gotCashResearch = true;
};
};
};
_local8 = TowerData.myXml.Tower[(_local2 - 1)].Size;
_local9 = (TowerData.myXml.Tower[(_local2 - 1)].Level[0].Range * _local7);
_local10 = (TowerData.myXml.Tower[(_local2 - 1)].Level[0].Damage * _local7);
_local11 = TowerData.myXml.Tower[(_local2 - 1)].Level[0].FireSP;
_local12 = TowerData.myXml.Tower[(_local2 - 1)].Level[0].Slow;
_local13 = (TowerData.myXml.Tower[(_local2 - 1)].Level[0].Splash * _local7);
_local14 = TowerData.myXml.Tower[(_local2 - 1)].Name;
_local15 = new Tower_controller(TPC.x, TPC.y, _local2, _local9, _local10, _local11, _local13, _local12, Towers.length, _local8, _local4, _local5, _local6, _local14, TowerData.myXml.Tower[(_local2 - 1)].Cost);
TGH.addChild(_local15);
Towers.push(_local15);
removeChild(TPC);
_local16 = TowerData.myXml.Tower[(_local2 - 1)].Level[0].UpgradeTime;
towerWait((Towers.length - 1), _local16);
Cash = (Cash - TowerData.myXml.Tower[(_local2 - 1)].Cost);
UpdateDisplay();
soundMod.buildingThump();
_local17 = 0;
while (_local17 < Towers.length) {
if (Towers[_local17].Name == "Laser MegaTower"){
TGH.setChildIndex(Towers[_local17], (TGH.numChildren - 1));
};
_local17++;
};
};
}
public function submitScore(_arg1:MouseEvent):void{
submitScore2();
}
private function enterToSubmit(_arg1:KeyboardEvent):void{
if (_arg1.keyCode == 13){
submitScore2();
};
}
public function callArmegalo(_arg1:MouseEvent):void{
var url:String;
var request:URLRequest;
var event = _arg1;
soundMod.soundClick();
url = "http://www.armegalo.com";
request = new URLRequest(url);
try {
navigateToURL(request, "_blank");
} catch(e:Error) {
};
}
private function getAdvantage(_arg1:String){
var _local2:Number;
_local2 = 0;
if (_arg1 == "Gun"){
_local2 = GunTechLevel;
};
if (_arg1 == "Bomb"){
_local2 = BombTechLevel;
};
if (_arg1 == "Slow"){
_local2 = SlowTechLevel;
};
if (_arg1 == "Mine"){
_local2 = (MineTechLevel * 3);
};
if (_arg1 == "Cash"){
_local2 = CashTechLevel;
};
if (_arg1 == "Multi"){
_local2 = ((GunTechLevel + BombTechLevel) + SlowTechLevel);
};
if (_local2 == -1){
_local2 = 0;
};
_local2 = (1 + (_local2 / 25));
return (_local2);
}
public function callFunnylishus(_arg1:MouseEvent):void{
var url:String;
var request:URLRequest;
var event = _arg1;
soundMod.soundClick();
url = "http://www.funnylishus.com";
request = new URLRequest(url);
try {
navigateToURL(request, "_blank");
} catch(e:Error) {
};
}
private function blowObject(_arg1:Object){
var _local2:Number;
var _local3:uint;
var _local4:Number;
_local3 = 0;
while (_local3 < Creeps.length) {
_local2 = rangeIs((_arg1.x - Creeps[_local3].x), (_arg1.y - Creeps[_local3].y));
if ((((_local2 < _arg1.Splash)) && (isOnBoard(Creeps[_local3])))){
Creeps[_local3].CurrentHP = (Creeps[_local3].CurrentHP - (-((_arg1.Damage * (_local2 / _arg1.Splash))) + _arg1.Damage));
_local4 = (1 - ((1 - _arg1.Slow) / Creeps[_local3].SlowResist));
if (_local4 != 1){
Creeps[_local3].CurrentSP = (Creeps[_local3].CurrentSP * (1 - ((1 - _local4) / 1.1)));
};
};
_local3++;
};
}
private function initDisplay():void{
TPC = new TowerPlacementController();
DBGH = new GameHolder();
GH = new GameHolder();
TGH = new GameHolder();
RGH = new GameHolder();
MGH = new GameHolder();
EGH = new GameHolder();
PathSel = new PathSelector();
ControlScreen = new ControlScreenControl();
StartBut = new StartButton();
PauseBut = new PauseButton();
Err = new ErrorReadout();
Crr = new CreepReadout();
Car = new CashReadout();
TowerMenu = new TowerInfo();
ResearchMenu = new ResearchInfo();
GamePanel = new BottomPanel();
yn = new AreYouSure();
Border = new border();
addChild(PathSel);
addChild(RGH);
addChild(GH);
addChild(TGH);
addChild(EGH);
addChild(MGH);
addChild(ControlScreen);
addChild(DBGH);
addChild(Border);
Border.x = -599.8;
Border.y = -417.8;
PathSel.visible = false;
tops();
}
public function callLatestVersion(_arg1:MouseEvent):void{
var url:String;
var request:URLRequest;
var event = _arg1;
soundMod.soundClick();
url = "http://www.funnylishus.com/index.php?custom=randomstuff&subcust=beginning";
request = new URLRequest(url);
try {
navigateToURL(request, "_blank");
} catch(e:Error) {
};
}
private function dontQuitGame(_arg1:MouseEvent){
removeYesNo();
}
private function initMainGameDisplay():void{
PathSel.visible = true;
PathSel.gotoAndStop((GamePath + 1));
DBGH.addChild(GamePanel);
GamePanel.y = 400;
GamePanel.armegaButton.addEventListener(MouseEvent.CLICK, callArmegalo, false, 0, true);
GamePanel.agButton_btn.addEventListener(MouseEvent.CLICK, callAdGa, false, 0, true);
GamePanel.siteButton.addEventListener(MouseEvent.CLICK, callFunnylishus, false, 0, true);
DBGH.addChild(Crr);
Crr.x = 129;
Crr.y = 403;
ControlScreen.Screen.Towerb1.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb2.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb3.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb4.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb5.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb6.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb7.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb8.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb20.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb21.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb22.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb23.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb24.addEventListener(MouseEvent.CLICK, prepTower, false, 0, true);
ControlScreen.Screen.Towerb1.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb2.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb3.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb4.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb5.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb6.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb7.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb8.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb20.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb21.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb22.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb23.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb24.addEventListener(MouseEvent.MOUSE_OVER, seeTower, false, 0, true);
ControlScreen.Screen.Towerb1.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.Screen.Towerb2.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.Screen.Towerb3.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.Screen.Towerb4.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.Screen.Towerb5.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.Screen.Towerb6.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.Screen.Towerb7.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.Screen.Towerb8.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.Screen.Towerb20.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.Screen.Towerb21.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.Screen.Towerb22.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.Screen.Towerb23.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.Screen.Towerb24.addEventListener(MouseEvent.MOUSE_OUT, noTower, false, 0, true);
ControlScreen.OpenControlButton.addEventListener(MouseEvent.MOUSE_OVER, openControlScreen);
ControlScreen.Screen.quitGameBut.addEventListener(MouseEvent.CLICK, confirmQuitGame, false, 0, true);
blankControlScreenTowerDisplay();
DBGH.addChild(Car);
Car.y = 4;
Car.y = 404;
DTGH.addChild(StartBut);
StartBut.x = 0x0202;
StartBut.y = 425;
StartBut.addEventListener(MouseEvent.CLICK, startGame);
UpdateDisplay();
addEventListener(KeyboardEvent.KEY_DOWN, pauseUnPause);
}
private function reStartGame2():void{
var _local1:uint;
soundMod.soundClick();
_local1 = 0;
while (_local1 < Missiles.length) {
Missiles[_local1].Missile.mis.play();
_local1++;
};
removeEventListener(Event.ENTER_FRAME, pauseManagement);
addEventListener(Event.ENTER_FRAME, onEnterFrame);
GAMEON = true;
DTGH.removeChild(StartBut);
DTGH.addChild(PauseBut);
PauseBut.x = 0x0202;
PauseBut.y = 425;
PauseBut.addEventListener(MouseEvent.CLICK, pauseGame);
gamePaused = false;
}
private function tops():void{
setChildIndex(DTGH, (numChildren - 1));
setChildIndex(Border, (numChildren - 1));
}
private function confirmQuitGame(_arg1:MouseEvent):void{
initYesNo();
yn.yesbut.addEventListener(MouseEvent.CLICK, quitGame);
yn.nobut.addEventListener(MouseEvent.CLICK, dontQuitGame);
}
public function pathSelected(_arg1:Event):void{
GamePath = _arg1.currentTarget.name.slice(1, _arg1.currentTarget.name.length);
PathHighlight.x = _arg1.currentTarget.x;
PathHighlight.y = _arg1.currentTarget.y;
}
private function rotateCreepAfterOneFrame(_arg1:Event):void{
removeEventListener(Event.ENTER_FRAME, rotateCreepAfterOneFrame);
}
private function noTower(_arg1:MouseEvent){
blankControlScreenTowerDisplay();
}
private function DisplayCrr(_arg1:String){
Crr.CreepMessage.text = _arg1;
}
private function initcreep():void{
var _local1:Number;
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:Number;
var _local8:Number;
var _local9:Number;
var _local10:Creep_controller;
_local1 = (CurrentWave + 1);
_local2 = PathData.myXml.Path[GamePath].Node[0].Xpos;
_local3 = PathData.myXml.Path[GamePath].Node[0].Ypos;
_local4 = PathData.myXml.Path[GamePath].Node[1].Xpos;
_local5 = PathData.myXml.Path[GamePath].Node[1].Ypos;
_local6 = WaveData.myXml.Wave[CurrentWave].HP;
_local7 = WaveData.myXml.Wave[CurrentWave].Speed;
_local8 = WaveData.myXml.Wave[CurrentWave].Worth;
_local9 = WaveData.myXml.Wave[CurrentWave].SlowResist;
_local10 = new Creep_controller(_local2, _local3, _local4, _local5, _local1, _local6, _local6, _local7, _local7, 1.01, _local9, 0, _local8);
GH.addChild(_local10);
GH.setChildIndex(_local10, 0);
Creeps.push(_local10);
addEventListener(Event.ENTER_FRAME, rotateCreepAfterOneFrame);
}
private function killExplosions():void{
var _local1:uint;
_local1 = 0;
while (_local1 < Explosions.length) {
EGH.removeChild(Explosions[_local1]);
_local1++;
};
Explosions.splice(0);
}
private function openControlScreen(_arg1:MouseEvent):void{
CloseTowerMenu2();
CloseResearchMenu2();
if (endGameFlag < 0){
ControlScreen.gotoAndStop(2);
ControlScreen.OpenControlButton.removeEventListener(MouseEvent.MOUSE_OVER, openControlScreen);
ControlScreen.OpenControlButton.addEventListener(MouseEvent.MOUSE_OVER, closeControlScreen);
};
}
private function ldr_startStar():void{
var _local1:ldr_StarContainer;
var _local2:Number;
var _local3:Number;
var _local4:Object;
_local1 = new ldr_StarContainer();
do {
_local2 = ((Math.random() * ldr_starXS) - (ldr_starXS / 2));
_local3 = ((Math.random() * ldr_starYS) - (ldr_starYS / 2));
} while ((((((((_local2 < ldr_minSpeed)) && ((_local2 > -(ldr_minSpeed))))) && ((_local3 < ldr_minSpeed)))) && ((_local3 > -(ldr_minSpeed)))));
_local4 = {xs:_local2, ys:_local3, star:_local1, typeOfStar:int((Math.random() * 2)), scal:ldr_startScale};
if ((Math.random() * 200) < 1){
_local4.typeOfStar = 2;
};
_local4.star.x = ((_local4.xs * ((Math.random() * 2000) / ldr_startPoint)) * ldr_universalAccel);
_local4.star.y = ((_local4.ys * ((Math.random() * 2000) / ldr_startPoint)) * ldr_universalAccel);
_local4.star.gotoAndStop((_local4.typeOfStar + 1));
ldr_SGH.addChild(_local4.star);
ldr_stars.push(_local4);
}
public function ldr_checkLoad(_arg1:Event):void{
var _local2:Number;
var _local3:Number;
var _local4:uint;
_local2 = ((this.loaderInfo.bytesLoaded / this.loaderInfo.bytesTotal) * 100);
ldr.lpc.text = (int(_local2) + "%");
_local3 = (_local2 * _local2);
_local3 = (_local3 / 100);
ldr.gob.rotation = (ldr.gob.rotation + _local3);
ldr.gob2.rotation = (ldr.gob.rotation - (_local3 * 0.15));
ldr.gob3.rotation = (ldr.gob.rotation - (_local3 * 0.3));
ldr.gob.gotoAndStop(int(_local2));
ldr.gob2.gotoAndStop(int(_local2));
ldr.gob3.gotoAndStop(int(_local2));
if ((((_local2 == 100)) && (permission))){
removeEventListener(Event.ENTER_FRAME, ldr_checkLoad);
removeEventListener(Event.ENTER_FRAME, ldr_onEnterFrame);
if (stage.contains(armegaButton)){
armegaButton.removeEventListener(MouseEvent.CLICK, callArmegalo);
};
if (stage.contains(agButton_btn)){
agButton_btn.removeEventListener(MouseEvent.CLICK, callAdGa);
};
siteButton.removeEventListener(MouseEvent.CLICK, callFunnylishus);
_local4 = 0;
while (_local4 < ldr_stars.length) {
ldr_SGH.removeChild(ldr_stars[_local4].star);
_local4++;
};
ldr_stars.splice(0);
removeChild(ldr_SGH);
gotoAndStop("Intro1");
addEventListener(Event.ENTER_FRAME, checkMoveOn);
};
}
private function backToMenu2():void{
soundMod.soundClick();
goBut.removeEventListener(MouseEvent.CLICK, backToMenu);
if (stage.contains(armegaButton)){
armegaButton.removeEventListener(MouseEvent.CLICK, callArmegalo);
};
if (stage.contains(agButton_btn)){
agButton_btn.removeEventListener(MouseEvent.CLICK, callAdGa);
};
siteButton.removeEventListener(MouseEvent.CLICK, callFunnylishus);
subBut.removeEventListener(MouseEvent.CLICK, submitScore);
stage.removeEventListener(KeyboardEvent.KEY_DOWN, enterToSubmit);
soundMod.musicScene = "Normal";
soundMod.startMusic();
gotoAndStop("menu");
}
public function submitScore2():void{
if (theName.text != "Your Name"){
soundMod.soundClick();
userName = theName.text;
ScoreSubmit = new Submit_score(finalScore, userName, PathData.myXml.Path[GamePath].BoardName);
backToMenu2();
} else {
namerror.play();
};
}
public function callScoreboards(_arg1:MouseEvent):void{
var url:String;
var request:URLRequest;
var event = _arg1;
soundMod.soundClick();
url = "http://www.funnylishus.com/index.php?custom=scoreboard&board=RANDOM DEFENCE&level=CLOVER";
request = new URLRequest(url);
try {
navigateToURL(request, "_blank");
} catch(e:Error) {
};
}
private function cantAfford(){
DisplayError("We can't afford that right now!");
}
private function pauseGame2():void{
var _local1:uint;
soundMod.soundClick();
PauseBut.removeEventListener(MouseEvent.CLICK, pauseGame);
_local1 = 0;
while (_local1 < Missiles.length) {
Missiles[_local1].Missile.mis.stop();
_local1++;
};
DTGH.removeChild(PauseBut);
DTGH.addChild(StartBut);
StartBut.x = 0x0202;
StartBut.y = 425;
StartBut.addEventListener(MouseEvent.CLICK, reStartGame);
removeEventListener(Event.ENTER_FRAME, onEnterFrame);
addEventListener(Event.ENTER_FRAME, pauseManagement);
gamePaused = true;
}
private function dontSellTower(_arg1:MouseEvent):void{
closeAreYouSure();
}
private function backToMenu(_arg1:MouseEvent){
backToMenu2();
}
private function killTower(_arg1:Number){
var _local2:uint;
Towers[_arg1].Tower.detect.removeEventListener(MouseEvent.CLICK, TowerClicked);
TGH.removeChild(Towers[_arg1]);
_local2 = (_arg1 + 1);
while (_local2 < Towers.length) {
Towers[_local2].Thisis = (Towers[_local2].Thisis - 1);
_local2++;
};
Towers.splice(_arg1, 1);
if (SelectedTower > _arg1){
SelectedTower = (SelectedTower - 1);
};
}
private function rotateTower(_arg1:Object, _arg2:Object){
var _local3:Number;
var _local4:Number;
var _local5:Number;
_local3 = (_arg1.x - _arg2.x);
_local4 = (_arg1.y - _arg2.y);
_local5 = Math.atan2(_local4, _local3);
_arg1.Tower.tow.TowerWep.rotation = ((_local5 * 180) / Math.PI);
}
private function placeTower(_arg1:Number){
var _local2:Number;
addChild(TPC);
TPC.towersHolder.gotoAndStop(_arg1);
TPC.startDrag(true);
_local2 = TowerData.myXml.Tower[(_arg1 - 1)].Level[0].Range;
if (TowerData.myXml.Tower[(_arg1 - 1)].Func == "Weapon"){
showRange2(TPC, _local2);
};
TPC.addEventListener(MouseEvent.CLICK, dropTower);
stage.addEventListener(KeyboardEvent.KEY_DOWN, cancelTower);
addEventListener(Event.ENTER_FRAME, onEnterFrameTowerCheck);
}
private function TowerMenuClick(_arg1:MouseEvent){
var _local2:Number;
var _local3:*;
var _local4:Number;
var _local5:Number;
var _local6:String;
var _local7:Boolean;
var _local8:uint;
soundMod.soundClick();
if (Towers[SelectedTower].WaitingTimer < 1){
_local2 = Towers[SelectedTower].Level;
_local3 = Towers[SelectedTower].TowerType;
_local4 = TowerData.myXml.Tower[(Towers[SelectedTower].TowerType - 1)].Level[(_local2 + 1)].Cost;
_local5 = TowerData.myXml.Tower[(Towers[SelectedTower].TowerType - 1)].Level[(_local2 + 1)].TechReq;
_local6 = TowerData.myXml.Tower[(Towers[SelectedTower].TowerType - 1)].UGTechType;
_local7 = TowerSelectionOKorNot(_local6, _local5);
if (Cash < _local4){
_local7 = false;
cantAfford();
};
if (_local4 == -1){
_local7 = false;
DisplayError("There are no more upgrades for this tower");
};
if (_local7 == true){
Cash = (Cash - _local4);
Towers[SelectedTower].TowerWorth = (Towers[SelectedTower].TowerWorth + _local4);
_local8 = TowerData.myXml.Tower[(_local3 - 1)].Level[(_local2 + 1)].UpgradeTime;
towerWait(SelectedTower, _local8);
UpdateDisplay();
};
};
}
private function reStartGame(_arg1:MouseEvent){
reStartGame2();
}
private function seeTower(_arg1:MouseEvent){
var _local2:Number;
var _local3:Number;
var _local4:String;
var _local5:String;
_local2 = _arg1.currentTarget.name.slice(6, _arg1.currentTarget.name.length);
_local3 = TowerData.myXml.Tower[(_local2 - 1)].Cost;
_local4 = TowerData.myXml.Tower[(_local2 - 1)].Name;
_local5 = TowerData.myXml.Tower[(_local2 - 1)].Info;
ControlScreen.Screen.towername.text = _local4;
ControlScreen.Screen.towercost.text = _local3;
ControlScreen.Screen.ct.text = "Cost";
ControlScreen.Screen.Info.text = _local5;
}
private function DisplayError(_arg1:String){
soundMod.soundError();
DTGH.addChild(Err);
Err.x = 5;
Err.y = 435;
Err.ert.holder.ErrorMessage.text = _arg1;
Err.gotoAndPlay(2);
Err.ert.gotoAndPlay(2);
errorTimer.addEventListener(TimerEvent.TIMER, removeErrorDisplay);
errorTimer.reset();
errorTimer.start();
}
public function pathOver(_arg1:Event):void{
var _local2:uint;
_local2 = _arg1.currentTarget.name.slice(1, _arg1.currentTarget.name.length);
details.text = PathData.myXml.Path[_local2].Details;
_arg1.currentTarget.addEventListener(MouseEvent.ROLL_OUT, pathOut);
}
private function isInRange(_arg1:Number, _arg2:Number, _arg3:Number){
var _local4:Number;
_local4 = Math.sqrt(((_arg1 * _arg1) + (_arg2 * _arg2)));
if (_local4 < _arg3){
return (true);
};
return (false);
}
public function initGrats():void{
goBut.addEventListener(MouseEvent.CLICK, backToMenu);
armegaButton.addEventListener(MouseEvent.CLICK, callArmegalo, false, 0, true);
agButton_btn.addEventListener(MouseEvent.CLICK, callAdGa, false, 0, true);
siteButton.addEventListener(MouseEvent.CLICK, callFunnylishus);
subBut.addEventListener(MouseEvent.CLICK, submitScore);
stage.addEventListener(KeyboardEvent.KEY_DOWN, enterToSubmit);
details.text = String(int(finalScore));
if (endGameFlag2 == "Bad"){
messageHolder.message.text = "GAME OVER";
} else {
messageHolder.message.text = "END GAME";
};
}
private function SellTower(_arg1:MouseEvent){
soundMod.soundBuildingUp();
trace(SelectedTower);
Cash = (Cash + int((Towers[SelectedTower].TowerWorth * 0.75)));
UpdateDisplay();
killTower(SelectedTower);
closeAreYouSure();
CloseTowerMenu3(_arg1);
}
private function updateTowersAdvantages():void{
var _local1:uint;
var _local2:uint;
var _local3:int;
var _local4:String;
var _local5:*;
var _local6:Number;
var _local7:Number;
var _local8:Number;
_local1 = 0;
while (_local1 < Towers.length) {
if (Towers[_local1].Func == "Weapon"){
_local2 = Towers[_local1].TowerType;
_local3 = Towers[_local1].Level;
if (_local3 > -1){
_local4 = TowerData.myXml.Tower[(_local2 - 1)].UGTechType;
_local5 = getAdvantage(_local4);
_local6 = (TowerData.myXml.Tower[(_local2 - 1)].Level[_local3].Range * _local5);
_local7 = (TowerData.myXml.Tower[(_local2 - 1)].Level[_local3].Damage * _local5);
_local8 = (TowerData.myXml.Tower[(_local2 - 1)].Level[_local3].Splash * _local5);
Towers[_local1].Range = _local6;
Towers[_local1].Damage = _local7;
Towers[_local1].Splash = _local8;
};
};
_local1++;
};
if (this.contains(TowerMenu)){
UpdateTowerMenu();
};
}
private function calculateFinalScore():void{
var _local1:Number;
finalScore = Cash;
trace(("Final Score=" + finalScore));
_local1 = 0;
while (_local1 < Towers.length) {
finalScore = (finalScore + (Towers[_local1].TowerWorth * 0.75));
trace(("TowerWorth " + Towers[_local1].TowerWorth));
_local1++;
};
if (Lives > 0){
finalScore = (finalScore + (Lives * 1000));
};
}
private function damageCreep(_arg1:Object, _arg2:Object){
var _local3:Number;
var _local4:uint;
var _local5:*;
_local5 = (1 - ((1 - _arg1.Slow) / _arg2.SlowResist));
_arg2.CurrentHP = (_arg2.CurrentHP - _arg1.Damage);
_arg2.CurrentSP = (_arg2.CurrentSP * _local5);
if (_arg1.Splash > 0){
_local4 = 0;
while (_local4 < Creeps.length) {
if (((!((_local4 == _arg1.Target))) && (isOnBoard(Creeps[_local4])))){
_local3 = rangeIs((_arg2.x - Creeps[_local4].x), (_arg2.y - Creeps[_local4].y));
if (_local3 < _arg1.Splash){
Creeps[_local4].CurrentHP = (Creeps[_local4].CurrentHP - (-((_arg1.Damage * (_local3 / _arg1.Splash))) + _arg1.Damage));
if (_local5 != 1){
Creeps[_local4].CurrentSP = (Creeps[_local4].CurrentSP * (1 - ((1 - _local5) / 1.1)));
};
};
};
_local4++;
};
};
}
private function towerOn(_arg1:uint){
var _local2:*;
var _local3:Number;
var _local4:Number;
Towers[_arg1].removeChild(Towers[_arg1].CT);
Towers[_arg1].Tower.detect.buttonMode = true;
Towers[_arg1].Tower.detect.addEventListener(MouseEvent.CLICK, TowerClicked);
_local2 = TowerData.myXml.Tower[(Towers[_arg1].TowerType - 1)].TechType;
_local3 = getAdvantage(Towers[_arg1].UGTechType);
if (Towers[_arg1].Func == "Research"){
if (Towers[_arg1].Level == -1){
Towers[_arg1].Level = 1;
} else {
Towers[_arg1].Level = (Towers[_arg1].Level + 1);
};
if (_local2 == "Gun"){
GunTechLevel = Towers[_arg1].Level;
} else {
if (_local2 == "Bomb"){
BombTechLevel = Towers[_arg1].Level;
} else {
if (_local2 == "Slow"){
SlowTechLevel = Towers[_arg1].Level;
} else {
if (_local2 == "Mine"){
MineTechLevel = Towers[_arg1].Level;
} else {
if (_local2 == "Cash"){
CashTechLevel = Towers[_arg1].Level;
};
};
};
};
};
if (SelectedTower == _arg1){
UpdateResearchMenu();
};
updateTowersAdvantages();
} else {
if (Towers[_arg1].Func == "Weapon"){
Towers[_arg1].Level = (Towers[_arg1].Level + 1);
Towers[_arg1].Range = (TowerData.myXml.Tower[(Towers[_arg1].TowerType - 1)].Level[Towers[_arg1].Level].Range * _local3);
Towers[_arg1].Damage = (TowerData.myXml.Tower[(Towers[_arg1].TowerType - 1)].Level[Towers[_arg1].Level].Damage * _local3);
Towers[_arg1].FireSP = TowerData.myXml.Tower[(Towers[_arg1].TowerType - 1)].Level[Towers[_arg1].Level].FireSP;
Towers[_arg1].Slow = TowerData.myXml.Tower[(Towers[_arg1].TowerType - 1)].Level[Towers[_arg1].Level].Slow;
Towers[_arg1].Splash = (TowerData.myXml.Tower[(Towers[_arg1].TowerType - 1)].Level[Towers[_arg1].Level].Splash * _local3);
if (Towers[_arg1].Name == "Shock Tower"){
_local4 = (Towers[_arg1].Range / 70);
Towers[_arg1].Tower.tow.TowerWep.scaleX = _local4;
Towers[_arg1].Tower.tow.TowerWep.scaleY = _local4;
};
if (SelectedTower == _arg1){
UpdateTowerMenu();
};
};
};
}
private function pauseManagement(_arg1:Event):void{
stage.focus = this;
runExplosions();
runGame();
soundMod.processSoundCounters();
}
private function CloseResearchMenu2(){
if (this.contains(ResearchMenu)){
removeChild(ResearchMenu);
ResearchMenu.closebut.removeEventListener(MouseEvent.CLICK, CloseResearchMenu);
ResearchMenu.upgradebut.removeEventListener(MouseEvent.CLICK, ResearchMenuClick);
SelectedTower = -1;
};
}
private function quitGame(_arg1:MouseEvent):void{
dontQuitGame(_arg1);
endGameCondition = "Quit";
initEndGame();
}
private function ldr_onEnterFrame(_arg1:Event):void{
var _local2:uint;
_local2 = 0;
while (_local2 < 5) {
ldr_startStar();
_local2++;
};
ldr_processStars();
ldr_processRot();
ldr_frameCounter = (ldr_frameCounter + 1);
}
private function rotateObject2(_arg1:Object, _arg2:Number, _arg3:Number){
var _local4:Number;
var _local5:Number;
var _local6:Number;
_local4 = (_arg1.x - _arg2);
_local5 = (_arg1.y - _arg3);
_local6 = Math.atan2(_local5, _local4);
_arg1.rotation = ((_local6 * 180) / Math.PI);
}
private function pauseGame(_arg1:MouseEvent):void{
pauseGame2();
}
public function callInstructions(_arg1:MouseEvent):void{
var url:String;
var request:URLRequest;
var event = _arg1;
soundMod.soundClick();
url = "http://www.funnylishus.com/index.php?custom=randomstuff&subcust=start";
request = new URLRequest(url);
try {
navigateToURL(request, "_blank");
} catch(e:Error) {
};
}
private function removeCreepDisplay(_arg1:TimerEvent):void{
DBGH.removeChild(Crr);
CrrTimer.removeEventListener(TimerEvent.TIMER, removeCreepDisplay);
}
private function startGame2():void{
soundMod.soundClick();
StartBut.removeEventListener(MouseEvent.CLICK, startGame);
removeEventListener(Event.ENTER_FRAME, preStartManagement);
addEventListener(Event.ENTER_FRAME, onEnterFrame);
GAMEON = true;
DTGH.removeChild(StartBut);
DTGH.addChild(PauseBut);
PauseBut.x = 0x0202;
PauseBut.y = 425;
PauseBut.addEventListener(MouseEvent.CLICK, pauseGame);
}
private function rangeIs(_arg1:Number, _arg2:Number){
return (Math.sqrt(((_arg1 * _arg1) + (_arg2 * _arg2))));
}
private function globalInit():void{
initVars();
DTGH = new GameHolder();
addChild(DTGH);
soundMod = new soundModule();
DTGH.addChild(soundMod);
}
private function onEnterFrameTowerCheck(_arg1:Event):void{
var _local2:Boolean;
_local2 = checkTowerPos();
if (_local2 == true){
TPC.no.gotoAndStop(1);
} else {
TPC.no.gotoAndStop(2);
};
}
private function initVars():void{
Towers = new Array();
Creeps = new Array();
Missiles = new Array();
Explosions = new Array();
}
private function findMissileATarget(_arg1:Object){
var _local2:Boolean;
var _local3:Number;
_local2 = false;
_local3 = 0;
while (_local3 < Creeps.length) {
if (isInRange((Creeps[_local3].x - _arg1.x), (Creeps[_local3].y - _arg1.y), _arg1.Range)){
_arg1.Target = _local3;
_local2 = true;
break;
};
_local3++;
};
return (_local2);
}
private function startGame(_arg1:MouseEvent){
startGame2();
}
private function TowerSelectionOKorNot(_arg1, _arg2){
var _local3:Boolean;
_local3 = true;
if (_arg1 == "Gun"){
if (_arg2 > GunTechLevel){
_local3 = false;
if (GunTechLevel == -1){
DisplayError("We need a Gun Research Centre");
} else {
DisplayError("We need to upgrade our Gun Research Centre");
};
};
} else {
if (_arg1 == "Bomb"){
if (_arg2 > BombTechLevel){
_local3 = false;
if (BombTechLevel == -1){
DisplayError("We need an Explosives Research Centre");
} else {
DisplayError("We need to upgrade our Explosives Research Centre");
};
};
} else {
if (_arg1 == "Slow"){
if (_arg2 > SlowTechLevel){
_local3 = false;
if (SlowTechLevel == -1){
DisplayError("We need an Electrics Research Centre");
} else {
DisplayError("We need to upgrade our Electrics Research Centre");
};
};
} else {
if (_arg1 == "Multi"){
if ((((((_arg2 > SlowTechLevel)) || ((_arg2 > BombTechLevel)))) || ((_arg2 > GunTechLevel)))){
_local3 = false;
DisplayError(("We need all Research Centres at Tech Level " + _arg2.toString()));
};
} else {
if (_arg1 == "Mine"){
if (_arg2 > MineTechLevel){
_local3 = false;
if (MineTechLevel == -1){
DisplayError("We need a Mine Factory");
} else {
DisplayError("We need to upgrade our Mine Factory");
};
};
};
};
};
};
};
return (_local3);
}
private function explodeObject(_arg1:Object){
var _local2:ExplosionsControl;
if (endGameFlag < 97){
_local2 = new ExplosionsControl();
EGH.addChild(_local2);
Explosions.push(_local2);
_local2.x = _arg1.x;
_local2.y = _arg1.y;
};
}
private function UpdateDisplay():void{
Car.Message.text = ((("LIVES: " + Lives) + "\rCASH: ") + Cash);
}
private function checkTowerPos(){
var _local1:Number;
var _local2:Number;
var _local3:String;
var _local4:Number;
var _local5:*;
var _local6:Boolean;
var _local7:Number;
_local1 = TPC.towersHolder.currentFrame;
_local2 = TowerData.myXml.Tower[(_local1 - 1)].Size;
_local3 = TowerData.myXml.Tower[(_local1 - 1)].Name;
_local4 = (_local2 / 2);
_local5 = 0;
_local6 = true;
if ((((((((TPC.x < (0 + _local4))) || ((TPC.x > (550 - _local4))))) || ((TPC.y < (0 + _local4))))) || ((TPC.y > (400 - _local4))))){
_local6 = false;
};
_local7 = 0;
while (_local7 < Towers.length) {
_local5 = (_local4 + (Towers[_local7].Size / 2));
if (isInRange((TPC.x - Towers[_local7].x), (TPC.y - Towers[_local7].y), _local5)){
_local6 = false;
};
_local7++;
};
if (_local2 == 25){
if (PathSel.detect3.hitTestPoint(TPC.x, TPC.y, true)){
if (_local3 != "Mine"){
_local6 = false;
};
};
} else {
if (_local2 == 35){
if (PathSel.detect2.hitTestPoint(TPC.x, TPC.y, true)){
if (_local3 != "Mine"){
_local6 = false;
};
};
} else {
if (PathSel.detect1.hitTestPoint(TPC.x, TPC.y, true)){
if (_local3 != "Mine"){
_local6 = false;
};
};
};
};
return (_local6);
}
private function isOnBoard(_arg1:Object){
if ((((((((_arg1.x > boardMinX)) && ((_arg1.x < boardMaxX)))) && ((_arg1.y > boardMinY)))) && ((_arg1.y < boardMaxY)))){
return (true);
};
return (false);
}
private function killMultipleTowers(_arg1, _arg2:int, _arg3:Array):void{
var _local4:int;
killTower(_arg1);
_local4 = 0;
while (_local4 < towersKilledThisFrame.length) {
if (_arg1 < towersKilledThisFrame[_local4]){
towersKilledThisFrame[_local4] = (towersKilledThisFrame[_local4] - 1);
};
_local4++;
};
}
private function CloseResearchMenu(_arg1:MouseEvent){
soundMod.soundClick();
CloseResearchMenu2();
}
public function callAdGa(_arg1:MouseEvent):void{
var url:String;
var request:URLRequest;
var event = _arg1;
soundMod.soundClick();
url = "http://www.addictinggames.com";
request = new URLRequest(url);
try {
navigateToURL(request, "_blank");
} catch(e:Error) {
};
}
private function ResearchMenuClick(_arg1:MouseEvent){
var _local2:Number;
var _local3:Number;
var _local4:*;
var _local5:Boolean;
var _local6:uint;
soundMod.soundClick();
if (Towers[SelectedTower].WaitingTimer < 1){
_local2 = Towers[SelectedTower].Level;
_local3 = TowerData.myXml.Tower[(Towers[SelectedTower].TowerType - 1)].Level[(_local2 + 1)].Cost;
_local4 = Towers[SelectedTower].TowerType;
_local5 = true;
if (Cash < _local3){
_local5 = false;
cantAfford();
};
if (_local3 == -1){
_local5 = false;
DisplayError("There are no more upgrades for this tower");
};
if (_local5 == true){
Cash = (Cash - _local3);
_local6 = TowerData.myXml.Tower[(_local4 - 1)].Level[(_local2 + 1)].UpgradeTime;
towerWait(SelectedTower, _local6);
UpdateDisplay();
};
};
}
private function initYesNo():void{
removeYesNo();
soundMod.soundQuestion();
addChild(yn);
yn.x = ((550 / 2) - (yn.width / 2));
yn.y = ((400 / 2) - (yn.height / 2));
}
private function closeAreYouSure():void{
removeYesNo();
}
private function showRange2(_arg1:Object, _arg2:Number){
_arg1.addChild(rangeCirc);
rangeCirc.x = 0;
rangeCirc.y = 0;
rangeCirc.graphics.clear();
rangeCirc.graphics.lineStyle(1, 0);
rangeCirc.graphics.beginFill(0xFFFFFF, 0.15);
rangeCirc.graphics.drawCircle(0, 0, _arg2);
}
private function confirmSellTower(_arg1:MouseEvent):void{
initYesNo();
yn.yesbut.addEventListener(MouseEvent.CLICK, SellTower);
yn.nobut.addEventListener(MouseEvent.CLICK, dontSellTower);
}
}
}//package
Section 77
//EndGame (EndGame)
package {
import flash.display.*;
public dynamic class EndGame extends MovieClip {
public function EndGame(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package
Section 78
//EndGameGood (EndGameGood)
package {
import flash.display.*;
public dynamic class EndGameGood extends MovieClip {
}
}//package
Section 79
//ENDGAMESOUND (ENDGAMESOUND)
package {
import flash.media.*;
public dynamic class ENDGAMESOUND extends Sound {
}
}//package
Section 80
//ERROR (ERROR)
package {
import flash.media.*;
public dynamic class ERROR extends Sound {
}
}//package
Section 81
//ErrorReadout (ErrorReadout)
package {
import flash.display.*;
public dynamic class ErrorReadout extends MovieClip {
public var ert:MovieClip;
}
}//package
Section 82
//ExplosionsControl (ExplosionsControl)
package {
import flash.display.*;
public dynamic class ExplosionsControl extends MovieClip {
public var boom:MovieClip;
}
}//package
Section 83
//GameHolder (GameHolder)
package {
import flash.display.*;
public dynamic class GameHolder extends MovieClip {
}
}//package
Section 84
//GAMESTART (GAMESTART)
package {
import flash.media.*;
public dynamic class GAMESTART extends Sound {
}
}//package
Section 85
//HitPointsBar (HitPointsBar)
package {
import flash.display.*;
public dynamic class HitPointsBar extends MovieClip {
public var bar:MovieClip;
}
}//package
Section 86
//LASERINIT (LASERINIT)
package {
import flash.media.*;
public dynamic class LASERINIT extends Sound {
}
}//package
Section 87
//LASERLONG (LASERLONG)
package {
import flash.media.*;
public dynamic class LASERLONG extends Sound {
}
}//package
Section 88
//ldr_StarContainer (ldr_StarContainer)
package {
import flash.display.*;
public dynamic class ldr_StarContainer extends MovieClip {
}
}//package
Section 89
//LECTRICSHOCK (LECTRICSHOCK)
package {
import flash.media.*;
public dynamic class LECTRICSHOCK extends Sound {
}
}//package
Section 90
//LITTLEGUN (LITTLEGUN)
package {
import flash.media.*;
public dynamic class LITTLEGUN extends Sound {
}
}//package
Section 91
//Missile_controller (Missile_controller)
package {
import flash.display.*;
public class Missile_controller extends Sprite {
public var Missile:MissileHolderforControl;
public var ya:Number;// = 0
public var xt:Number;
public var xs:Number;// = 0
public var Guided:uint;
public var Friction:Number;
public var yt:Number;
public var meDead:Boolean;// = false
public var ys:Number;// = 0
public var Range:Number;
public var Slow:Number;
public var rs:Number;
public var MissileType:Number;
public var Thisis:Number;
public var Splash:Number;
public var Damage:Number;
public var Target:Number;// = -1
public var Accel:Number;
public var xa:Number;// = 0
public function Missile_controller(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:Number, _arg7:uint, _arg8:Number, _arg9:Number, _arg10:Number, _arg11:Number, _arg12:Number, _arg13:Number, _arg14:Number, _arg15:Number, _arg16:uint){
xs = 0;
ys = 0;
xa = 0;
ya = 0;
rs = int(((Math.random() * 15) - 7));
Target = -1;
Missile = new MissileHolderforControl();
meDead = false;
super();
addChild(Missile);
this.x = _arg1;
this.y = _arg2;
Missile.gotoAndStop(_arg7);
Range = _arg8;
Damage = _arg9;
Splash = _arg10;
Slow = _arg11;
xs = _arg3;
ys = _arg4;
Accel = _arg12;
Friction = _arg13;
Thisis = _arg14;
Target = _arg15;
Guided = _arg16;
xt = _arg5;
yt = _arg6;
}
public function killme():void{
this.parent.removeChild(this);
}
}
}//package
Section 92
//missile_definitions (missile_definitions)
package {
import flash.display.*;
public class missile_definitions extends Sprite {
public var myXml:XML;
public function missile_definitions(){
myXml = <Miss>
<Bomb>
<Guided>0</Guided>
<Level id="0">
<Accel>1</Accel>
<StartSpeed>10</StartSpeed>
<Friction>.1</Friction>
<Graphic>20</Graphic>
</Level>
<Level id="1">
<Accel>1</Accel>
<StartSpeed>10</StartSpeed>
<Friction>.1</Friction>
<Graphic>20</Graphic>
</Level>
<Level id="2">
<Accel>1.1</Accel>
<StartSpeed>10</StartSpeed>
<Friction>.1</Friction>
<Graphic>20</Graphic>
</Level>
<Level id="3">
<Accel>1.2</Accel>
<StartSpeed>10</StartSpeed>
<Friction>.1</Friction>
<Graphic>20</Graphic>
</Level>
<Level id="4">
<Accel>1.2</Accel>
<StartSpeed>10</StartSpeed>
<Friction>.1</Friction>
<Graphic>20</Graphic>
</Level>
<Level id="5">
<Accel>1.2</Accel>
<StartSpeed>10</StartSpeed>
<Friction>.1</Friction>
<Graphic>20</Graphic>
</Level>
</Bomb>
<Missile>
<Guided>1</Guided>
<Level id="0">
<Accel>1</Accel>
<StartSpeed>3</StartSpeed>
<Friction>.95</Friction>
<Graphic>1</Graphic>
</Level>
<Level id="1">
<Accel>1</Accel>
<StartSpeed>3</StartSpeed>
<Friction>.96</Friction>
<Graphic>1</Graphic>
</Level>
<Level id="2">
<Accel>1.1</Accel>
<StartSpeed>3</StartSpeed>
<Friction>.97</Friction>
<Graphic>2</Graphic>
</Level>
<Level id="3">
<Accel>1.2</Accel>
<StartSpeed>3</StartSpeed>
<Friction>.98</Friction>
<Graphic>2</Graphic>
</Level>
<Level id="4">
<Accel>1.3</Accel>
<StartSpeed>3</StartSpeed>
<Friction>.98</Friction>
<Graphic>2</Graphic>
</Level>
<Level id="5">
<Accel>1.4</Accel>
<StartSpeed>3</StartSpeed>
<Friction>.98</Friction>
<Graphic>2</Graphic>
</Level>
</Missile>
</Miss>
;
super();
}
}
}//package
Section 93
//MISSILE1 (MISSILE1)
package {
import flash.media.*;
public dynamic class MISSILE1 extends Sound {
}
}//package
Section 94
//MISSILE2 (MISSILE2)
package {
import flash.media.*;
public dynamic class MISSILE2 extends Sound {
}
}//package
Section 95
//MISSILE3 (MISSILE3)
package {
import flash.media.*;
public dynamic class MISSILE3 extends Sound {
}
}//package
Section 96
//MissileHolderforControl (MissileHolderforControl)
package {
import flash.display.*;
public dynamic class MissileHolderforControl extends MovieClip {
public var mis:MovieClip;
public function MissileHolderforControl(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package
Section 97
//MRSLOWDOWN (MRSLOWDOWN)
package {
import flash.media.*;
public dynamic class MRSLOWDOWN extends Sound {
}
}//package
Section 98
//Muteneer (Muteneer)
package {
import flash.display.*;
public dynamic class Muteneer extends MovieClip {
public var fx_mc:MovieClip;
public var music_but:SimpleButton;
public var fx_but:SimpleButton;
public var music_mc:MovieClip;
}
}//package
Section 99
//path_definitions (path_definitions)
package {
import flash.display.*;
public class path_definitions extends Sprite {
public var myXml:XML;
public function path_definitions(){
myXml = <Paths>
<maxPaths>5</maxPaths>
<Path id="0">
<Details>The Jungle : Clover - Easy</Details>
<BoardName>CLOVER</BoardName>
<BonusCash>500</BonusCash>
<Node id="0">
<Xpos>208</Xpos>
<Ypos>-21</Ypos>
</Node>
<Node id="1">
<Xpos>171</Xpos>
<Ypos>93</Ypos>
</Node>
<Node id="2">
<Xpos>58</Xpos>
<Ypos>130</Ypos>
</Node>
<Node id="3">
<Xpos>94</Xpos>
<Ypos>332</Ypos>
</Node>
<Node id="4">
<Xpos>234</Xpos>
<Ypos>237</Ypos>
</Node>
<Node id="5">
<Xpos>337</Xpos>
<Ypos>359</Ypos>
</Node>
<Node id="6">
<Xpos>454</Xpos>
<Ypos>364</Ypos>
</Node>
<Node id="7">
<Xpos>410</Xpos>
<Ypos>234</Ypos>
</Node>
<Node id="8">
<Xpos>494</Xpos>
<Ypos>158</Ypos>
</Node>
<Node id="9">
<Xpos>406</Xpos>
<Ypos>71</Ypos>
</Node>
<Node id="10">
<Xpos>325</Xpos>
<Ypos>83</Ypos>
</Node>
<Node id="11">
<Xpos>286</Xpos>
<Ypos>-29</Ypos>
</Node>
<Node id="12">
<Xpos>-1</Xpos>
<Ypos>-1</Ypos>
</Node>
</Path>
<Path id="1">
<Details>The Plains : Square Wave - Easy</Details>
<BoardName>SQUARE WAVE</BoardName>
<BonusCash>100</BonusCash>
<Node id="0">
<Xpos>-25</Xpos>
<Ypos>312</Ypos>
</Node>
<Node id="1">
<Xpos>172</Xpos>
<Ypos>312</Ypos>
</Node>
<Node id="2">
<Xpos>172</Xpos>
<Ypos>196</Ypos>
</Node>
<Node id="3">
<Xpos>96</Xpos>
<Ypos>196</Ypos>
</Node>
<Node id="4">
<Xpos>82</Xpos>
<Ypos>62</Ypos>
</Node>
<Node id="5">
<Xpos>307</Xpos>
<Ypos>74</Ypos>
</Node>
<Node id="6">
<Xpos>280</Xpos>
<Ypos>307</Ypos>
</Node>
<Node id="7">
<Xpos>448</Xpos>
<Ypos>256</Ypos>
</Node>
<Node id="8">
<Xpos>438</Xpos>
<Ypos>100</Ypos>
</Node>
<Node id="9">
<Xpos>585</Xpos>
<Ypos>100</Ypos>
</Node>
<Node id="10">
<Xpos>-1</Xpos>
<Ypos>-1</Ypos>
</Node>
</Path>
<Path id="2">
<Details>The Jungle : Meander - Easy</Details>
<BoardName>MEANDER</BoardName>
<BonusCash>100</BonusCash>
<Node id="0">
<Xpos>-66</Xpos>
<Ypos>100</Ypos>
</Node>
<Node id="1">
<Xpos>188</Xpos>
<Ypos>46</Ypos>
</Node>
<Node id="2">
<Xpos>254</Xpos>
<Ypos>215</Ypos>
</Node>
<Node id="3">
<Xpos>82</Xpos>
<Ypos>200</Ypos>
</Node>
<Node id="4">
<Xpos>72</Xpos>
<Ypos>359</Ypos>
</Node>
<Node id="5">
<Xpos>401</Xpos>
<Ypos>372</Ypos>
</Node>
<Node id="6">
<Xpos>497</Xpos>
<Ypos>214</Ypos>
</Node>
<Node id="7">
<Xpos>326</Xpos>
<Ypos>83</Ypos>
</Node>
<Node id="8">
<Xpos>592</Xpos>
<Ypos>39</Ypos>
</Node>
<Node id="9">
<Xpos>-1</Xpos>
<Ypos>-1</Ypos>
</Node>
</Path>
<Path id="3">
<Details>The Plains : Swirlishus - Easy</Details>
<BoardName>SWIRLISHUS</BoardName>
<BonusCash>100</BonusCash>
<Node id="0">
<Xpos>574</Xpos>
<Ypos>85</Ypos>
</Node>
<Node id="1">
<Xpos>353</Xpos>
<Ypos>45</Ypos>
</Node>
<Node id="2">
<Xpos>162</Xpos>
<Ypos>356</Ypos>
</Node>
<Node id="3">
<Xpos>355</Xpos>
<Ypos>383</Ypos>
</Node>
<Node id="4">
<Xpos>470</Xpos>
<Ypos>180</Ypos>
</Node>
<Node id="5">
<Xpos>72</Xpos>
<Ypos>38</Ypos>
</Node>
<Node id="6">
<Xpos>90</Xpos>
<Ypos>455</Ypos>
</Node>
<Node id="7">
<Xpos>-1</Xpos>
<Ypos>-1</Ypos>
</Node>
</Path>
<Path id="4">
<Details>The Desert : Platform Zero - Medium</Details>
<BoardName>PLATFORM ZERO</BoardName>
<BonusCash>0</BonusCash>
<Node id="0">
<Xpos>488</Xpos>
<Ypos>469</Ypos>
</Node>
<Node id="1">
<Xpos>354</Xpos>
<Ypos>238</Ypos>
</Node>
<Node id="2">
<Xpos>509</Xpos>
<Ypos>127</Ypos>
</Node>
<Node id="3">
<Xpos>56</Xpos>
<Ypos>50</Ypos>
</Node>
<Node id="4">
<Xpos>233</Xpos>
<Ypos>247</Ypos>
</Node>
<Node id="5">
<Xpos>80</Xpos>
<Ypos>463</Ypos>
</Node>
<Node id="6">
<Xpos>-1</Xpos>
<Ypos>-1</Ypos>
</Node>
</Path>
<Path id="5">
<Details>The Desert : Zig Zaggion - Hard</Details>
<BoardName>ZIG ZAGGION</BoardName>
<BonusCash>0</BonusCash>
<Node id="0">
<Xpos>-45</Xpos>
<Ypos>95</Ypos>
</Node>
<Node id="1">
<Xpos>287</Xpos>
<Ypos>95</Ypos>
</Node>
<Node id="2">
<Xpos>187</Xpos>
<Ypos>319</Ypos>
</Node>
<Node id="3">
<Xpos>599</Xpos>
<Ypos>300</Ypos>
</Node>
<Node id="4">
<Xpos>-1</Xpos>
<Ypos>-1</Ypos>
</Node>
</Path>
<Path id="6">
<Details>Space : Mmmmmm - Hard</Details>
<BoardName>MMMMMM</BoardName>
<BonusCash>0</BonusCash>
<Node id="0">
<Xpos>-50</Xpos>
<Ypos>239</Ypos>
</Node>
<Node id="1">
<Xpos>119</Xpos>
<Ypos>116</Ypos>
</Node>
<Node id="2">
<Xpos>280</Xpos>
<Ypos>349</Ypos>
</Node>
<Node id="3">
<Xpos>433</Xpos>
<Ypos>105</Ypos>
</Node>
<Node id="4">
<Xpos>597</Xpos>
<Ypos>225</Ypos>
</Node>
<Node id="5">
<Xpos>-1</Xpos>
<Ypos>-1</Ypos>
</Node>
</Path>
<Path id="7">
<Details>The Sky : G Spot - Medium</Details>
<BoardName>G SPOT</BoardName>
<BonusCash>0</BonusCash>
<Node id="0">
<Xpos>416</Xpos>
<Ypos>571</Ypos>
</Node>
<Node id="1">
<Xpos>455</Xpos>
<Ypos>320</Ypos>
</Node>
<Node id="2">
<Xpos>120</Xpos>
<Ypos>335</Ypos>
</Node>
<Node id="3">
<Xpos>229</Xpos>
<Ypos>66</Ypos>
</Node>
<Node id="4">
<Xpos>627</Xpos>
<Ypos>96</Ypos>
</Node>
<Node id="5">
<Xpos>-1</Xpos>
<Ypos>-1</Ypos>
</Node>
</Path>
<Path id="8">
<Details>Space : Fly By - Hard</Details>
<BoardName>FLY BY</BoardName>
<BonusCash>0</BonusCash>
<Node id="0">
<Xpos>194</Xpos>
<Ypos>-50</Ypos>
</Node>
<Node id="1">
<Xpos>180</Xpos>
<Ypos>80</Ypos>
</Node>
<Node id="2">
<Xpos>73</Xpos>
<Ypos>195</Ypos>
</Node>
<Node id="3">
<Xpos>209</Xpos>
<Ypos>367</Ypos>
</Node>
<Node id="4">
<Xpos>407</Xpos>
<Ypos>333</Ypos>
</Node>
<Node id="5">
<Xpos>425</Xpos>
<Ypos>174</Ypos>
</Node>
<Node id="6">
<Xpos>601</Xpos>
<Ypos>145</Ypos>
</Node>
<Node id="7">
<Xpos>-1</Xpos>
<Ypos>-1</Ypos>
</Node>
</Path>
<Path id="9">
<Details>The Sky : Merry Go Round - Medium</Details>
<BoardName>MERRY GO ROUND</BoardName>
<BonusCash>0</BonusCash>
<Node id="0">
<Xpos>110</Xpos>
<Ypos>537</Ypos>
</Node>
<Node id="1">
<Xpos>185</Xpos>
<Ypos>372</Ypos>
</Node>
<Node id="2">
<Xpos>77</Xpos>
<Ypos>245</Ypos>
</Node>
<Node id="3">
<Xpos>119</Xpos>
<Ypos>65</Ypos>
</Node>
<Node id="4">
<Xpos>438</Xpos>
<Ypos>65</Ypos>
</Node>
<Node id="5">
<Xpos>464</Xpos>
<Ypos>318</Ypos>
</Node>
<Node id="6">
<Xpos>622</Xpos>
<Ypos>310</Ypos>
</Node>
<Node id="7">
<Xpos>-1</Xpos>
<Ypos>-1</Ypos>
</Node>
</Path>
</Paths>
;
super();
}
}
}//package
Section 100
//PathButton (PathButton)
package {
import flash.display.*;
public dynamic class PathButton extends SimpleButton {
}
}//package
Section 101
//PathSelector (PathSelector)
package {
import flash.display.*;
public dynamic class PathSelector extends MovieClip {
public var detect1:MovieClip;
public var detect2:MovieClip;
public var detect3:MovieClip;
public function PathSelector(){
addFrameScript(0, frame1, 1, frame2);
}
function frame1(){
stop();
}
function frame2(){
stop();
}
}
}//package
Section 102
//PauseButton (PauseButton)
package {
import flash.display.*;
public dynamic class PauseButton extends SimpleButton {
}
}//package
Section 103
//QUESTION (QUESTION)
package {
import flash.media.*;
public dynamic class QUESTION extends Sound {
}
}//package
Section 104
//ResearchInfo (ResearchInfo)
package {
import flash.display.*;
import flash.text.*;
public dynamic class ResearchInfo extends MovieClip {
public var towername:TextField;
public var towerlevel:TextField;
public var closebut:SimpleButton;
public var upgradebut:SimpleButton;
public var upgradecost:TextField;
}
}//package
Section 105
//Smash (Smash)
package {
import flash.media.*;
public dynamic class Smash extends Sound {
}
}//package
Section 106
//soundModule (soundModule)
package {
import com.hydrotik.utils.*;
import flash.events.*;
import flash.display.*;
import flash.net.*;
public class soundModule extends MovieClip {
private var laserCount:Number;// = 0
private var boomCount:Number;// = 0
private var medFxVol:Number;// = 0.5
private var topFxVol:Number;// = 1
private var laserInitCount:Number;// = 0
public var so:SharedObject;
public var musicScene:String;// = "Normal"
public var musicState:String;
public var muteButtons:Muteneer;
private var missileCount:Number;// = 0
private var fxVol:Number;
private var shockCount:Number;// = 0
private var slowDownCount:Number;// = 0
private var littleGunCount:Number;// = 0
private var bigGunCount:Number;// = 0
public var fxState:String;
public function soundModule():void{
muteButtons = new Muteneer();
so = SharedObject.getLocal("rdmutesettings");
missileCount = 0;
littleGunCount = 0;
bigGunCount = 0;
boomCount = 0;
slowDownCount = 0;
shockCount = 0;
laserCount = 0;
laserInitCount = 0;
topFxVol = 1;
medFxVol = 0.5;
fxVol = topFxVol;
musicScene = "Normal";
super();
trace("Mute Module PROPER on");
initSounds();
if (so.data.fxState == undefined){
so.data.fxState = "HALFON";
so.data.fxVol = topFxVol;
};
if (so.data.musicState == undefined){
so.data.musicState = "TUNE1";
};
fxState = so.data.fxState;
musicState = so.data.musicState;
fxVol = so.data.fxVol;
trace(musicState);
addChild(muteButtons);
muteButtons.x = 548;
muteButtons.y = 0;
muteButtons.fx_mc.gotoAndStop(fxState);
muteButtons.music_mc.gotoAndStop(musicState);
muteButtons.fx_but.addEventListener(MouseEvent.CLICK, switchFx);
muteButtons.music_but.addEventListener(MouseEvent.CLICK, switchMusic);
startMusic();
}
public function soundLaser():void{
if (laserCount < 0){
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
if (laserCount < -1){
SoundManager.getInstance().play("LASERLONG", 9999, fxVol);
};
};
laserCount = 1;
};
}
public function startMusic():void{
if (musicState != "ALLOFF"){
SoundManager.getInstance().startSequencer(musicState);
};
}
public function soundMissile():void{
var _local1:Number;
if (missileCount < 0){
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
_local1 = (int((Math.random() * 3)) + 1);
SoundManager.getInstance().play(("MISSILE" + _local1), 1, fxVol);
};
missileCount = 1;
};
}
public function soundLittleGun():void{
if (littleGunCount < 0){
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("LITTLEGUN", 1, fxVol);
};
littleGunCount = 1;
};
}
public function soundQuestion():void{
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("QUESTION", 1, fxVol);
};
}
public function soundBigGun():void{
if (bigGunCount < 0){
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("BIGGUN", 1, fxVol);
};
bigGunCount = 1;
};
}
public function soundLaserInit():void{
if (laserInitCount < 0){
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("LASERINIT", 1, fxVol);
};
laserInitCount = 1;
};
}
public function switchFx(_arg1:Event){
if (fxState == "ALLON"){
fxState = "HALFON";
fxVol = medFxVol;
} else {
if (fxState == "HALFON"){
fxState = "ALLOFF";
} else {
if (fxState == "ALLOFF"){
fxVol = topFxVol;
fxState = "ALLON";
};
};
};
muteButtons.fx_mc.gotoAndStop(fxState);
so.data.fxState = fxState;
so.data.fxVol = fxVol;
so.flush();
}
public function soundEndGameGood():void{
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("CROWD", 1, fxVol);
};
}
public function soundApresExplo():void{
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("APRESEXPLO1", 1, fxVol);
};
}
public function stopMusic():void{
if (musicState != "ALLOFF"){
SoundManager.getInstance().stop(musicState);
};
}
public function soundError():void{
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("ERROR", 1, fxVol);
};
}
public function switchMusic(_arg1:Event){
if (musicScene == "Normal"){
stopMusic();
};
if (musicState == "TUNE1"){
musicState = "TUNE2";
} else {
if (musicState == "TUNE2"){
musicState = "ALLOFF";
} else {
if (musicState == "ALLOFF"){
musicState = "TUNE1";
};
};
};
if (musicScene == "Normal"){
startMusic();
};
muteButtons.music_mc.gotoAndStop(musicState);
so.data.musicState = musicState;
so.flush();
}
private function initSounds(){
SoundManager.getInstance().addItem(new BIGGUN());
SoundManager.getInstance().addItem(new BUILDINGDOWNTHUMP());
SoundManager.getInstance().addItem(new BOOM1());
SoundManager.getInstance().addItem(new BOOM2());
SoundManager.getInstance().addItem(new BOOM3());
SoundManager.getInstance().addItem(new BOOM4());
SoundManager.getInstance().addItem(new BOOM5());
SoundManager.getInstance().addItem(new BOOM6());
SoundManager.getInstance().addItem(new LITTLEGUN());
SoundManager.getInstance().addItem(new MISSILE1());
SoundManager.getInstance().addItem(new MISSILE2());
SoundManager.getInstance().addItem(new MISSILE3());
SoundManager.getInstance().addItem(new MRSLOWDOWN());
SoundManager.getInstance().addItem(new LECTRICSHOCK());
SoundManager.getInstance().addItem(new TUNE1());
SoundManager.getInstance().addItem(new TUNE2());
SoundManager.getInstance().addItem(new LASERINIT());
SoundManager.getInstance().addItem(new LASERLONG());
SoundManager.getInstance().addItem(new QUESTION());
SoundManager.getInstance().addItem(new BUILDINGUP());
SoundManager.getInstance().addItem(new CLICK());
SoundManager.getInstance().addItem(new ERROR());
SoundManager.getInstance().addItem(new ENDGAMESOUND());
SoundManager.getInstance().addItem(new CROWD());
SoundManager.getInstance().addItem(new APRESEXPLO1());
SoundManager.getInstance().addItem(new GAMESTART());
SoundManager.getInstance().play("LASERLONG", 1, 1);
SoundManager.getInstance().stop("LASERLONG");
}
public function soundGameStart():void{
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("GAMESTART", 1, fxVol);
};
}
public function buildingThump():void{
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("BUILDINGDOWNTHUMP", 1, fxVol);
};
}
public function soundBoom():void{
var _local1:Number;
if (boomCount < 0){
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
_local1 = (int((Math.random() * 6)) + 1);
SoundManager.getInstance().play(("BOOM" + _local1), 1, fxVol);
};
boomCount = 1;
};
}
public function soundSlowDown():void{
if (slowDownCount < 0){
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("MRSLOWDOWN", 1, fxVol);
};
slowDownCount = 1;
};
}
public function processSoundCounters():void{
if (littleGunCount > -1){
littleGunCount = (littleGunCount - 1);
};
if (bigGunCount > -1){
bigGunCount = (bigGunCount - 1);
};
if (missileCount > -1){
missileCount = (missileCount - 1);
};
if (slowDownCount > -1){
slowDownCount = (slowDownCount - 1);
};
if (shockCount > -1){
shockCount = (shockCount - 1);
};
if (boomCount > -4){
boomCount = (boomCount - 1);
} else {
if (boomCount == -4){
soundApresExplo();
boomCount = (boomCount - 1);
};
};
if (laserCount > -2){
laserCount = (laserCount - 1);
if (laserCount == -2){
SoundManager.getInstance().stop("LASERLONG");
};
};
if (laserInitCount > -1){
laserInitCount = (laserInitCount - 1);
};
}
public function killme():void{
this.parent.removeChild(this);
}
public function soundClick():void{
}
public function soundShock():void{
if (shockCount < 0){
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("LECTRICSHOCK", 1, fxVol);
};
shockCount = 1;
};
}
public function soundEndGameBad():void{
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("ENDGAMESOUND", 1, fxVol);
};
}
public function soundBuildingUp():void{
if ((((fxState == "ALLON")) || ((fxState == "HALFON")))){
SoundManager.getInstance().play("BUILDINGUP", 1, fxVol);
};
}
}
}//package
Section 107
//StartButton (StartButton)
package {
import flash.display.*;
public dynamic class StartButton extends SimpleButton {
}
}//package
Section 108
//sting_controller (sting_controller)
package {
import flash.events.*;
import flash.display.*;
import flash.net.*;
public class sting_controller extends MovieClip {
public var clip:MovieClip;
private var aas:Array;
private var thisMode:Array;
private var yys:Array;
private var mose:Number;// = 1
private var xxs:Array;
private var qwik:Number;// = 10
public function sting_controller(){
aas = new Array();
xxs = new Array();
yys = new Array();
mose = 1;
qwik = 10;
thisMode = new Array();
super();
addEventListener(Event.ENTER_FRAME, onEnterFrame, false, 0, true);
clip.armegaButton.addEventListener(MouseEvent.CLICK, callArmegalo, false, 0, true);
play();
aas.push(clip.a1);
aas.push(clip.a2);
aas.push(clip.a3);
aas.forEach(setEmUp);
}
public function callArmegalo(_arg1:MouseEvent):void{
var url:String;
var request:URLRequest;
var event = _arg1;
url = "http://www.armegalo.com";
trace(url);
request = new URLRequest(url);
try {
navigateToURL(request, "_blank");
} catch(e:Error) {
};
}
public function onEnterFrame(_arg1:Event):void{
if ((Math.random() * 5) < 1){
mose = 0;
qwik = 2;
} else {
mose = 1;
qwik = 10;
};
aas.forEach(doMaThang);
}
private function doMaThang(_arg1, _arg2:int, _arg3:Array):void{
if (thisMode[_arg2] == 0){
if ((Math.random() * 4) < 2){
thisMode[_arg2] = int((Math.random() * 4));
};
_arg1.x = ((xxs[_arg2] + (Math.random() * 12)) - 6);
_arg1.y = ((yys[_arg2] + (Math.random() * 12)) - 6);
if (mose == 1){
this.scaleY = ((Math.random() / 20) + 0.975);
this.scaleY = ((Math.random() / 20) + 0.975);
} else {
this.scaleX = ((Math.random() / 10) + 0.9);
this.scaleY = ((Math.random() / 10) + 0.9);
};
} else {
if (thisMode[_arg2] == 1){
this.scaleX = (this.scaleX - (this.scaleX / 100));
this.scaleY = (this.scaleY + (this.scaleY / 100));
} else {
if (thisMode[_arg2] == 2){
this.scaleX = (this.scaleX + (this.scaleX / 100));
this.scaleY = (this.scaleY + (this.scaleY / 100));
} else {
if (thisMode[_arg2] == 3){
this.scaleX = (this.scaleX + (this.scaleX / 100));
this.scaleY = (this.scaleY - (this.scaleY / 100));
};
};
};
if ((Math.random() * qwik) < 1.5){
thisMode[_arg2] = 0;
};
};
if (this.scaleX > 1.2){
this.scaleX = 1.2;
};
if (this.scaleY > 1.2){
this.scaleY = 1.2;
};
}
private function setEmUp(_arg1, _arg2:int, _arg3:Array):void{
xxs[_arg2] = _arg1.x;
yys[_arg2] = _arg1.y;
thisMode[_arg2] = 0;
}
}
}//package
Section 109
//Submit_score (Submit_score)
package {
import flash.display.*;
import flash.net.*;
public class Submit_score extends MovieClip {
public var myName:String;
public var score:int;// = 0
public function Submit_score(_arg1:int, _arg2:String, _arg3:String){
var n:Number;
var a:Number;
var score1:int;
var section_length:int;
var uniquea1:int;
var uniqueb1:int;
var uniquea2:String;
var sl:Number;
var more:Number;
var uniqueb2:String;
var level1:String;
var ll:Number;
var keyb1:String;
var board1:String;
var score2:String;
var keya1:uint;
var keya2:String;
var mypassword:String;
var stringy:String;
var stringy2:Array;
var stringy3:Array;
var url:String;
var request:URLRequest;
var variables:URLVariables;
var times:Number;
var s = _arg1;
var m = _arg2;
var l = _arg3;
score = 0;
super();
score1 = s;
section_length = 10;
uniquea1 = int((Math.random() * 9999));
uniqueb1 = (47652 - uniquea1);
uniquea2 = uniquea1.toString(10);
sl = uniquea2.length;
more = (5 - sl);
n = 0;
while (n < more) {
uniquea2 = ("0" + uniquea2);
n = (n + 1);
};
uniqueb2 = uniqueb1.toString(10);
sl = uniqueb2.length;
more = (5 - sl);
n = 0;
while (n < more) {
uniqueb2 = ("0" + uniqueb2);
n = (n + 1);
};
level1 = l;
level1 = level1.toUpperCase();
ll = level1.length;
more = ((section_length * 2) - ll);
n = 0;
while (n < more) {
level1 = (" " + level1);
n = (n + 1);
};
keyb1 = level1.toLowerCase();
board1 = "RANDOM DEFENCE";
board1 = board1.toUpperCase();
ll = board1.length;
more = ((section_length * 2) - ll);
n = 0;
while (n < more) {
board1 = (" " + board1);
n = (n + 1);
};
score2 = score1.toString(10);
trace("ok1");
sl = score2.length;
more = (section_length - sl);
trace("ok2");
n = 0;
while (n < more) {
score2 = ("0" + score2);
n = (n + 1);
};
trace("ok3");
keya1 = (935672921 - score1);
keya2 = keya1.toString(10);
sl = keya2.length;
more = (section_length - sl);
trace("ok4");
n = 0;
while (n < more) {
keya2 = ("0" + keya2);
n = (n + 1);
};
trace("ok5");
mypassword = "fuckly";
stringy = ((((((uniqueb2 + level1) + keya2) + score2) + board1) + keyb1) + uniquea2);
sl = stringy.length;
trace("ok6");
stringy2 = new Array();
trace("ok7");
n = 0;
while (n < sl) {
trace("ok8");
times = mypassword.charCodeAt((n % mypassword.length));
trace("ok8.5");
stringy2[n] = (stringy.charCodeAt(n) + (((n + 3) * times) % 100));
n = (n + 1);
};
trace("ok7");
stringy3 = new Array();
a = 0;
trace("ok675");
n = 0;
while (n < section_length) {
stringy3[a] = stringy2[n];
a = (a + 1);
stringy3[a] = stringy2[(n + 10)];
a = (a + 1);
stringy3[a] = stringy2[(n + 20)];
a = (a + 1);
stringy3[a] = stringy2[(n + 30)];
a = (a + 1);
stringy3[a] = stringy2[(n + 40)];
a = (a + 1);
stringy3[a] = stringy2[(n + 50)];
a = (a + 1);
stringy3[a] = stringy2[(n + 60)];
a = (a + 1);
stringy3[a] = stringy2[(n + 70)];
a = (a + 1);
stringy3[a] = stringy2[(n + 80)];
a = (a + 1);
n = (n + 1);
};
trace("ok9");
url = "http://www.funnylishus.com/index.php?custom=scoreboard";
request = new URLRequest(url);
variables = new URLVariables();
variables.smyname = m;
variables.sscore = stringy3.toString();
request.data = variables;
request.method = URLRequestMethod.POST;
try {
navigateToURL(request, "_blank");
} catch(e:Error) {
trace("Error occurred!");
};
}
public function killme():void{
this.parent.removeChild(this);
}
}
}//package
Section 110
//Symbol136 (Symbol136)
package {
public dynamic class Symbol136 extends bubblishus {
}
}//package
Section 111
//Symbol137 (Symbol137)
package {
public dynamic class Symbol137 extends bubblishus {
}
}//package
Section 112
//Symbol138 (Symbol138)
package {
public dynamic class Symbol138 extends bubblishus {
}
}//package
Section 113
//Symbol139 (Symbol139)
package {
public dynamic class Symbol139 extends bubblishus {
}
}//package
Section 114
//Symbol140 (Symbol140)
package {
public dynamic class Symbol140 extends bubblishus {
}
}//package
Section 115
//Symbol141 (Symbol141)
package {
public dynamic class Symbol141 extends bubblishus {
}
}//package
Section 116
//Symbol142 (Symbol142)
package {
public dynamic class Symbol142 extends bubblishus {
}
}//package
Section 117
//Symbol143 (Symbol143)
package {
public dynamic class Symbol143 extends bubblishus {
}
}//package
Section 118
//Symbol144 (Symbol144)
package {
public dynamic class Symbol144 extends bubblishus {
}
}//package
Section 119
//Symbol145 (Symbol145)
package {
public dynamic class Symbol145 extends bubblishus {
}
}//package
Section 120
//Symbol146 (Symbol146)
package {
public dynamic class Symbol146 extends bubblishus {
}
}//package
Section 121
//Tower_controller (Tower_controller)
package {
import flash.events.*;
import flash.filters.*;
import flash.display.*;
public class Tower_controller extends Sprite {
public var TechType:String;
public var Range_lev:Number;// = 0
public var FireSP_lev:Number;// = 0
public var TowerWorth:uint;// = 0
public var Range:Number;
private var filtersArray:Array;
public var FireSP:Number;
public var rotDir:Number;
public var FireCount_lev:Number;// = 0
public var Slow:Number;
public var WaitingTimer:uint;
public var Size:Number;// = 0
public var Level:Number;// = -1
public var fuse:uint;// = 0
public var FireCount:Number;// = 2
public var Damage_lev:Number;// = 0
public var WaitingFrom:uint;
public var myShape:Shape;
public var Splash:Number;
public var Thisis:Number;
public var Damage:Number;
public var UGTechType:String;
public var glow:GlowFilter;
public var Target:Number;// = -1
public var CT:ClockTimer;
public var Name:String;
public var TowerType:Number;
public var Splash_lev:Number;// = 0
public var framecount:uint;// = 0
public var Tower:TowersHolderforControl;
public var Func:String;
public var Slow_lev:Number;// = 0
public function Tower_controller(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:Number, _arg7:Number, _arg8:Number, _arg9:Number, _arg10:Number, _arg11:String, _arg12:String, _arg13:String, _arg14:String, _arg15:uint){
Range_lev = 0;
Damage_lev = 0;
FireSP_lev = 0;
FireCount = 2;
FireCount_lev = 0;
Splash_lev = 0;
Slow_lev = 0;
Level = -1;
Size = 0;
Target = -1;
Tower = new TowersHolderforControl();
CT = new ClockTimer();
myShape = new Shape();
TowerWorth = 0;
rotDir = int(((Math.random() * 7) - 3));
framecount = 0;
fuse = 0;
glow = new GlowFilter();
filtersArray = new Array(glow);
super();
glow.color = 39202;
glow.alpha = 1;
glow.blurX = 5;
glow.blurY = 5;
glow.quality = BitmapFilterQuality.MEDIUM;
addChild(Tower);
this.x = _arg1;
this.y = _arg2;
Tower.gotoAndStop(_arg3);
TowerType = _arg3;
Range = _arg4;
Damage = _arg5;
FireSP = _arg6;
FireCount = FireSP;
Splash = _arg7;
Slow = _arg8;
Thisis = _arg9;
Size = _arg10;
Func = _arg11;
TechType = _arg12;
UGTechType = _arg13;
Name = _arg14;
TowerWorth = _arg15;
if (Name == "Laser MegaTower"){
addEventListener(Event.ENTER_FRAME, addChildShapeAfterOneFrame);
};
}
public function deleteLaserAfterOneFrame(_arg1:Event):void{
framecount = (framecount + 1);
if (framecount > 1){
myShape.graphics.clear();
removeEventListener(Event.ENTER_FRAME, deleteLaserAfterOneFrame);
};
}
public function addChildShapeAfterOneFrame(_arg1:Event):void{
framecount = (framecount + 1);
trace(framecount);
if (framecount > 1){
Tower.tow.emptymc.addChild(myShape);
myShape.filters = filtersArray;
removeEventListener(Event.ENTER_FRAME, addChildShapeAfterOneFrame);
};
}
}
}//package
Section 122
//tower_definitions (tower_definitions)
package {
import flash.display.*;
public class tower_definitions extends Sprite {
public var myXml:XML;
public function tower_definitions(){
myXml = <Towers>
<DefaultInfo>Mouse over a tower to see info</DefaultInfo>
<Tower id="0">
<Cost>30</Cost>
<Name>Gun Tower</Name>
<Size>25</Size>
<Func>Weapon</Func>
<TechType>Gun</TechType>
<UGTechType>Gun</UGTechType>
<Info>Basic Weapons Tower. Quick to react - good for picking off th stragglers.</Info>
<Level id="0">
<Cost>0</Cost>
<Range>80</Range>
<Damage>2</Damage>
<FireSP>8</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>5</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="1">
<Cost>30</Cost>
<Range>85</Range>
<Damage>4</Damage>
<FireSP>7</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>60</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="2">
<Cost>40</Cost>
<Range>90</Range>
<Damage>6</Damage>
<FireSP>6</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>70</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="3">
<Cost>50</Cost>
<Range>95</Range>
<Damage>8</Damage>
<FireSP>5</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>70</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="4">
<Cost>70</Cost>
<Range>100</Range>
<Damage>10</Damage>
<FireSP>4</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>70</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="5">
<Cost>100</Cost>
<Range>105</Range>
<Damage>12</Damage>
<FireSP>3</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>70</UpgradeTime>
<TechReq>2</TechReq>
</Level>
<Level id="6">
<Cost>-1</Cost>
</Level>
</Tower>
<Tower id="1">
<Cost>60</Cost>
<Name>Grenade Tower</Name>
<Size>25</Size>
<Func>Weapon</Func>
<TechType>Bomb</TechType>
<UGTechType>Bomb</UGTechType>
<Info>Throws Grenades. Not very good at predicting creep movement. Good splash radius though.</Info>
<Level id="0">
<Cost>0</Cost>
<Range>80</Range>
<Damage>5</Damage>
<FireSP>15</FireSP>
<Splash>40</Splash>
<Slow>1</Slow>
<UpgradeTime>5</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="1">
<Cost>60</Cost>
<Range>85</Range>
<Damage>10</Damage>
<FireSP>14</FireSP>
<Splash>45</Splash>
<Slow>.99</Slow>
<UpgradeTime>120</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="2">
<Cost>100</Cost>
<Range>90</Range>
<Damage>18</Damage>
<FireSP>13</FireSP>
<Splash>50</Splash>
<Slow>.99</Slow>
<UpgradeTime>140</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="3">
<Cost>150</Cost>
<Range>95</Range>
<Damage>28</Damage>
<FireSP>12</FireSP>
<Splash>55</Splash>
<Slow>.98</Slow>
<UpgradeTime>160</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="4">
<Cost>210</Cost>
<Range>100</Range>
<Damage>40</Damage>
<FireSP>11</FireSP>
<Splash>60</Splash>
<Slow>.98</Slow>
<UpgradeTime>160</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="5">
<Cost>260</Cost>
<Range>105</Range>
<Damage>54</Damage>
<FireSP>10</FireSP>
<Splash>65</Splash>
<Slow>.97</Slow>
<UpgradeTime>160</UpgradeTime>
<TechReq>2</TechReq>
</Level>
<Level id="6">
<Cost>-1</Cost>
</Level>
</Tower>
<Tower id="2">
<Cost>150</Cost>
<Name>Slow Tower</Name>
<Size>25</Size>
<Func>Weapon</Func>
<TechType>Slow</TechType>
<UGTechType>Slow</UGTechType>
<Info>Slows creeps for other towers. No Damage.</Info>
<Level id="0">
<Cost>0</Cost>
<Range>70</Range>
<Damage>0</Damage>
<FireSP>20</FireSP>
<Splash>0</Splash>
<Slow>.80</Slow>
<UpgradeTime>5</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="1">
<Cost>150</Cost>
<Range>80</Range>
<Damage>0</Damage>
<FireSP>17</FireSP>
<Splash>0</Splash>
<Slow>.75</Slow>
<UpgradeTime>12</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="2">
<Cost>200</Cost>
<Range>90</Range>
<Damage>0</Damage>
<FireSP>15</FireSP>
<Splash>0</Splash>
<Slow>.70</Slow>
<UpgradeTime>14</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="3">
<Cost>250</Cost>
<Range>100</Range>
<Damage>0</Damage>
<FireSP>12</FireSP>
<Splash>0</Splash>
<Slow>.65</Slow>
<UpgradeTime>16</UpgradeTime>
<TechReq>2</TechReq>
</Level>
<Level id="4">
<Cost>-1</Cost>
</Level>
</Tower>
<Tower id="3">
<Cost>150</Cost>
<Name>Big Gun Tower</Name>
<Size>35</Size>
<Func>Weapon</Func>
<TechType>Gun</TechType>
<UGTechType>Gun</UGTechType>
<Info>Requires Gun Research centre. High damage, good aim and fire rate.</Info>
<Level id="0">
<Cost>0</Cost>
<Range>90</Range>
<Damage>7</Damage>
<FireSP>8</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>5</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="1">
<Cost>200</Cost>
<Range>100</Range>
<Damage>14</Damage>
<FireSP>7</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>60</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="2">
<Cost>250</Cost>
<Range>110</Range>
<Damage>22</Damage>
<FireSP>6</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>70</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="3">
<Cost>300</Cost>
<Range>120</Range>
<Damage>31</Damage>
<FireSP>5</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>80</UpgradeTime>
<TechReq>2</TechReq>
</Level>
<Level id="4">
<Cost>350</Cost>
<Range>130</Range>
<Damage>41</Damage>
<FireSP>4</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>90</UpgradeTime>
<TechReq>2</TechReq>
</Level>
<Level id="5">
<Cost>400</Cost>
<Range>140</Range>
<Damage>52</Damage>
<FireSP>3</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>90</UpgradeTime>
<TechReq>3</TechReq>
</Level>
<Level id="5">
<Cost>-1</Cost>
</Level>
</Tower>
<Tower id="4">
<Cost>250</Cost>
<Name>Missile Turret</Name>
<Size>35</Size>
<Func>Weapon</Func>
<TechType>Missile</TechType>
<UGTechType>Bomb</UGTechType>
<Info>Requires Explosives Research. Fires heat seeking missiles. Huge range, good splash and some slow.</Info>
<Level id="0">
<Cost>0</Cost>
<Range>150</Range>
<Damage>21</Damage>
<FireSP>17</FireSP>
<Splash>25</Splash>
<Slow>1</Slow>
<UpgradeTime>5</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="1">
<Cost>150</Cost>
<Range>160</Range>
<Damage>29</Damage>
<FireSP>15</FireSP>
<Splash>30</Splash>
<Slow>1</Slow>
<UpgradeTime>120</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="2">
<Cost>225</Cost>
<Range>170</Range>
<Damage>38</Damage>
<FireSP>13</FireSP>
<Splash>40</Splash>
<Slow>1</Slow>
<UpgradeTime>140</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="3">
<Cost>325</Cost>
<Range>180</Range>
<Damage>47</Damage>
<FireSP>11</FireSP>
<Splash>50</Splash>
<Slow>1</Slow>
<UpgradeTime>160</UpgradeTime>
<TechReq>2</TechReq>
</Level>
<Level id="4">
<Cost>450</Cost>
<Range>190</Range>
<Damage>57</Damage>
<FireSP>9</FireSP>
<Splash>60</Splash>
<Slow>.99</Slow>
<UpgradeTime>160</UpgradeTime>
<TechReq>3</TechReq>
</Level>
<Level id="5">
<Cost>600</Cost>
<Range>200</Range>
<Damage>68</Damage>
<FireSP>7</FireSP>
<Splash>70</Splash>
<Slow>.98</Slow>
<UpgradeTime>160</UpgradeTime>
<TechReq>4</TechReq>
</Level>
<Level id="6">
<Cost>-1</Cost>
</Level>
</Tower>
<Tower id="5">
<Cost>400</Cost>
<Name>Shock Tower</Name>
<Size>35</Size>
<Func>Weapon</Func>
<TechType>Shock</TechType>
<UGTechType>Slow</UGTechType>
<Info>Requires Electrics Research. Hits ALL targets within range with one shot. Low fire rate, but good damage and some slow.</Info>
<Level id="0">
<Cost>0</Cost>
<Range>70</Range>
<Damage>20</Damage>
<FireSP>30</FireSP>
<Splash>0</Splash>
<Slow>.99</Slow>
<UpgradeTime>5</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="1">
<Cost>400</Cost>
<Range>75</Range>
<Damage>45</Damage>
<FireSP>28</FireSP>
<Splash>0</Splash>
<Slow>.98</Slow>
<UpgradeTime>60</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="2">
<Cost>475</Cost>
<Range>80</Range>
<Damage>70</Damage>
<FireSP>26</FireSP>
<Splash>0</Splash>
<Slow>.96</Slow>
<UpgradeTime>65</UpgradeTime>
<TechReq>2</TechReq>
</Level>
<Level id="3">
<Cost>650</Cost>
<Range>85</Range>
<Damage>100</Damage>
<FireSP>24</FireSP>
<Splash>0</Splash>
<Slow>.93</Slow>
<UpgradeTime>70</UpgradeTime>
<TechReq>3</TechReq>
</Level>
<Level id="4">
<Cost>800</Cost>
<Range>90</Range>
<Damage>135</Damage>
<FireSP>22</FireSP>
<Splash>0</Splash>
<Slow>.9</Slow>
<UpgradeTime>75</UpgradeTime>
<TechReq>4</TechReq>
</Level>
<Level id="5">
<Cost>-1</Cost>
</Level>
</Tower>
<Tower id="6">
<Cost>1500</Cost>
<Name>Laser MegaTower</Name>
<Size>50</Size>
<Func>Weapon</Func>
<TechType>GunShock</TechType>
<UGTechType>Multi</UGTechType>
<Info>Requires all research centres at level 3. Constant fire, huge damage.</Info>
<Level id="0">
<Cost>0</Cost>
<Range>100</Range>
<Damage>30</Damage>
<FireSP>1</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>5</UpgradeTime>
<TechReq>3</TechReq>
</Level>
<Level id="1">
<Cost>1400</Cost>
<Range>110</Range>
<Damage>75</Damage>
<FireSP>1</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>65</UpgradeTime>
<TechReq>4</TechReq>
</Level>
<Level id="2">
<Cost>1300</Cost>
<Range>120</Range>
<Damage>120</Damage>
<FireSP>1</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>75</UpgradeTime>
<TechReq>5</TechReq>
</Level>
<Level id="3">
<Cost>1200</Cost>
<Range>130</Range>
<Damage>165</Damage>
<FireSP>1</FireSP>
<Splash>0</Splash>
<Slow>1</Slow>
<UpgradeTime>85</UpgradeTime>
<TechReq>6</TechReq>
</Level>
<Level id="4">
<Cost>-1</Cost>
</Level>
</Tower>
<Tower id="7">
<Cost>30</Cost>
<Name>Mine</Name>
<Size>30</Size>
<Func>Weapon</Func>
<TechType>Mine</TechType>
<UGTechType>Mine</UGTechType>
<Info>Requires Mine Factory. Leave mines on paths for one-shot, large splash, huge damage and slow.</Info>
<Level id="0">
<Cost>0</Cost>
<Range>30</Range>
<Damage>100</Damage>
<FireSP>30</FireSP>
<Splash>50</Splash>
<Slow>.65</Slow>
<UpgradeTime>5</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="1">
<Cost>30</Cost>
<Range>32</Range>
<Damage>250</Damage>
<FireSP>30</FireSP>
<Splash>65</Splash>
<Slow>.6</Slow>
<UpgradeTime>15</UpgradeTime>
<TechReq>1</TechReq>
</Level>
<Level id="2">
<Cost>50</Cost>
<Range>34</Range>
<Damage>500</Damage>
<FireSP>30</FireSP>
<Splash>85</Splash>
<Slow>.55</Slow>
<UpgradeTime>25</UpgradeTime>
<TechReq>2</TechReq>
</Level>
<Level id="3">
<Cost>80</Cost>
<Range>36</Range>
<Damage>1000</Damage>
<FireSP>30</FireSP>
<Splash>110</Splash>
<Slow>.5</Slow>
<UpgradeTime>35</UpgradeTime>
<TechReq>3</TechReq>
</Level>
<Level id="4">
<Cost>120</Cost>
<Range>38</Range>
<Damage>2000</Damage>
<FireSP>30</FireSP>
<Splash>140</Splash>
<Slow>.5</Slow>
<UpgradeTime>45</UpgradeTime>
<TechReq>4</TechReq>
</Level>
<Level id="5">
<Cost>170</Cost>
<Range>40</Range>
<Damage>4000</Damage>
<FireSP>30</FireSP>
<Splash>175</Splash>
<Slow>.5</Slow>
<UpgradeTime>55</UpgradeTime>
<TechReq>5</TechReq>
</Level>
<Level id="6">
<Cost>-1</Cost>
</Level>
</Tower>
<Tower id="8">
</Tower>
<Tower id="9">
</Tower>
<Tower id="10">
</Tower>
<Tower id="11">
</Tower>
<Tower id="12">
</Tower>
<Tower id="13">
</Tower>
<Tower id="14">
</Tower>
<Tower id="15">
</Tower>
<Tower id="16">
</Tower>
<Tower id="17">
</Tower>
<Tower id="18">
</Tower>
<Tower id="19">
<Cost>250</Cost>
<Name>Gun Research</Name>
<Size>50</Size>
<Func>Research</Func>
<TechType>Gun</TechType>
<Info>Research Projectile Weapons Technology for extra upgrades.</Info>
<Level id="0">
<Cost>0</Cost>
<Techup>0</Techup>
<UpgradeTime>200</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="1">
<Cost>100</Cost>
<Techup>1</Techup>
<UpgradeTime>300</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="2">
<Cost>250</Cost>
<Techup>2</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="3">
<Cost>400</Cost>
<Techup>3</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="4">
<Cost>550</Cost>
<Techup>4</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="5">
<Cost>700</Cost>
<Techup>5</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="6">
<Cost>850</Cost>
<Techup>6</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="7">
<Cost>-1</Cost>
</Level>
</Tower>
<Tower id="20">
<Cost>300</Cost>
<Name>Expl. Research</Name>
<Size>50</Size>
<Func>Research</Func>
<TechType>Bomb</TechType>
<Info>Research Explosives Technology for extra upgrades.</Info>
<Level id="0">
<Cost>0</Cost>
<Techup>0</Techup>
<UpgradeTime>200</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="1">
<Cost>100</Cost>
<Techup>1</Techup>
<UpgradeTime>300</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="2">
<Cost>250</Cost>
<Techup>2</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="3">
<Cost>400</Cost>
<Techup>3</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="4">
<Cost>550</Cost>
<Techup>4</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="5">
<Cost>700</Cost>
<Techup>5</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="6">
<Cost>850</Cost>
<Techup>6</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="7">
<Cost>-1</Cost>
</Level>
</Tower>
<Tower id="21">
<Cost>350</Cost>
<Name>Electric Research</Name>
<Size>50</Size>
<Func>Research</Func>
<TechType>Slow</TechType>
<Info>Research Electrics Technology for extra upgrades.</Info>
<Level id="0">
<Cost>0</Cost>
<Techup>0</Techup>
<UpgradeTime>200</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="1">
<Cost>100</Cost>
<Techup>1</Techup>
<UpgradeTime>5</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="2">
<Cost>250</Cost>
<Techup>2</Techup>
<UpgradeTime>300</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="3">
<Cost>400</Cost>
<Techup>3</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="4">
<Cost>550</Cost>
<Techup>4</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="5">
<Cost>700</Cost>
<Techup>5</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="6">
<Cost>850</Cost>
<Techup>6</Techup>
<UpgradeTime>400</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="7">
<Cost>-1</Cost>
</Level>
</Tower>
<Tower id="22">
<Cost>100</Cost>
<Name>Mine Factory</Name>
<Size>50</Size>
<Func>Research</Func>
<TechType>Mine</TechType>
<Info>Build Mines.</Info>
<Level id="0">
<Cost>0</Cost>
<Techup>0</Techup>
<UpgradeTime>150</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="1">
<Cost>50</Cost>
<Techup>1</Techup>
<UpgradeTime>175</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="2">
<Cost>100</Cost>
<Techup>2</Techup>
<UpgradeTime>200</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="3">
<Cost>150</Cost>
<Techup>3</Techup>
<UpgradeTime>225</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="4">
<Cost>200</Cost>
<Techup>4</Techup>
<UpgradeTime>250</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="5">
<Cost>250</Cost>
<Techup>5</Techup>
<UpgradeTime>275</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="6">
<Cost>-1</Cost>
</Level>
</Tower>
<Tower id="23">
<Cost>100</Cost>
<Name>Finance Centre</Name>
<Size>50</Size>
<Func>Research</Func>
<TechType>Cash</TechType>
<Info>Increase cash interest (adds 3% per level)</Info>
<Level id="0">
<Cost>0</Cost>
<Techup>0</Techup>
<UpgradeTime>5</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="1">
<Cost>800</Cost>
<Techup>1</Techup>
<UpgradeTime>5</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="2">
<Cost>1600</Cost>
<Techup>2</Techup>
<UpgradeTime>5</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="3">
<Cost>2400</Cost>
<Techup>3</Techup>
<UpgradeTime>5</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="4">
<Cost>3200</Cost>
<Techup>4</Techup>
<UpgradeTime>5</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="5">
<Cost>4800</Cost>
<Techup>5</Techup>
<UpgradeTime>5</UpgradeTime>
<TechReq>-1</TechReq>
</Level>
<Level id="6">
<Cost>-1</Cost>
</Level>
</Tower>
</Towers>
;
super();
}
}
}//package
Section 123
//TowerInfo (TowerInfo)
package {
import flash.display.*;
import flash.text.*;
public dynamic class TowerInfo extends MovieClip {
public var towername:TextField;
public var towerlevel:TextField;
public var towerslowu:TextField;
public var towerrangeu:TextField;
public var towerspeedu:TextField;
public var towerslow:TextField;
public var closebut:SimpleButton;
public var upgradetechreq:TextField;
public var towersplash:TextField;
public var towerdamageu:TextField;
public var towersplashu:TextField;
public var towerdamage:TextField;
public var towerrange:TextField;
public var towerspeed:TextField;
public var upgradebut:SimpleButton;
public var upgradecost:TextField;
public var sellbut:SimpleButton;
}
}//package
Section 124
//TowerPlacementController (TowerPlacementController)
package {
import flash.display.*;
public dynamic class TowerPlacementController extends MovieClip {
public var no:MovieClip;
public var towersHolder:MovieClip;
}
}//package
Section 125
//TowersHolderforControl (TowersHolderforControl)
package {
import flash.display.*;
public dynamic class TowersHolderforControl extends MovieClip {
public var tow:MovieClip;
public var detect:MovieClip;
}
}//package
Section 126
//TUNE1 (TUNE1)
package {
import flash.media.*;
public dynamic class TUNE1 extends Sound {
}
}//package
Section 127
//TUNE2 (TUNE2)
package {
import flash.media.*;
public dynamic class TUNE2 extends Sound {
}
}//package
Section 128
//wave_definitions (wave_definitions)
package {
import flash.display.*;
public class wave_definitions extends Sprite {
public var myXml:XML;
public function wave_definitions(){
myXml = <Waves>
<WaveCount>7</WaveCount>
<WaveTimer>30000</WaveTimer>
<Wave id="0">
<Name>The Muffers</Name>
<Type>1</Type>
<HP>10</HP>
<SlowResist>1</SlowResist>
<Speed>1.5</Speed>
<Quantity>20</Quantity>
<Timing>20</Timing>
<Worth>1</Worth>
</Wave>
<Wave id="1">
<Name>Funkinslop</Name>
<Type>2</Type>
<HP>12</HP>
<SlowResist>1</SlowResist>
<Speed>1.5</Speed>
<Quantity>21</Quantity>
<Timing>20</Timing>
<Worth>1</Worth>
</Wave>
<Wave id="2">
<Name>Biggly Goers</Name>
<Type>3</Type>
<HP>15</HP>
<SlowResist>1</SlowResist>
<Speed>1.5</Speed>
<Quantity>22</Quantity>
<Timing>10</Timing>
<Worth>2</Worth>
</Wave>
<Wave id="3">
<Name>The Foolish</Name>
<Type>4</Type>
<HP>19</HP>
<SlowResist>1</SlowResist>
<Speed>1.5</Speed>
<Quantity>23</Quantity>
<Timing>10</Timing>
<Worth>2</Worth>
</Wave>
<Wave id="4">
<Name>Agents Smith</Name>
<Type>5</Type>
<HP>23</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>24</Quantity>
<Timing>10</Timing>
<Worth>2</Worth>
</Wave>
<Wave id="5">
<Name>NutStop</Name>
<Type>3</Type>
<HP>29</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>25</Quantity>
<Timing>10</Timing>
<Worth>3</Worth>
</Wave>
<Wave id="6">
<Name>Bustards</Name>
<Type>7</Type>
<HP>37</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>26</Quantity>
<Timing>10</Timing>
<Worth>3</Worth>
</Wave>
<Wave id="7">
<Name>Super Bustards</Name>
<Type>2</Type>
<HP>45</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>27</Quantity>
<Timing>10</Timing>
<Worth>3</Worth>
</Wave>
<Wave id="8">
<Name>Evil Kitty Boss</Name>
<Type>6</Type>
<HP>270</HP>
<SlowResist>1</SlowResist>
<Speed>1</Speed>
<Quantity>1</Quantity>
<Timing>10</Timing>
<Worth>150</Worth>
</Wave>
<Wave id="9">
<Name>The Many</Name>
<Type>1</Type>
<HP>25</HP>
<SlowResist>1</SlowResist>
<Speed>4</Speed>
<Quantity>55</Quantity>
<Timing>5</Timing>
<Worth>3</Worth>
</Wave>
<Wave id="10">
<Name>The Few</Name>
<Type>2</Type>
<HP>100</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>10</Quantity>
<Timing>10</Timing>
<Worth>4</Worth>
</Wave>
<Wave id="11">
<Name>Bitchemin</Name>
<Type>3</Type>
<HP>70</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>29</Quantity>
<Timing>10</Timing>
<Worth>4</Worth>
</Wave>
<Wave id="12">
<Name>Marvoz</Name>
<Type>9</Type>
<HP>85</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>30</Quantity>
<Timing>10</Timing>
<Worth>4</Worth>
</Wave>
<Wave id="13">
<Name>Wigglesbury</Name>
<Type>2</Type>
<HP>97</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>31</Quantity>
<Timing>10</Timing>
<Worth>4</Worth>
</Wave>
<Wave id="14">
<Name>Moot Boss</Name>
<Type>1</Type>
<HP>500</HP>
<SlowResist>1</SlowResist>
<Speed>1</Speed>
<Quantity>3</Quantity>
<Timing>60</Timing>
<Worth>200</Worth>
</Wave>
<Wave id="15">
<Name>Wormulon</Name>
<Type>2</Type>
<HP>50</HP>
<SlowResist>1</SlowResist>
<Speed>3</Speed>
<Quantity>100</Quantity>
<Timing>3</Timing>
<Worth>5</Worth>
</Wave>
<Wave id="16">
<Name>Remus 5</Name>
<Type>3</Type>
<HP>140</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>30</Quantity>
<Timing>10</Timing>
<Worth>5</Worth>
</Wave>
<Wave id="17">
<Name>Remus 9</Name>
<Type>1</Type>
<HP>155</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>31</Quantity>
<Timing>10</Timing>
<Worth>5</Worth>
</Wave>
<Wave id="18">
<Name>Upple Diggers</Name>
<Type>2</Type>
<HP>171</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>32</Quantity>
<Timing>10</Timing>
<Worth>5</Worth>
</Wave>
<Wave id="19">
<Name>Fimo Curse</Name>
<Type>2</Type>
<HP>200</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>33</Quantity>
<Timing>10</Timing>
<Worth>5</Worth>
</Wave>
<Wave id="20">
<Name>Jumpy Pumpers</Name>
<Type>2</Type>
<HP>230</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>34</Quantity>
<Timing>10</Timing>
<Worth>5</Worth>
</Wave>
<Wave id="21">
<Name>Fastards</Name>
<Type>2</Type>
<HP>270</HP>
<SlowResist>1</SlowResist>
<Speed>4</Speed>
<Quantity>35</Quantity>
<Timing>30</Timing>
<Worth>5</Worth>
</Wave>
<Wave id="22">
<Name>Plod Rockers</Name>
<Type>2</Type>
<HP>315</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>36</Quantity>
<Timing>10</Timing>
<Worth>6</Worth>
</Wave>
<Wave id="23">
<Name>Melvins</Name>
<Type>2</Type>
<HP>347</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>37</Quantity>
<Timing>10</Timing>
<Worth>6</Worth>
</Wave>
<Wave id="24">
<Name>Slow Worm</Name>
<Type>2</Type>
<HP>384</HP>
<SlowResist>1</SlowResist>
<Speed>1</Speed>
<Quantity>100</Quantity>
<Timing>6</Timing>
<Worth>6</Worth>
</Wave>
<Wave id="25">
<Name>Uber Bossy</Name>
<Type>2</Type>
<HP>3200</HP>
<SlowResist>1</SlowResist>
<Speed>1</Speed>
<Quantity>3</Quantity>
<Timing>40</Timing>
<Worth>250</Worth>
</Wave>
<Wave id="26">
<Name>Muntiheimer</Name>
<Type>3</Type>
<HP>306</HP>
<SlowResist>1</SlowResist>
<Speed>3</Speed>
<Quantity>39</Quantity>
<Timing>10</Timing>
<Worth>7</Worth>
</Wave>
<Wave id="27">
<Name>Blickenshtein</Name>
<Type>1</Type>
<HP>483</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>40</Quantity>
<Timing>10</Timing>
<Worth>7</Worth>
</Wave>
<Wave id="28">
<Name>Mud Hunty</Name>
<Type>1</Type>
<HP>522</HP>
<SlowResist>1</SlowResist>
<Speed>4</Speed>
<Quantity>41</Quantity>
<Timing>30</Timing>
<Worth>7</Worth>
</Wave>
<Wave id="29">
<Name>Bibble Chubber</Name>
<Type>1</Type>
<HP>536</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>42</Quantity>
<Timing>10</Timing>
<Worth>7</Worth>
</Wave>
<Wave id="30">
<Name>Bullin</Name>
<Type>1</Type>
<HP>570</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>43</Quantity>
<Timing>10</Timing>
<Worth>8</Worth>
</Wave>
<Wave id="31">
<Name>Bibble</Name>
<Type>1</Type>
<HP>249</HP>
<SlowResist>1</SlowResist>
<Speed>4</Speed>
<Quantity>70</Quantity>
<Timing>5</Timing>
<Worth>8</Worth>
</Wave>
<Wave id="32">
<Name>Millicent</Name>
<Type>1</Type>
<HP>598</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>44</Quantity>
<Timing>10</Timing>
<Worth>8</Worth>
</Wave>
<Wave id="33">
<Name>WipeOut</Name>
<Type>1</Type>
<HP>650</HP>
<SlowResist>1</SlowResist>
<Speed>1.5</Speed>
<Quantity>100</Quantity>
<Timing>20</Timing>
<Worth>8</Worth>
</Wave>
<Wave id="34">
<Name>BubbleBoss</Name>
<Type>1</Type>
<HP>12000</HP>
<SlowResist>1</SlowResist>
<Speed>1</Speed>
<Quantity>1</Quantity>
<Timing>20</Timing>
<Worth>1000</Worth>
</Wave>
<Wave id="35">
<Name>Their</Name>
<Type>1</Type>
<HP>400</HP>
<SlowResist>1</SlowResist>
<Speed>4</Speed>
<Quantity>100</Quantity>
<Timing>6</Timing>
<Worth>9</Worth>
</Wave>
<Wave id="36">
<Name>Liken</Name>
<Type>1</Type>
<HP>685</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>45</Quantity>
<Timing>10</Timing>
<Worth>9</Worth>
</Wave>
<Wave id="37">
<Name>Dundys</Name>
<Type>1</Type>
<HP>724</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>46</Quantity>
<Timing>10</Timing>
<Worth>9</Worth>
</Wave>
<Wave id="38">
<Name>Puffer JaKt</Name>
<Type>1</Type>
<HP>778</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>47</Quantity>
<Timing>10</Timing>
<Worth>9</Worth>
</Wave>
<Wave id="39">
<Name>Bingy</Name>
<Type>1</Type>
<HP>832</HP>
<SlowResist>1</SlowResist>
<Speed>4</Speed>
<Quantity>48</Quantity>
<Timing>10</Timing>
<Worth>9</Worth>
</Wave>
<Wave id="40">
<Name>Wukka</Name>
<Type>1</Type>
<HP>956</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>49</Quantity>
<Timing>10</Timing>
<Worth>9</Worth>
</Wave>
<Wave id="41">
<Name>Pill Chudder</Name>
<Type>1</Type>
<HP>1112</HP>
<SlowResist>1</SlowResist>
<Speed>3</Speed>
<Quantity>50</Quantity>
<Timing>10</Timing>
<Worth>9</Worth>
</Wave>
<Wave id="42">
<Name>Chuff Monster</Name>
<Type>1</Type>
<HP>23000</HP>
<SlowResist>1</SlowResist>
<Speed>1.5</Speed>
<Quantity>1</Quantity>
<Timing>10</Timing>
<Worth>1500</Worth>
</Wave>
<Wave id="43">
<Name>Bliboil</Name>
<Type>1</Type>
<HP>1724</HP>
<SlowResist>1</SlowResist>
<Speed>4</Speed>
<Quantity>70</Quantity>
<Timing>30</Timing>
<Worth>10</Worth>
</Wave>
<Wave id="44">
<Name>Fimlitch</Name>
<Type>1</Type>
<HP>2086</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>53</Quantity>
<Timing>10</Timing>
<Worth>10</Worth>
</Wave>
<Wave id="45">
<Name>Byznathum</Name>
<Type>1</Type>
<HP>2580</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>54</Quantity>
<Timing>10</Timing>
<Worth>10</Worth>
</Wave>
<Wave id="46">
<Name>MupperDrone</Name>
<Type>1</Type>
<HP>3200</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>55</Quantity>
<Timing>11</Timing>
<Worth>11</Worth>
</Wave>
<Wave id="47">
<Name>Cash Cow Bob</Name>
<Type>1</Type>
<HP>35000</HP>
<SlowResist>1</SlowResist>
<Speed>1</Speed>
<Quantity>1</Quantity>
<Timing>10</Timing>
<Worth>3000</Worth>
</Wave>
<Wave id="48">
<Name>Millicent</Name>
<Type>1</Type>
<HP>1920</HP>
<SlowResist>1</SlowResist>
<Speed>4</Speed>
<Quantity>120</Quantity>
<Timing>5</Timing>
<Worth>15</Worth>
</Wave>
<Wave id="49">
<Name>Upstander</Name>
<Type>1</Type>
<HP>4000</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>56</Quantity>
<Timing>10</Timing>
<Worth>20</Worth>
</Wave>
<Wave id="50">
<Name>Yard Sale</Name>
<Type>1</Type>
<HP>5000</HP>
<SlowResist>1</SlowResist>
<Speed>2</Speed>
<Quantity>300</Quantity>
<Timing>10</Timing>
<Worth>25</Worth>
</Wave>
<Wave id="51">
<Name>NAN</Name>
</Wave>
</Waves>
;
super();
}
}
}//package