Section 1
//Laboratory (Assets.Buildings.Laboratory)
package Assets.Buildings {
import flash.display.*;
public dynamic class Laboratory extends BitmapData {
public function Laboratory(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Buildings
Section 2
//Thumbnails (Assets.Buildings.Thumbnails)
package Assets.Buildings {
import flash.display.*;
public dynamic class Thumbnails extends BitmapData {
public function Thumbnails(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Buildings
Section 3
//Workshop (Assets.Buildings.Workshop)
package Assets.Buildings {
import flash.display.*;
public dynamic class Workshop extends BitmapData {
public function Workshop(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Buildings
Section 4
//CaptureIt (Assets.Fonts.CaptureIt)
package Assets.Fonts {
import flash.text.*;
public dynamic class CaptureIt extends Font {
}
}//package Assets.Fonts
Section 5
//MenuButton (Assets.Interface.MenuButton)
package Assets.Interface {
import flash.display.*;
public dynamic class MenuButton extends BitmapData {
public function MenuButton(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Interface
Section 6
//MenuButtonBig (Assets.Interface.MenuButtonBig)
package Assets.Interface {
import flash.display.*;
public dynamic class MenuButtonBig extends BitmapData {
public function MenuButtonBig(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Interface
Section 7
//MenuButtons (Assets.Interface.MenuButtons)
package Assets.Interface {
import flash.display.*;
public dynamic class MenuButtons extends BitmapData {
public function MenuButtons(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Interface
Section 8
//RoundButton (Assets.Interface.RoundButton)
package Assets.Interface {
import flash.display.*;
public dynamic class RoundButton extends BitmapData {
public function RoundButton(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Interface
Section 9
//TowerAbilities (Assets.Interface.TowerAbilities)
package Assets.Interface {
import flash.display.*;
public dynamic class TowerAbilities extends BitmapData {
public function TowerAbilities(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Interface
Section 10
//Boar (Assets.Monsters.Boar)
package Assets.Monsters {
import flash.display.*;
public dynamic class Boar extends BitmapData {
public function Boar(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 11
//BoarDeath (Assets.Monsters.BoarDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class BoarDeath extends Sound {
}
}//package Assets.Monsters
Section 12
//DeathKnight (Assets.Monsters.DeathKnight)
package Assets.Monsters {
import flash.display.*;
public dynamic class DeathKnight extends BitmapData {
public function DeathKnight(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 13
//DeathKnightDeath (Assets.Monsters.DeathKnightDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class DeathKnightDeath extends Sound {
}
}//package Assets.Monsters
Section 14
//Demon (Assets.Monsters.Demon)
package Assets.Monsters {
import flash.display.*;
public dynamic class Demon extends BitmapData {
public function Demon(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 15
//DemonDeath (Assets.Monsters.DemonDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class DemonDeath extends Sound {
}
}//package Assets.Monsters
Section 16
//Dwarf (Assets.Monsters.Dwarf)
package Assets.Monsters {
import flash.display.*;
public dynamic class Dwarf extends BitmapData {
public function Dwarf(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 17
//DwarfDeath (Assets.Monsters.DwarfDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class DwarfDeath extends Sound {
}
}//package Assets.Monsters
Section 18
//DwarfStone (Assets.Monsters.DwarfStone)
package Assets.Monsters {
import flash.display.*;
public dynamic class DwarfStone extends BitmapData {
public function DwarfStone(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 19
//Eye (Assets.Monsters.Eye)
package Assets.Monsters {
import flash.display.*;
public dynamic class Eye extends BitmapData {
public function Eye(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 20
//EyeDeath (Assets.Monsters.EyeDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class EyeDeath extends Sound {
}
}//package Assets.Monsters
Section 21
//Grunt (Assets.Monsters.Grunt)
package Assets.Monsters {
import flash.display.*;
public dynamic class Grunt extends BitmapData {
public function Grunt(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 22
//GruntBerserker (Assets.Monsters.GruntBerserker)
package Assets.Monsters {
import flash.display.*;
public dynamic class GruntBerserker extends BitmapData {
public function GruntBerserker(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 23
//GruntDeath (Assets.Monsters.GruntDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class GruntDeath extends Sound {
}
}//package Assets.Monsters
Section 24
//GruntScout (Assets.Monsters.GruntScout)
package Assets.Monsters {
import flash.display.*;
public dynamic class GruntScout extends BitmapData {
public function GruntScout(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 25
//Knight (Assets.Monsters.Knight)
package Assets.Monsters {
import flash.display.*;
public dynamic class Knight extends BitmapData {
public function Knight(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 26
//KnightBlack (Assets.Monsters.KnightBlack)
package Assets.Monsters {
import flash.display.*;
public dynamic class KnightBlack extends BitmapData {
public function KnightBlack(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 27
//KnightDeath (Assets.Monsters.KnightDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class KnightDeath extends Sound {
}
}//package Assets.Monsters
Section 28
//Mercenary (Assets.Monsters.Mercenary)
package Assets.Monsters {
import flash.display.*;
public dynamic class Mercenary extends BitmapData {
public function Mercenary(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 29
//MercenaryDeath (Assets.Monsters.MercenaryDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class MercenaryDeath extends Sound {
}
}//package Assets.Monsters
Section 30
//MercenaryVeteran (Assets.Monsters.MercenaryVeteran)
package Assets.Monsters {
import flash.display.*;
public dynamic class MercenaryVeteran extends BitmapData {
public function MercenaryVeteran(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 31
//MercenaryVeteranDeath (Assets.Monsters.MercenaryVeteranDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class MercenaryVeteranDeath extends Sound {
}
}//package Assets.Monsters
Section 32
//Ogre (Assets.Monsters.Ogre)
package Assets.Monsters {
import flash.display.*;
public dynamic class Ogre extends BitmapData {
public function Ogre(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 33
//OgreDeath (Assets.Monsters.OgreDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class OgreDeath extends Sound {
}
}//package Assets.Monsters
Section 34
//OgreInfected (Assets.Monsters.OgreInfected)
package Assets.Monsters {
import flash.display.*;
public dynamic class OgreInfected extends BitmapData {
public function OgreInfected(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 35
//OgreSpirit (Assets.Monsters.OgreSpirit)
package Assets.Monsters {
import flash.display.*;
public dynamic class OgreSpirit extends BitmapData {
public function OgreSpirit(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 36
//Peon (Assets.Monsters.Peon)
package Assets.Monsters {
import flash.display.*;
public dynamic class Peon extends BitmapData {
public function Peon(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 37
//PeonDeath (Assets.Monsters.PeonDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class PeonDeath extends Sound {
}
}//package Assets.Monsters
Section 38
//PeonSpirit (Assets.Monsters.PeonSpirit)
package Assets.Monsters {
import flash.display.*;
public dynamic class PeonSpirit extends BitmapData {
public function PeonSpirit(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 39
//Sapper (Assets.Monsters.Sapper)
package Assets.Monsters {
import flash.display.*;
public dynamic class Sapper extends BitmapData {
public function Sapper(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 40
//SapperDeath (Assets.Monsters.SapperDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class SapperDeath extends Sound {
}
}//package Assets.Monsters
Section 41
//Thumbnails (Assets.Monsters.Thumbnails)
package Assets.Monsters {
import flash.display.*;
public dynamic class Thumbnails extends BitmapData {
public function Thumbnails(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 42
//Troll (Assets.Monsters.Troll)
package Assets.Monsters {
import flash.display.*;
public dynamic class Troll extends BitmapData {
public function Troll(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 43
//TrollBerserker (Assets.Monsters.TrollBerserker)
package Assets.Monsters {
import flash.display.*;
public dynamic class TrollBerserker extends BitmapData {
public function TrollBerserker(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 44
//TrollDeath (Assets.Monsters.TrollDeath)
package Assets.Monsters {
import flash.media.*;
public dynamic class TrollDeath extends Sound {
}
}//package Assets.Monsters
Section 45
//TrollScout (Assets.Monsters.TrollScout)
package Assets.Monsters {
import flash.display.*;
public dynamic class TrollScout extends BitmapData {
public function TrollScout(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Monsters
Section 46
//ArrowDown (Assets.Tiles.ArrowDown)
package Assets.Tiles {
import flash.display.*;
public dynamic class ArrowDown extends BitmapData {
public function ArrowDown(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 47
//ArrowLeft (Assets.Tiles.ArrowLeft)
package Assets.Tiles {
import flash.display.*;
public dynamic class ArrowLeft extends BitmapData {
public function ArrowLeft(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 48
//ArrowRight (Assets.Tiles.ArrowRight)
package Assets.Tiles {
import flash.display.*;
public dynamic class ArrowRight extends BitmapData {
public function ArrowRight(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 49
//ArrowUp (Assets.Tiles.ArrowUp)
package Assets.Tiles {
import flash.display.*;
public dynamic class ArrowUp extends BitmapData {
public function ArrowUp(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 50
//Cliff1 (Assets.Tiles.Cliff1)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff1 extends BitmapData {
public function Cliff1(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 51
//Cliff10 (Assets.Tiles.Cliff10)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff10 extends BitmapData {
public function Cliff10(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 52
//Cliff11 (Assets.Tiles.Cliff11)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff11 extends BitmapData {
public function Cliff11(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 53
//Cliff12 (Assets.Tiles.Cliff12)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff12 extends BitmapData {
public function Cliff12(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 54
//Cliff13 (Assets.Tiles.Cliff13)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff13 extends BitmapData {
public function Cliff13(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 55
//Cliff14 (Assets.Tiles.Cliff14)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff14 extends BitmapData {
public function Cliff14(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 56
//Cliff15 (Assets.Tiles.Cliff15)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff15 extends BitmapData {
public function Cliff15(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 57
//Cliff16 (Assets.Tiles.Cliff16)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff16 extends BitmapData {
public function Cliff16(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 58
//Cliff17 (Assets.Tiles.Cliff17)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff17 extends BitmapData {
public function Cliff17(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 59
//Cliff18 (Assets.Tiles.Cliff18)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff18 extends BitmapData {
public function Cliff18(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 60
//Cliff19 (Assets.Tiles.Cliff19)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff19 extends BitmapData {
public function Cliff19(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 61
//Cliff2 (Assets.Tiles.Cliff2)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff2 extends BitmapData {
public function Cliff2(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 62
//Cliff20 (Assets.Tiles.Cliff20)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff20 extends BitmapData {
public function Cliff20(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 63
//Cliff21 (Assets.Tiles.Cliff21)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff21 extends BitmapData {
public function Cliff21(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 64
//Cliff22 (Assets.Tiles.Cliff22)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff22 extends BitmapData {
public function Cliff22(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 65
//Cliff23 (Assets.Tiles.Cliff23)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff23 extends BitmapData {
public function Cliff23(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 66
//Cliff24 (Assets.Tiles.Cliff24)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff24 extends BitmapData {
public function Cliff24(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 67
//Cliff25 (Assets.Tiles.Cliff25)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff25 extends BitmapData {
public function Cliff25(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 68
//Cliff3 (Assets.Tiles.Cliff3)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff3 extends BitmapData {
public function Cliff3(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 69
//Cliff4 (Assets.Tiles.Cliff4)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff4 extends BitmapData {
public function Cliff4(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 70
//Cliff5 (Assets.Tiles.Cliff5)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff5 extends BitmapData {
public function Cliff5(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 71
//Cliff6 (Assets.Tiles.Cliff6)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff6 extends BitmapData {
public function Cliff6(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 72
//Cliff7 (Assets.Tiles.Cliff7)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff7 extends BitmapData {
public function Cliff7(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 73
//Cliff8 (Assets.Tiles.Cliff8)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff8 extends BitmapData {
public function Cliff8(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 74
//Cliff9 (Assets.Tiles.Cliff9)
package Assets.Tiles {
import flash.display.*;
public dynamic class Cliff9 extends BitmapData {
public function Cliff9(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 75
//Fence1 (Assets.Tiles.Fence1)
package Assets.Tiles {
import flash.display.*;
public dynamic class Fence1 extends BitmapData {
public function Fence1(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 76
//Fence2 (Assets.Tiles.Fence2)
package Assets.Tiles {
import flash.display.*;
public dynamic class Fence2 extends BitmapData {
public function Fence2(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 77
//Fence3 (Assets.Tiles.Fence3)
package Assets.Tiles {
import flash.display.*;
public dynamic class Fence3 extends BitmapData {
public function Fence3(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 78
//Grass1 (Assets.Tiles.Grass1)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass1 extends BitmapData {
public function Grass1(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 79
//Grass10 (Assets.Tiles.Grass10)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass10 extends BitmapData {
public function Grass10(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 80
//Grass11 (Assets.Tiles.Grass11)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass11 extends BitmapData {
public function Grass11(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 81
//Grass12 (Assets.Tiles.Grass12)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass12 extends BitmapData {
public function Grass12(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 82
//Grass13 (Assets.Tiles.Grass13)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass13 extends BitmapData {
public function Grass13(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 83
//Grass14 (Assets.Tiles.Grass14)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass14 extends BitmapData {
public function Grass14(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 84
//Grass15 (Assets.Tiles.Grass15)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass15 extends BitmapData {
public function Grass15(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 85
//Grass16 (Assets.Tiles.Grass16)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass16 extends BitmapData {
public function Grass16(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 86
//Grass17 (Assets.Tiles.Grass17)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass17 extends BitmapData {
public function Grass17(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 87
//Grass18 (Assets.Tiles.Grass18)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass18 extends BitmapData {
public function Grass18(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 88
//Grass2 (Assets.Tiles.Grass2)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass2 extends BitmapData {
public function Grass2(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 89
//Grass3 (Assets.Tiles.Grass3)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass3 extends BitmapData {
public function Grass3(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 90
//Grass4 (Assets.Tiles.Grass4)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass4 extends BitmapData {
public function Grass4(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 91
//Grass5 (Assets.Tiles.Grass5)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass5 extends BitmapData {
public function Grass5(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 92
//Grass6 (Assets.Tiles.Grass6)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass6 extends BitmapData {
public function Grass6(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 93
//Grass7 (Assets.Tiles.Grass7)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass7 extends BitmapData {
public function Grass7(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 94
//Grass8 (Assets.Tiles.Grass8)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass8 extends BitmapData {
public function Grass8(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 95
//Grass9 (Assets.Tiles.Grass9)
package Assets.Tiles {
import flash.display.*;
public dynamic class Grass9 extends BitmapData {
public function Grass9(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 96
//House1 (Assets.Tiles.House1)
package Assets.Tiles {
import flash.display.*;
public dynamic class House1 extends BitmapData {
public function House1(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 97
//House2 (Assets.Tiles.House2)
package Assets.Tiles {
import flash.display.*;
public dynamic class House2 extends BitmapData {
public function House2(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 98
//House3 (Assets.Tiles.House3)
package Assets.Tiles {
import flash.display.*;
public dynamic class House3 extends BitmapData {
public function House3(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 99
//House4 (Assets.Tiles.House4)
package Assets.Tiles {
import flash.display.*;
public dynamic class House4 extends BitmapData {
public function House4(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 100
//House5 (Assets.Tiles.House5)
package Assets.Tiles {
import flash.display.*;
public dynamic class House5 extends BitmapData {
public function House5(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 101
//House6 (Assets.Tiles.House6)
package Assets.Tiles {
import flash.display.*;
public dynamic class House6 extends BitmapData {
public function House6(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 102
//House7 (Assets.Tiles.House7)
package Assets.Tiles {
import flash.display.*;
public dynamic class House7 extends BitmapData {
public function House7(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 103
//House8 (Assets.Tiles.House8)
package Assets.Tiles {
import flash.display.*;
public dynamic class House8 extends BitmapData {
public function House8(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 104
//Land1 (Assets.Tiles.Land1)
package Assets.Tiles {
import flash.display.*;
public dynamic class Land1 extends BitmapData {
public function Land1(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 105
//Land10 (Assets.Tiles.Land10)
package Assets.Tiles {
import flash.display.*;
public dynamic class Land10 extends BitmapData {
public function Land10(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 106
//Land11 (Assets.Tiles.Land11)
package Assets.Tiles {
import flash.display.*;
public dynamic class Land11 extends BitmapData {
public function Land11(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 107
//Land12 (Assets.Tiles.Land12)
package Assets.Tiles {
import flash.display.*;
public dynamic class Land12 extends BitmapData {
public function Land12(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 108
//Land2 (Assets.Tiles.Land2)
package Assets.Tiles {
import flash.display.*;
public dynamic class Land2 extends BitmapData {
public function Land2(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 109
//Land3 (Assets.Tiles.Land3)
package Assets.Tiles {
import flash.display.*;
public dynamic class Land3 extends BitmapData {
public function Land3(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 110
//Land4 (Assets.Tiles.Land4)
package Assets.Tiles {
import flash.display.*;
public dynamic class Land4 extends BitmapData {
public function Land4(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 111
//Land5 (Assets.Tiles.Land5)
package Assets.Tiles {
import flash.display.*;
public dynamic class Land5 extends BitmapData {
public function Land5(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 112
//Land6 (Assets.Tiles.Land6)
package Assets.Tiles {
import flash.display.*;
public dynamic class Land6 extends BitmapData {
public function Land6(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 113
//Land7 (Assets.Tiles.Land7)
package Assets.Tiles {
import flash.display.*;
public dynamic class Land7 extends BitmapData {
public function Land7(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 114
//Land8 (Assets.Tiles.Land8)
package Assets.Tiles {
import flash.display.*;
public dynamic class Land8 extends BitmapData {
public function Land8(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 115
//Land9 (Assets.Tiles.Land9)
package Assets.Tiles {
import flash.display.*;
public dynamic class Land9 extends BitmapData {
public function Land9(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 116
//Rock1 (Assets.Tiles.Rock1)
package Assets.Tiles {
import flash.display.*;
public dynamic class Rock1 extends BitmapData {
public function Rock1(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 117
//Rock2 (Assets.Tiles.Rock2)
package Assets.Tiles {
import flash.display.*;
public dynamic class Rock2 extends BitmapData {
public function Rock2(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 118
//Rock3 (Assets.Tiles.Rock3)
package Assets.Tiles {
import flash.display.*;
public dynamic class Rock3 extends BitmapData {
public function Rock3(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 119
//Rock4 (Assets.Tiles.Rock4)
package Assets.Tiles {
import flash.display.*;
public dynamic class Rock4 extends BitmapData {
public function Rock4(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 120
//Tree1 (Assets.Tiles.Tree1)
package Assets.Tiles {
import flash.display.*;
public dynamic class Tree1 extends BitmapData {
public function Tree1(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 121
//Tree2 (Assets.Tiles.Tree2)
package Assets.Tiles {
import flash.display.*;
public dynamic class Tree2 extends BitmapData {
public function Tree2(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 122
//Tree3 (Assets.Tiles.Tree3)
package Assets.Tiles {
import flash.display.*;
public dynamic class Tree3 extends BitmapData {
public function Tree3(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 123
//Tree4 (Assets.Tiles.Tree4)
package Assets.Tiles {
import flash.display.*;
public dynamic class Tree4 extends BitmapData {
public function Tree4(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 124
//Tree5 (Assets.Tiles.Tree5)
package Assets.Tiles {
import flash.display.*;
public dynamic class Tree5 extends BitmapData {
public function Tree5(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 125
//Tree6 (Assets.Tiles.Tree6)
package Assets.Tiles {
import flash.display.*;
public dynamic class Tree6 extends BitmapData {
public function Tree6(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 126
//Tree7 (Assets.Tiles.Tree7)
package Assets.Tiles {
import flash.display.*;
public dynamic class Tree7 extends BitmapData {
public function Tree7(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 127
//Tree8 (Assets.Tiles.Tree8)
package Assets.Tiles {
import flash.display.*;
public dynamic class Tree8 extends BitmapData {
public function Tree8(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Tiles
Section 128
//ArrowFireSound (Assets.Towers.ArrowFireSound)
package Assets.Towers {
import flash.media.*;
public dynamic class ArrowFireSound extends Sound {
}
}//package Assets.Towers
Section 129
//ArrowMissile (Assets.Towers.ArrowMissile)
package Assets.Towers {
import flash.display.*;
public dynamic class ArrowMissile extends BitmapData {
public function ArrowMissile(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 130
//ArrowTower (Assets.Towers.ArrowTower)
package Assets.Towers {
import flash.display.*;
public dynamic class ArrowTower extends BitmapData {
public function ArrowTower(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 131
//BuildingPlacement (Assets.Towers.BuildingPlacement)
package Assets.Towers {
import flash.media.*;
public dynamic class BuildingPlacement extends Sound {
}
}//package Assets.Towers
Section 132
//CannonFireSound (Assets.Towers.CannonFireSound)
package Assets.Towers {
import flash.media.*;
public dynamic class CannonFireSound extends Sound {
}
}//package Assets.Towers
Section 133
//CannonMissile (Assets.Towers.CannonMissile)
package Assets.Towers {
import flash.display.*;
public dynamic class CannonMissile extends BitmapData {
public function CannonMissile(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 134
//CannonTower (Assets.Towers.CannonTower)
package Assets.Towers {
import flash.display.*;
public dynamic class CannonTower extends BitmapData {
public function CannonTower(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 135
//DeathTower (Assets.Towers.DeathTower)
package Assets.Towers {
import flash.display.*;
public dynamic class DeathTower extends BitmapData {
public function DeathTower(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 136
//EnergyMissile (Assets.Towers.EnergyMissile)
package Assets.Towers {
import flash.display.*;
public dynamic class EnergyMissile extends BitmapData {
public function EnergyMissile(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 137
//EnergyTower (Assets.Towers.EnergyTower)
package Assets.Towers {
import flash.display.*;
public dynamic class EnergyTower extends BitmapData {
public function EnergyTower(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 138
//FireExplosion (Assets.Towers.FireExplosion)
package Assets.Towers {
import flash.display.*;
public dynamic class FireExplosion extends BitmapData {
public function FireExplosion(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 139
//FireFireSound (Assets.Towers.FireFireSound)
package Assets.Towers {
import flash.media.*;
public dynamic class FireFireSound extends Sound {
}
}//package Assets.Towers
Section 140
//FireMissile (Assets.Towers.FireMissile)
package Assets.Towers {
import flash.display.*;
public dynamic class FireMissile extends BitmapData {
public function FireMissile(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 141
//FireTower (Assets.Towers.FireTower)
package Assets.Towers {
import flash.display.*;
public dynamic class FireTower extends BitmapData {
public function FireTower(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 142
//Generator (Assets.Towers.Generator)
package Assets.Towers {
import flash.display.*;
public dynamic class Generator extends BitmapData {
public function Generator(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 143
//IceFireSound (Assets.Towers.IceFireSound)
package Assets.Towers {
import flash.media.*;
public dynamic class IceFireSound extends Sound {
}
}//package Assets.Towers
Section 144
//IceMissile (Assets.Towers.IceMissile)
package Assets.Towers {
import flash.display.*;
public dynamic class IceMissile extends BitmapData {
public function IceMissile(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 145
//IceTower (Assets.Towers.IceTower)
package Assets.Towers {
import flash.display.*;
public dynamic class IceTower extends BitmapData {
public function IceTower(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 146
//PoisonFireSound (Assets.Towers.PoisonFireSound)
package Assets.Towers {
import flash.media.*;
public dynamic class PoisonFireSound extends Sound {
}
}//package Assets.Towers
Section 147
//PoisonMissile (Assets.Towers.PoisonMissile)
package Assets.Towers {
import flash.display.*;
public dynamic class PoisonMissile extends BitmapData {
public function PoisonMissile(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 148
//PoisonTower (Assets.Towers.PoisonTower)
package Assets.Towers {
import flash.display.*;
public dynamic class PoisonTower extends BitmapData {
public function PoisonTower(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 149
//ScoutTower (Assets.Towers.ScoutTower)
package Assets.Towers {
import flash.display.*;
public dynamic class ScoutTower extends BitmapData {
public function ScoutTower(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 150
//SniperTower (Assets.Towers.SniperTower)
package Assets.Towers {
import flash.display.*;
public dynamic class SniperTower extends BitmapData {
public function SniperTower(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 151
//Thumbnails (Assets.Towers.Thumbnails)
package Assets.Towers {
import flash.display.*;
public dynamic class Thumbnails extends BitmapData {
public function Thumbnails(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 152
//UpgradeComplete (Assets.Towers.UpgradeComplete)
package Assets.Towers {
import flash.media.*;
public dynamic class UpgradeComplete extends Sound {
}
}//package Assets.Towers
Section 153
//Upgrading (Assets.Towers.Upgrading)
package Assets.Towers {
import flash.display.*;
public dynamic class Upgrading extends BitmapData {
public function Upgrading(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.Towers
Section 154
//Shields (Assets.WorldMap.Shields)
package Assets.WorldMap {
import flash.display.*;
public dynamic class Shields extends BitmapData {
public function Shields(_arg1:Number, _arg2:Number){
super(_arg1, _arg2);
}
}
}//package Assets.WorldMap
Section 155
//Defeat (Assets.Defeat)
package Assets {
import flash.media.*;
public dynamic class Defeat extends Sound {
}
}//package Assets
Section 156
//RoundBeginning (Assets.RoundBeginning)
package Assets {
import flash.media.*;
public dynamic class RoundBeginning extends Sound {
}
}//package Assets
Section 157
//RoundCompleted (Assets.RoundCompleted)
package Assets {
import flash.media.*;
public dynamic class RoundCompleted extends Sound {
}
}//package Assets
Section 158
//Theme (Assets.Theme)
package Assets {
import flash.media.*;
public dynamic class Theme extends Sound {
}
}//package Assets
Section 159
//Victory (Assets.Victory)
package Assets {
import flash.media.*;
public dynamic class Victory extends Sound {
}
}//package Assets
Section 160
//Splash (InFlashStudios.Splash)
package InFlashStudios {
import flash.display.*;
import flash.events.*;
import flash.utils.*;
import flash.net.*;
import flash.filters.*;
public class Splash extends MovieClip {
private var Counter:int;// = 0
private var Ticker:Timer;
private var OnComplete:Function;
private var Blur:Number;// = 1
public var Logo:MovieClip;
public function Splash(_arg1:Stage, _arg2:Function){
Counter = 0;
Blur = 1;
super();
_arg1.addChild(this);
this.OnComplete = _arg2;
this.alpha = 0;
this.mouseChildren = false;
this.buttonMode = true;
this.useHandCursor = true;
this.Ticker = new Timer(25);
this.Ticker.addEventListener(TimerEvent.TIMER, this.FadeIn);
this.Ticker.start();
}
private function OpenIFS(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.inflashstudios.com/"), "_blank");
}
private function Tick(_arg1:Event):void{
this.Counter++;
if (this.alpha < 0){
this.Ticker.removeEventListener(TimerEvent.TIMER, this.Tick);
this.parent.removeChild(this);
this.OnComplete();
return;
};
if (this.Counter > 50){
Blur = (Blur + 0.5);
this.Logo.filters = [new BlurFilter(Blur, Blur)];
this.alpha = (this.alpha - 0.01);
};
}
private function FadeIn(_arg1:Event):void{
this.alpha = (this.alpha + 0.02);
if (this.alpha >= 1){
this.Ticker.removeEventListener(TimerEvent.TIMER, this.FadeIn);
this.Ticker.addEventListener(TimerEvent.TIMER, this.Tick);
};
}
}
}//package InFlashStudios
Section 161
//MochiDigits (mochi.as3.MochiDigits)
package mochi.as3 {
public final class MochiDigits {
private var Sibling:MochiDigits;
private var Fragment:Number;
private var Encoder:Number;
public function MochiDigits(_arg1:Number=0, _arg2:uint=0):void{
Encoder = 0;
setValue(_arg1, _arg2);
}
public function set value(_arg1:Number):void{
setValue(_arg1);
}
public function reencode():void{
var _local1:uint;
_local1 = int((2147483647 * Math.random()));
Fragment = (Fragment ^ (_local1 ^ Encoder));
Encoder = _local1;
}
public function toString():String{
var _local1:String;
_local1 = String.fromCharCode((Fragment ^ Encoder));
if (Sibling != null){
_local1 = (_local1 + Sibling.toString());
};
return (_local1);
}
public function get value():Number{
return (Number(this.toString()));
}
public function setValue(_arg1:Number=0, _arg2:uint=0):void{
var _local3:String;
_local3 = _arg1.toString();
var _temp1 = _arg2;
_arg2 = (_arg2 + 1);
Fragment = (_local3.charCodeAt(_temp1) ^ Encoder);
if (_arg2 < _local3.length){
Sibling = new MochiDigits(_arg1, _arg2);
} else {
Sibling = null;
};
reencode();
}
public function addValue(_arg1:Number):void{
value = (value + _arg1);
}
}
}//package mochi.as3
Section 162
//MochiScores (mochi.as3.MochiScores)
package mochi.as3 {
import flash.display.*;
import flash.text.*;
public class MochiScores {
private static var boardID:String;
public static var onErrorHandler:Object;
public static var onCloseHandler:Object;
public static function showLeaderboard(_arg1:Object=null):void{
var n:Number;
var options = _arg1;
if (options != null){
if (options.clip != null){
if ((options.clip is Sprite)){
MochiServices.setContainer(options.clip);
};
delete options.clip;
} else {
MochiServices.setContainer();
};
MochiServices.stayOnTop();
if (options.name != null){
if ((options.name is TextField)){
if (options.name.text.length > 0){
options.name = options.name.text;
};
};
};
if (options.score != null){
if ((options.score is TextField)){
if (options.score.text.length > 0){
options.score = options.score.text;
};
} else {
if ((options.score is MochiDigits)){
options.score = options.score.value;
};
};
n = Number(options.score);
if (isNaN(n)){
trace((("ERROR: Submitted score '" + options.score) + "' will be rejected, score is 'Not a Number'"));
} else {
if ((((n == Number.NEGATIVE_INFINITY)) || ((n == Number.POSITIVE_INFINITY)))){
trace((("ERROR: Submitted score '" + options.score) + "' will be rejected, score is an infinite"));
} else {
if (Math.floor(n) != n){
trace((("WARNING: Submitted score '" + options.score) + "' will be truncated"));
};
options.score = n;
};
};
};
if (options.onDisplay != null){
options.onDisplay();
} else {
if (MochiServices.clip != null){
if ((MochiServices.clip is MovieClip)){
MochiServices.clip.stop();
} else {
trace("Warning: Container is not a MovieClip, cannot call default onDisplay.");
};
};
};
} else {
options = {};
if ((MochiServices.clip is MovieClip)){
MochiServices.clip.stop();
} else {
trace("Warning: Container is not a MovieClip, cannot call default onDisplay.");
};
};
if (options.onClose != null){
onCloseHandler = options.onClose;
} else {
onCloseHandler = function ():void{
if ((MochiServices.clip is MovieClip)){
MochiServices.clip.play();
} else {
trace("Warning: Container is not a MovieClip, cannot call default onClose.");
};
};
};
if (options.onError != null){
onErrorHandler = options.onError;
} else {
onErrorHandler = null;
};
if (options.boardID == null){
if (MochiScores.boardID != null){
options.boardID = MochiScores.boardID;
};
};
trace("[MochiScores] NOTE: Security Sandbox Violation errors below are normal");
MochiServices.send("scores_showLeaderboard", {options:options}, null, onClose);
}
public static function closeLeaderboard():void{
MochiServices.send("scores_closeLeaderboard");
}
public static function getPlayerInfo(_arg1:Object, _arg2:Object=null):void{
MochiServices.send("scores_getPlayerInfo", null, _arg1, _arg2);
}
public static function requestList(_arg1:Object, _arg2:Object=null):void{
MochiServices.send("scores_requestList", null, _arg1, _arg2);
}
public static function scoresArrayToObjects(_arg1:Object):Object{
var _local2:Object;
var _local3:Number;
var _local4:Number;
var _local5:Object;
var _local6:Object;
var _local7:String;
var _local8:String;
_local2 = {};
for (_local7 in _arg1) {
if (typeof(_arg1[_local7]) == "object"){
if (((!((_arg1[_local7].cols == null))) && (!((_arg1[_local7].rows == null))))){
_local2[_local7] = [];
_local5 = _arg1[_local7];
_local4 = 0;
while (_local4 < _local5.rows.length) {
_local6 = {};
_local3 = 0;
while (_local3 < _local5.cols.length) {
_local6[_local5.cols[_local3]] = _local5.rows[_local4][_local3];
_local3++;
};
_local2[_local7].push(_local6);
_local4++;
};
} else {
_local2[_local7] = {};
for (_local8 in _arg1[_local7]) {
_local2[_local7][_local8] = _arg1[_local7][_local8];
};
};
} else {
_local2[_local7] = _arg1[_local7];
};
};
return (_local2);
}
public static function submit(_arg1:Number, _arg2:String, _arg3:Object=null, _arg4:Object=null):void{
_arg1 = Number(_arg1);
if (isNaN(_arg1)){
trace((("ERROR: Submitted score '" + String(_arg1)) + "' will be rejected, score is 'Not a Number'"));
} else {
if ((((_arg1 == Number.NEGATIVE_INFINITY)) || ((_arg1 == Number.POSITIVE_INFINITY)))){
trace((("ERROR: Submitted score '" + String(_arg1)) + "' will be rejected, score is an infinite"));
} else {
if (Math.floor(_arg1) != _arg1){
trace((("WARNING: Submitted score '" + String(_arg1)) + "' will be truncated"));
};
_arg1 = Number(_arg1);
};
};
MochiServices.send("scores_submit", {score:_arg1, name:_arg2}, _arg3, _arg4);
}
public static function onClose(_arg1:Object=null):void{
if (_arg1 != null){
if (_arg1.error != null){
if (_arg1.error == true){
if (onErrorHandler != null){
if (_arg1.errorCode == null){
_arg1.errorCode = "IOError";
};
onErrorHandler(_arg1.errorCode);
MochiServices.doClose();
return;
};
};
};
};
onCloseHandler();
MochiServices.doClose();
}
public static function setBoardID(_arg1:String):void{
MochiScores.boardID = _arg1;
MochiServices.send("scores_setBoardID", {boardID:_arg1});
}
}
}//package mochi.as3
Section 163
//MochiServices (mochi.as3.MochiServices)
package mochi.as3 {
import flash.display.*;
import flash.geom.*;
import flash.events.*;
import flash.utils.*;
import flash.net.*;
import flash.system.*;
public class MochiServices {
private static var _container:Object;
private static var _connected:Boolean = false;
private static var _swfVersion:String;
public static var netupAttempted:Boolean = false;
private static var _sendChannel:LocalConnection;
private static var _clip:MovieClip;
private static var _loader:Loader;
private static var _id:String;
private static var _listenChannel:LocalConnection;
public static var widget:Boolean = false;
private static var _timer:Timer;
private static var _sendChannelName:String;
private static var _connecting:Boolean = false;
public static var onError:Object;
private static var _listenChannelName:String = "__ms_";
private static var _servicesURL:String = "http://www.mochiads.com/static/lib/services/services.swf";
public static var netup:Boolean = true;
public static function isNetworkAvailable():Boolean{
return (!((Security.sandboxType == "localWithFile")));
}
public static function get connected():Boolean{
return (_connected);
}
private static function flush(_arg1:Boolean):void{
var _local2:Object;
var _local3:Object;
if (_clip != null){
if (_clip._queue != null){
while (_clip._queue.length > 0) {
_local2 = _clip._queue.shift();
_local3 = null;
if (_local2 != null){
if (_local2.callbackID != null){
_local3 = _clip._callbacks[_local2.callbackID];
};
delete _clip._callbacks[_local2.callbackID];
if (((_arg1) && (!((_local3 == null))))){
handleError(_local2.args, _local3.callbackObject, _local3.callbackMethod);
};
};
};
};
};
}
public static function send(_arg1:String, _arg2:Object=null, _arg3:Object=null, _arg4:Object=null):void{
if (_connected){
_sendChannel.send(_sendChannelName, "onReceive", {methodName:_arg1, args:_arg2, callbackID:_clip._nextcallbackID});
} else {
if ((((_clip == null)) || (!(_connecting)))){
onError("NotConnected");
handleError(_arg2, _arg3, _arg4);
flush(true);
return;
};
_clip._queue.push({methodName:_arg1, args:_arg2, callbackID:_clip._nextcallbackID});
};
if (_clip != null){
if (((!((_clip._callbacks == null))) && (!((_clip._nextcallbackID == null))))){
_clip._callbacks[_clip._nextcallbackID] = {callbackObject:_arg3, callbackMethod:_arg4};
_clip._nextcallbackID++;
};
};
}
private static function init(_arg1:String, _arg2:Object):void{
_id = _arg1;
if (_arg2 != null){
_container = _arg2;
loadCommunicator(_arg1, _container);
};
}
public static function get childClip():Object{
return (_clip);
}
private static function clickMovie(_arg1:String, _arg2:Function):MovieClip{
var _local3:Array;
var _local4:int;
var _local5:Array;
var _local6:Array;
var _local7:MovieClip;
var _local8:LocalConnection;
var _local9:String;
var _local10:ByteArray;
var _local11:ByteArray;
var _local12:uint;
var _local13:uint;
var _local14:Loader;
_local3 = [150, 21, 0, 7, 1, 0, 0, 0, 0, 98, 116, 110, 0, 7, 2, 0, 0, 0, 0, 116, 104, 105, 115, 0, 28, 150, 22, 0, 0, 99, 114, 101, 97, 116, 101, 69, 109, 112, 116, 121, 77, 111, 118, 105, 101, 67, 108, 105, 112, 0, 82, 135, 1, 0, 0, 23, 150, 13, 0, 4, 0, 0, 111, 110, 82, 101, 108, 101, 97, 115, 101, 0, 142, 8, 0, 0, 0, 0, 2, 42, 0, 114, 0, 150, 17, 0, 0, 32, 0, 7, 1, 0, 0, 0, 8, 0, 0, 115, 112, 108, 105, 116, 0, 82, 135, 1, 0, 1, 23, 150, 7, 0, 4, 1, 7, 0, 0, 0, 0, 78, 150, 8, 0, 0, 95, 98, 108, 97, 110, 107, 0, 154, 1, 0, 0, 150, 7, 0, 0, 99, 108, 105, 99, 107, 0, 150, 7, 0, 4, 1, 7, 1, 0, 0, 0, 78, 150, 27, 0, 7, 2, 0, 0, 0, 7, 0, 0, 0, 0, 0, 76, 111, 99, 97, 108, 67, 111, 110, 110, 101, 99, 116, 105, 111, 110, 0, 64, 150, 6, 0, 0, 115, 101, 110, 100, 0, 82, 79, 150, 15, 0, 4, 0, 0, 95, 97, 108, 112, 104, 97, 0, 7, 0, 0, 0, 0, 79, 150, 23, 0, 7, 0xFF, 0, 0xFF, 0, 7, 1, 0, 0, 0, 4, 0, 0, 98, 101, 103, 105, 110, 70, 105, 108, 108, 0, 82, 23, 150, 25, 0, 7, 0, 0, 0, 0, 7, 0, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 109, 111, 118, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 100, 0, 0, 0, 7, 0, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 100, 0, 0, 0, 7, 100, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 0, 0, 0, 0, 7, 100, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 0, 0, 0, 0, 7, 0, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 16, 0, 7, 0, 0, 0, 0, 4, 0, 0, 101, 110, 100, 70, 105, 108, 108, 0, 82, 23];
_local5 = [104, 0, 31, 64, 0, 7, 208, 0, 0, 12, 1, 0, 67, 2, 0xFF, 0xFF, 0xFF, 63, 3];
_local6 = [0, 64, 0, 0, 0];
_local7 = new MovieClip();
_local8 = new LocalConnection();
_local9 = ((("_click_" + Math.floor((Math.random() * 999999))) + "_") + Math.floor(new Date().getTime()));
_local8 = new LocalConnection();
_local7.lc = _local8;
_local7.click = _arg2;
_local8.client = _local7;
_local8.connect(_local9);
_local10 = new ByteArray();
_local11 = new ByteArray();
_local11.endian = Endian.LITTLE_ENDIAN;
_local11.writeShort(1);
_local11.writeUTFBytes(((_arg1 + " ") + _local9));
_local11.writeByte(0);
_local12 = ((_local3.length + _local11.length) + 4);
_local13 = (_local12 + 35);
_local10.endian = Endian.LITTLE_ENDIAN;
_local10.writeUTFBytes("FWS");
_local10.writeByte(8);
_local10.writeUnsignedInt(_local13);
for each (_local4 in _local5) {
_local10.writeByte(_local4);
};
_local10.writeUnsignedInt(_local12);
_local10.writeByte(136);
_local10.writeShort(_local11.length);
_local10.writeBytes(_local11);
for each (_local4 in _local3) {
_local10.writeByte(_local4);
};
for each (_local4 in _local6) {
_local10.writeByte(_local4);
};
_local14 = new Loader();
_local14.loadBytes(_local10);
_local7.addChild(_local14);
return (_local7);
}
public static function stayOnTop():void{
_container.addEventListener(Event.ENTER_FRAME, MochiServices.bringToTop, false, 0, true);
if (_clip != null){
_clip.visible = true;
};
}
public static function addLinkEvent(_arg1:String, _arg2:String, _arg3:DisplayObjectContainer, _arg4:Function=null):void{
var vars:Object;
var avm1Click:DisplayObject;
var s:String;
var i:Number;
var x:String;
var req:URLRequest;
var loader:Loader;
var setURL:Function;
var err:Function;
var complete:Function;
var url = _arg1;
var burl = _arg2;
var btn = _arg3;
var onClick = _arg4;
vars = new Object();
vars["mav"] = getVersion();
vars["swfv"] = "9";
vars["swfurl"] = btn.loaderInfo.loaderURL;
vars["fv"] = Capabilities.version;
vars["os"] = Capabilities.os;
vars["lang"] = Capabilities.language;
vars["scres"] = ((Capabilities.screenResolutionX + "x") + Capabilities.screenResolutionY);
s = "?";
i = 0;
for (x in vars) {
if (i != 0){
s = (s + "&");
};
i = (i + 1);
s = (((s + x) + "=") + escape(vars[x]));
};
req = new URLRequest("http://x.mochiads.com/linkping.swf");
loader = new Loader();
setURL = function (_arg1:String):void{
var _local2:Rectangle;
if (avm1Click){
btn.removeChild(avm1Click);
};
avm1Click = clickMovie(_arg1, onClick);
_local2 = btn.getBounds(btn);
btn.addChild(avm1Click);
avm1Click.x = _local2.x;
avm1Click.y = _local2.y;
avm1Click.scaleX = (0.01 * _local2.width);
avm1Click.scaleY = (0.01 * _local2.height);
};
err = function (_arg1:Object):void{
netup = false;
_arg1.target.removeEventListener(_arg1.type, arguments.callee);
setURL(burl);
};
complete = function (_arg1:Object):void{
_arg1.target.removeEventListener(_arg1.type, arguments.callee);
};
if (netup){
setURL((url + s));
} else {
setURL(burl);
};
if (!((netupAttempted) || (_connected))){
netupAttempted = true;
loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, err);
loader.contentLoaderInfo.addEventListener(Event.COMPLETE, complete);
loader.load(req);
};
}
public static function disconnect():void{
if (((_connected) || (_connecting))){
if (_clip != null){
if (_clip.parent != null){
if ((_clip.parent is Sprite)){
Sprite(_clip.parent).removeChild(_clip);
_clip = null;
};
};
};
_connecting = (_connected = false);
flush(true);
try {
_listenChannel.close();
} catch(error:Error) {
};
};
if (_timer != null){
try {
_timer.stop();
} catch(error:Error) {
};
};
}
public static function allowDomains(_arg1:String):String{
var _local2:String;
if (Security.sandboxType != "application"){
Security.allowDomain("*");
Security.allowInsecureDomain("*");
};
if (_arg1.indexOf("http://") != -1){
_local2 = _arg1.split("/")[2].split(":")[0];
if (Security.sandboxType != "application"){
Security.allowDomain(_local2);
Security.allowInsecureDomain(_local2);
};
};
return (_local2);
}
public static function getVersion():String{
return ("3.0");
}
public static function doClose():void{
_container.removeEventListener(Event.ENTER_FRAME, MochiServices.bringToTop);
if (_clip.parent != null){
Sprite(_clip.parent).removeChild(_clip);
};
}
private static function onStatus(_arg1:StatusEvent):void{
switch (_arg1.level){
case "error":
_connected = false;
_listenChannel.connect(_listenChannelName);
break;
};
}
public static function get id():String{
return (_id);
}
private static function urlOptions(_arg1:Object):Object{
var _local2:Object;
var _local3:String;
var _local4:Array;
var _local5:Number;
var _local6:Array;
_local2 = {};
_local3 = _arg1.loaderInfo.parameters.mochiad_options;
if (_local3){
_local4 = _local3.split("&");
_local5 = 0;
while (_local5 < _local4.length) {
_local6 = _local4[_local5].split("=");
_local2[unescape(_local6[0])] = unescape(_local6[1]);
_local5++;
};
};
return (_local2);
}
public static function setContainer(_arg1:Object=null, _arg2:Boolean=true):void{
if (_arg1 != null){
if ((_arg1 is Sprite)){
_container = _arg1;
};
};
if (_arg2){
if ((_container is Sprite)){
Sprite(_container).addChild(_clip);
};
};
}
private static function handleError(_arg1:Object, _arg2:Object, _arg3:Object):void{
var args = _arg1;
var callbackObject = _arg2;
var callbackMethod = _arg3;
if (args != null){
if (args.onError != null){
args.onError.apply(null, ["NotConnected"]);
};
if (((!((args.options == null))) && (!((args.options.onError == null))))){
args.options.onError.apply(null, ["NotConnected"]);
};
};
if (callbackMethod != null){
args = {};
args.error = true;
args.errorCode = "NotConnected";
if (((!((callbackObject == null))) && ((callbackMethod is String)))){
try {
var _local5 = callbackObject;
_local5[callbackMethod](args);
} catch(error:Error) {
};
} else {
if (callbackMethod != null){
try {
callbackMethod.apply(args);
} catch(error:Error) {
};
};
};
};
}
private static function initComChannels():void{
if (!_connected){
_sendChannel.addEventListener(StatusEvent.STATUS, MochiServices.onStatus);
_sendChannel.send(_sendChannelName, "onReceive", {methodName:"handshakeDone"});
_sendChannel.send(_sendChannelName, "onReceive", {methodName:"registerGame", id:_id, clip:_container, version:getVersion(), parentURL:_container.loaderInfo.loaderURL});
_listenChannel.addEventListener(StatusEvent.STATUS, MochiServices.onStatus);
_clip.onReceive = function (_arg1:Object):void{
var cb:String;
var cblst:Object;
var method:*;
var methodName:String;
var obj:Object;
var pkg = _arg1;
cb = pkg.callbackID;
cblst = this.client._callbacks[cb];
if (!cblst){
return;
};
method = cblst.callbackMethod;
methodName = "";
obj = cblst.callbackObject;
if (((obj) && ((typeof(method) == "string")))){
methodName = method;
if (obj[method] != null){
method = obj[method];
} else {
trace((("Error: Method " + method) + " does not exist."));
};
};
if (method != undefined){
try {
method.apply(obj, pkg.args);
} catch(error:Error) {
trace(((("Error invoking callback method '" + methodName) + "': ") + error.toString()));
};
} else {
if (obj != null){
try {
obj(pkg.args);
} catch(error:Error) {
trace(("Error invoking method on object: " + error.toString()));
};
};
};
delete this.client._callbacks[cb];
};
_clip.onError = function ():void{
MochiServices.onError("IOError");
};
trace("connected!");
_connecting = false;
_connected = true;
while (_clip._queue.length > 0) {
_sendChannel.send(_sendChannelName, "onReceive", _clip._queue.shift());
};
};
}
private static function listen():void{
_listenChannel = new LocalConnection();
_listenChannel.client = _clip;
_clip.handshake = function (_arg1:Object):void{
MochiServices.comChannelName = _arg1.newChannel;
};
_listenChannel.allowDomain("*", "localhost");
_listenChannel.allowInsecureDomain("*", "localhost");
_listenChannel.connect(_listenChannelName);
trace("Waiting for MochiAds services to connect...");
}
public static function set comChannelName(_arg1:String):void{
if (_arg1 != null){
if (_arg1.length > 3){
_sendChannelName = (_arg1 + "_fromgame");
initComChannels();
};
};
}
private static function loadCommunicator(_arg1:String, _arg2:Object):MovieClip{
var clipname:String;
var f:Function;
var req:URLRequest;
var vars:URLVariables;
var id = _arg1;
var clip = _arg2;
clipname = ("_mochiservices_com_" + id);
if (_clip != null){
return (_clip);
};
if (!MochiServices.isNetworkAvailable()){
return (null);
};
if (urlOptions(clip).servicesURL != undefined){
_servicesURL = urlOptions(clip).servicesURL;
};
MochiServices.allowDomains(_servicesURL);
_clip = createEmptyMovieClip(clip, clipname, 10336, false);
_loader = new Loader();
f = function (_arg1:Object):void{
_clip._mochiad_ctr_failed = true;
trace("MochiServices could not load.");
MochiServices.disconnect();
MochiServices.onError("IOError");
};
_listenChannelName = (_listenChannelName + ((Math.floor(new Date().getTime()) + "_") + Math.floor((Math.random() * 99999))));
_loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, f);
req = new URLRequest(_servicesURL);
vars = new URLVariables();
vars.listenLC = _listenChannelName;
vars.mochiad_options = clip.loaderInfo.parameters.mochiad_options;
if (widget){
vars.widget = true;
};
req.data = vars;
listen();
_loader.load(req);
_clip.addChild(_loader);
_clip._mochiservices_com = _loader;
_sendChannel = new LocalConnection();
_clip._queue = [];
_clip._nextcallbackID = 0;
_clip._callbacks = {};
_timer = new Timer(10000, 1);
_timer.addEventListener(TimerEvent.TIMER, connectWait);
_timer.start();
return (_clip);
}
public static function get clip():Object{
return (_container);
}
public static function bringToTop(_arg1:Event):void{
var e = _arg1;
if (MochiServices.clip != null){
if (MochiServices.childClip != null){
try {
if (MochiServices.clip.numChildren > 1){
MochiServices.clip.setChildIndex(MochiServices.childClip, (MochiServices.clip.numChildren - 1));
};
} catch(errorObject:Error) {
trace("Warning: Depth sort error.");
_container.removeEventListener(Event.ENTER_FRAME, MochiServices.bringToTop);
};
};
};
}
public static function connect(_arg1:String, _arg2:Object, _arg3:Object=null):void{
var id = _arg1;
var clip = _arg2;
var onError = _arg3;
if ((clip is DisplayObject)){
if (((!(_connected)) && ((_clip == null)))){
trace("MochiServices Connecting...");
_connecting = true;
init(id, clip);
};
} else {
trace("Error, MochiServices requires a Sprite, Movieclip or instance of the stage.");
};
if (onError != null){
MochiServices.onError = onError;
} else {
if (MochiServices.onError == null){
MochiServices.onError = function (_arg1:String):void{
trace(_arg1);
};
};
};
}
public static function createEmptyMovieClip(_arg1:Object, _arg2:String, _arg3:Number, _arg4:Boolean=true):MovieClip{
var mc:MovieClip;
var parent = _arg1;
var name = _arg2;
var depth = _arg3;
var doAdd = _arg4;
mc = new MovieClip();
if (doAdd){
if (((false) && (depth))){
parent.addChildAt(mc, depth);
} else {
parent.addChild(mc);
};
};
try {
parent[name] = mc;
} catch(e:Error) {
throw (new Error("MochiServices requires a clip that is an instance of a dynamic class. If your class extends Sprite or MovieClip, you must make it dynamic."));
};
mc["_name"] = name;
return (mc);
}
public static function connectWait(_arg1:TimerEvent):void{
if (!_connected){
_clip._mochiad_ctr_failed = true;
trace("MochiServices could not load. (timeout)");
MochiServices.disconnect();
MochiServices.onError("IOError");
};
}
}
}//package mochi.as3
Section 164
//CustomMetrics (SWFStats.CustomMetrics)
package SWFStats {
import flash.events.*;
import flash.net.*;
public class CustomMetrics {
public static const EASY:int = 3;
public static const HARD:int = 5;
public static const ENGLISH:int = 1;
public static const SPANISH:int = 2;
public static const MEDIUM:int = 4;
private static function ErrorHandler(_arg1:IOErrorEvent):void{
Tracker.SourceUrl = null;
}
public static function Log(_arg1:int):void{
var _local2:URLLoader;
if (Tracker.SourceUrl == null){
return;
};
_local2 = new URLLoader();
_local2.addEventListener(IOErrorEvent.IO_ERROR, ErrorHandler);
_local2.load(new URLRequest(((((((("http://ping.swfstats.com/custom.aspx?guid=" + SWF.GUID) + "&swfid=") + SWF.SWFID) + "&metricid=") + _arg1) + "&") + Tracker.Random)));
}
}
}//package SWFStats
Section 165
//HighScores (SWFStats.HighScores)
package SWFStats {
import flash.events.*;
import flash.net.*;
public class HighScores {
public static const EASY:int = 1;
public static const HARD:int = 3;
public static const MEDIUM:int = 2;
private static var CallBack:Function;
private static var DataLoader:URLLoader;
private static function DataLoaded(_arg1:Event):void{
var _local2:XML;
var _local3:int;
var _local4:XMLList;
var _local5:Array;
var _local6:XML;
var _local7:Score;
_local2 = XML(DataLoader.data);
_local3 = 0;
_local4 = _local2.entry;
_local5 = new Array();
for each (_local6 in _local4) {
_local7 = new Score();
_local7.Name = _local6.name;
_local7.Points = _local6.score;
_local7.SDate = new Date(_local6.sdate);
_local7.Website = _local6.website;
_local7.Rank = (_local5.length + 1);
_local5.push(_local7);
};
CallBack(_local5);
}
public static function Submit(_arg1:String, _arg2:int, _arg3:int):void{
var _local4:URLLoader;
if (Tracker.SourceUrl == null){
return;
};
_local4 = new URLLoader();
_local4.addEventListener(IOErrorEvent.IO_ERROR, ErrorHandler);
_local4.load(new URLRequest(((((((((((((((("http://ping.swfstats.com/scores/save.aspx?guid=" + SWF.GUID) + "&swfid=") + SWF.SWFID) + "&url=") + Tracker.SourceUrl) + "&groupid=") + _arg3) + "&name=") + _arg1) + "&score=") + _arg2) + "&auth=") + MD5.calcMD5((Tracker.SourceUrl + _arg2.toString()))) + "&r=") + Math.random())));
trace(((((((((((((((("http://ping.swfstats.com/scores/save.aspx?guid=" + SWF.GUID) + "&swfid=") + SWF.SWFID) + "&url=") + Tracker.SourceUrl) + "&groupid=") + _arg3) + "&name=") + _arg1) + "&score=") + _arg2) + "&auth=") + MD5.calcMD5((Tracker.SourceUrl + _arg2.toString()))) + "&r=") + Math.random()));
}
private static function ErrorHandler(_arg1:IOErrorEvent):void{
}
public static function List(_arg1:Boolean, _arg2:int, _arg3:Function):void{
if (Tracker.SourceUrl == null){
_arg3(new Array());
};
CallBack = _arg3;
DataLoader = new URLLoader();
DataLoader.addEventListener(Event.COMPLETE, DataLoaded);
DataLoader.addEventListener(IOErrorEvent.IO_ERROR, ErrorHandler);
DataLoader.load(new URLRequest(((((((((("http://ping.swfstats.com/scores/get.aspx?guid=" + SWF.GUID) + "&swfid=") + SWF.SWFID) + "&url=") + (_arg1) ? "global" : Tracker.SourceUrl) + "&groupid=") + _arg2) + "&") + Math.random())));
}
}
}//package SWFStats
Section 166
//MD5 (SWFStats.MD5)
package SWFStats {
public class MD5 {
private static var hex_chr = "0123456789abcdef";
private static function ff(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7){
return (cmn(bitOR(bitAND(_arg2, _arg3), bitAND(~(_arg2), _arg4)), _arg1, _arg2, _arg5, _arg6, _arg7));
}
public static function calcMD5(_arg1){
var _local2:*;
var _local3:*;
var _local4:*;
var _local5:*;
var _local6:*;
var _local7:*;
var _local8:*;
var _local9:*;
var _local10:*;
var _local11:*;
var _local12:*;
_local2 = str2blks_MD5(_arg1);
_local3 = 1732584193;
_local4 = -271733879;
_local5 = -1732584194;
_local6 = 271733878;
_local8 = 0;
while (_local8 < _local2.length) {
_local9 = _local3;
_local10 = _local4;
_local11 = _local5;
_local12 = _local6;
_local7 = 0;
_local3 = ff(_local3, _local4, _local5, _local6, _local2[(_local8 + 0)], 7, -680876936);
_local6 = ff(_local6, _local3, _local4, _local5, _local2[(_local8 + 1)], 12, -389564586);
_local5 = ff(_local5, _local6, _local3, _local4, _local2[(_local8 + 2)], 17, 606105819);
_local4 = ff(_local4, _local5, _local6, _local3, _local2[(_local8 + 3)], 22, -1044525330);
_local3 = ff(_local3, _local4, _local5, _local6, _local2[(_local8 + 4)], 7, -176418897);
_local6 = ff(_local6, _local3, _local4, _local5, _local2[(_local8 + 5)], 12, 1200080426);
_local5 = ff(_local5, _local6, _local3, _local4, _local2[(_local8 + 6)], 17, -1473231341);
_local4 = ff(_local4, _local5, _local6, _local3, _local2[(_local8 + 7)], 22, -45705983);
_local3 = ff(_local3, _local4, _local5, _local6, _local2[(_local8 + 8)], 7, 1770035416);
_local6 = ff(_local6, _local3, _local4, _local5, _local2[(_local8 + 9)], 12, -1958414417);
_local5 = ff(_local5, _local6, _local3, _local4, _local2[(_local8 + 10)], 17, -42063);
_local4 = ff(_local4, _local5, _local6, _local3, _local2[(_local8 + 11)], 22, -1990404162);
_local3 = ff(_local3, _local4, _local5, _local6, _local2[(_local8 + 12)], 7, 1804603682);
_local6 = ff(_local6, _local3, _local4, _local5, _local2[(_local8 + 13)], 12, -40341101);
_local5 = ff(_local5, _local6, _local3, _local4, _local2[(_local8 + 14)], 17, -1502002290);
_local4 = ff(_local4, _local5, _local6, _local3, _local2[(_local8 + 15)], 22, 1236535329);
_local3 = gg(_local3, _local4, _local5, _local6, _local2[(_local8 + 1)], 5, -165796510);
_local6 = gg(_local6, _local3, _local4, _local5, _local2[(_local8 + 6)], 9, -1069501632);
_local5 = gg(_local5, _local6, _local3, _local4, _local2[(_local8 + 11)], 14, 643717713);
_local4 = gg(_local4, _local5, _local6, _local3, _local2[(_local8 + 0)], 20, -373897302);
_local3 = gg(_local3, _local4, _local5, _local6, _local2[(_local8 + 5)], 5, -701558691);
_local6 = gg(_local6, _local3, _local4, _local5, _local2[(_local8 + 10)], 9, 38016083);
_local5 = gg(_local5, _local6, _local3, _local4, _local2[(_local8 + 15)], 14, -660478335);
_local4 = gg(_local4, _local5, _local6, _local3, _local2[(_local8 + 4)], 20, -405537848);
_local3 = gg(_local3, _local4, _local5, _local6, _local2[(_local8 + 9)], 5, 568446438);
_local6 = gg(_local6, _local3, _local4, _local5, _local2[(_local8 + 14)], 9, -1019803690);
_local5 = gg(_local5, _local6, _local3, _local4, _local2[(_local8 + 3)], 14, -187363961);
_local4 = gg(_local4, _local5, _local6, _local3, _local2[(_local8 + 8)], 20, 1163531501);
_local3 = gg(_local3, _local4, _local5, _local6, _local2[(_local8 + 13)], 5, -1444681467);
_local6 = gg(_local6, _local3, _local4, _local5, _local2[(_local8 + 2)], 9, -51403784);
_local5 = gg(_local5, _local6, _local3, _local4, _local2[(_local8 + 7)], 14, 1735328473);
_local4 = gg(_local4, _local5, _local6, _local3, _local2[(_local8 + 12)], 20, -1926607734);
_local3 = hh(_local3, _local4, _local5, _local6, _local2[(_local8 + 5)], 4, -378558);
_local6 = hh(_local6, _local3, _local4, _local5, _local2[(_local8 + 8)], 11, -2022574463);
_local5 = hh(_local5, _local6, _local3, _local4, _local2[(_local8 + 11)], 16, 1839030562);
_local4 = hh(_local4, _local5, _local6, _local3, _local2[(_local8 + 14)], 23, -35309556);
_local3 = hh(_local3, _local4, _local5, _local6, _local2[(_local8 + 1)], 4, -1530992060);
_local6 = hh(_local6, _local3, _local4, _local5, _local2[(_local8 + 4)], 11, 1272893353);
_local5 = hh(_local5, _local6, _local3, _local4, _local2[(_local8 + 7)], 16, -155497632);
_local4 = hh(_local4, _local5, _local6, _local3, _local2[(_local8 + 10)], 23, -1094730640);
_local3 = hh(_local3, _local4, _local5, _local6, _local2[(_local8 + 13)], 4, 681279174);
_local6 = hh(_local6, _local3, _local4, _local5, _local2[(_local8 + 0)], 11, -358537222);
_local5 = hh(_local5, _local6, _local3, _local4, _local2[(_local8 + 3)], 16, -722521979);
_local4 = hh(_local4, _local5, _local6, _local3, _local2[(_local8 + 6)], 23, 76029189);
_local3 = hh(_local3, _local4, _local5, _local6, _local2[(_local8 + 9)], 4, -640364487);
_local6 = hh(_local6, _local3, _local4, _local5, _local2[(_local8 + 12)], 11, -421815835);
_local5 = hh(_local5, _local6, _local3, _local4, _local2[(_local8 + 15)], 16, 530742520);
_local4 = hh(_local4, _local5, _local6, _local3, _local2[(_local8 + 2)], 23, -995338651);
_local3 = ii(_local3, _local4, _local5, _local6, _local2[(_local8 + 0)], 6, -198630844);
_local6 = ii(_local6, _local3, _local4, _local5, _local2[(_local8 + 7)], 10, 1126891415);
_local5 = ii(_local5, _local6, _local3, _local4, _local2[(_local8 + 14)], 15, -1416354905);
_local4 = ii(_local4, _local5, _local6, _local3, _local2[(_local8 + 5)], 21, -57434055);
_local3 = ii(_local3, _local4, _local5, _local6, _local2[(_local8 + 12)], 6, 1700485571);
_local6 = ii(_local6, _local3, _local4, _local5, _local2[(_local8 + 3)], 10, -1894986606);
_local5 = ii(_local5, _local6, _local3, _local4, _local2[(_local8 + 10)], 15, -1051523);
_local4 = ii(_local4, _local5, _local6, _local3, _local2[(_local8 + 1)], 21, -2054922799);
_local3 = ii(_local3, _local4, _local5, _local6, _local2[(_local8 + 8)], 6, 1873313359);
_local6 = ii(_local6, _local3, _local4, _local5, _local2[(_local8 + 15)], 10, -30611744);
_local5 = ii(_local5, _local6, _local3, _local4, _local2[(_local8 + 6)], 15, -1560198380);
_local4 = ii(_local4, _local5, _local6, _local3, _local2[(_local8 + 13)], 21, 1309151649);
_local3 = ii(_local3, _local4, _local5, _local6, _local2[(_local8 + 4)], 6, -145523070);
_local6 = ii(_local6, _local3, _local4, _local5, _local2[(_local8 + 11)], 10, -1120210379);
_local5 = ii(_local5, _local6, _local3, _local4, _local2[(_local8 + 2)], 15, 718787259);
_local4 = ii(_local4, _local5, _local6, _local3, _local2[(_local8 + 9)], 21, -343485551);
_local3 = addme(_local3, _local9);
_local4 = addme(_local4, _local10);
_local5 = addme(_local5, _local11);
_local6 = addme(_local6, _local12);
_local8 = (_local8 + 16);
};
return ((((rhex(_local3) + rhex(_local4)) + rhex(_local5)) + rhex(_local6)));
}
private static function cmn(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6){
return (addme(rol(addme(addme(_arg2, _arg1), addme(_arg4, _arg6)), _arg5), _arg3));
}
private static function ii(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7){
return (cmn(bitXOR(_arg3, bitOR(_arg2, ~(_arg4))), _arg1, _arg2, _arg5, _arg6, _arg7));
}
private static function gg(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7){
return (cmn(bitOR(bitAND(_arg2, _arg4), bitAND(_arg3, ~(_arg4))), _arg1, _arg2, _arg5, _arg6, _arg7));
}
private static function addme(_arg1, _arg2){
var _local3:*;
var _local4:*;
_local3 = ((_arg1 & 0xFFFF) + (_arg2 & 0xFFFF));
_local4 = (((_arg1 >> 16) + (_arg2 >> 16)) + (_local3 >> 16));
return (((_local4 << 16) | (_local3 & 0xFFFF)));
}
private static function bitAND(_arg1, _arg2){
var _local3:*;
var _local4:*;
_local3 = ((_arg1 & 1) & (_arg2 & 1));
_local4 = ((_arg1 >>> 1) & (_arg2 >>> 1));
return (((_local4 << 1) | _local3));
}
private static function hh(_arg1, _arg2, _arg3, _arg4, _arg5, _arg6, _arg7){
return (cmn(bitXOR(bitXOR(_arg2, _arg3), _arg4), _arg1, _arg2, _arg5, _arg6, _arg7));
}
private static function bitXOR(_arg1, _arg2){
var _local3:*;
var _local4:*;
_local3 = ((_arg1 & 1) ^ (_arg2 & 1));
_local4 = ((_arg1 >>> 1) ^ (_arg2 >>> 1));
return (((_local4 << 1) | _local3));
}
private static function rol(_arg1, _arg2){
return (((_arg1 << _arg2) | (_arg1 >>> (32 - _arg2))));
}
private static function bitOR(_arg1, _arg2){
var _local3:*;
var _local4:*;
_local3 = ((_arg1 & 1) | (_arg2 & 1));
_local4 = ((_arg1 >>> 1) | (_arg2 >>> 1));
return (((_local4 << 1) | _local3));
}
private static function rhex(_arg1){
var _local2:*;
var _local3:*;
_local2 = "";
_local3 = 0;
while (_local3 <= 3) {
_local2 = (_local2 + (hex_chr.charAt(((_arg1 >> ((_local3 * 8) + 4)) & 15)) + hex_chr.charAt(((_arg1 >> (_local3 * 8)) & 15))));
_local3++;
};
return (_local2);
}
protected static function str2blks_MD5(_arg1){
var _local2:*;
var _local3:*;
var _local4:*;
var _local5:*;
_local2 = (((_arg1.length + 8) >> 6) + 1);
_local3 = new Array((_local2 * 16));
_local4 = 0;
while (_local4 < (_local2 * 16)) {
_local3[_local4] = 0;
_local4++;
};
_local4 = 0;
while (_local4 < _arg1.length) {
_local3[(_local4 >> 2)] = (_local3[(_local4 >> 2)] | (_arg1.charCodeAt(_local4) << ((((_arg1.length * 8) + _local4) % 4) * 8)));
_local4++;
};
_local3[(_local4 >> 2)] = (_local3[(_local4 >> 2)] | (128 << ((((_arg1.length * 8) + _local4) % 4) * 8)));
_local5 = (_arg1.length * 8);
_local3[((_local2 * 16) - 2)] = (_local5 & 0xFF);
_local3[((_local2 * 16) - 2)] = (_local3[((_local2 * 16) - 2)] | (((_local5 >>> 8) & 0xFF) << 8));
_local3[((_local2 * 16) - 2)] = (_local3[((_local2 * 16) - 2)] | (((_local5 >>> 16) & 0xFF) << 16));
_local3[((_local2 * 16) - 2)] = (_local3[((_local2 * 16) - 2)] | (((_local5 >>> 24) & 0xFF) << 24));
return (_local3);
}
}
}//package SWFStats
Section 167
//Score (SWFStats.Score)
package SWFStats {
public class Score {
public var SDate:Date;
public var Points:int;
public var Name:String;
public var Rank:int;
public var Website:String;
}
}//package SWFStats
Section 168
//SWF (SWFStats.SWF)
package SWFStats {
public class SWF {
public static const GUID:String = "afba3376-e784-42cf-a1c4-7ab121c2155d";
public static const SWFID:int = 7;
}
}//package SWFStats
Section 169
//Tracker (SWFStats.Tracker)
package SWFStats {
import flash.events.*;
import flash.utils.*;
import flash.net.*;
import flash.system.*;
import flash.external.*;
public class Tracker {
private static const Ping:Timer = new Timer(30000);
public static const Random:Number = Math.random();
public static var SourceUrl:String;
public static function LogView(_arg1:String):void{
var sendaction:URLLoader;
var defaulturl = _arg1;
SourceUrl = GetUrl(defaulturl);
if (SourceUrl == null){
return;
};
try {
Security.loadPolicyFile("http://ping.swfstats.com/crossdomain.xml");
} catch(s:Error) {
SourceUrl = null;
return;
};
sendaction = new URLLoader();
sendaction.addEventListener(IOErrorEvent.IO_ERROR, ErrorHandler);
sendaction.load(new URLRequest(((((((("http://ping.swfstats.com/init.aspx?guid=" + SWF.GUID) + "&swfid=") + SWF.SWFID) + "&url=") + SourceUrl) + "&") + Random)));
Ping.addEventListener(TimerEvent.TIMER, KeepAlive);
}
private static function GetUrl(_arg1:String):String{
var url:String;
var defaulturl = _arg1;
try {
url = String(ExternalInterface.call("window.location.href.toString"));
} catch(s:Error) {
url = ((defaulturl)!=null) ? defaulturl : "Unknown";
};
return (((url)!="null") ? url : "");
}
private static function KeepAlive(_arg1:Event):void{
var _local2:URLLoader;
if (SourceUrl == null){
return;
};
_local2 = new URLLoader();
_local2.addEventListener(IOErrorEvent.IO_ERROR, ErrorHandler);
_local2.load(new URLRequest(((((((("http://ping.swfstats.com/ping.aspx?guid=" + SWF.GUID) + "&swfid=") + SWF.SWFID) + "&url=") + SourceUrl) + "&") + Random)));
}
private static function ErrorHandler(_arg1:IOErrorEvent):void{
SourceUrl = null;
}
public static function LogPlay():void{
var _local1:URLLoader;
if (SourceUrl == null){
return;
};
_local1 = new URLLoader();
_local1.addEventListener(IOErrorEvent.IO_ERROR, ErrorHandler);
_local1.load(new URLRequest(((((((("http://ping.swfstats.com/play.aspx?guid=" + SWF.GUID) + "&swfid=") + SWF.SWFID) + "&url=") + SourceUrl) + "&") + Random)));
}
}
}//package SWFStats
Section 170
//clip_sd88detincelle_29 (thehorde2_fla.clip_sd88detincelle_29)
package thehorde2_fla {
import flash.display.*;
public dynamic class clip_sd88detincelle_29 extends MovieClip {
public function clip_sd88detincelle_29(){
addFrameScript(13, frame14);
}
function frame14(){
stop();
}
}
}//package thehorde2_fla
Section 171
//freeinternetgames_28 (thehorde2_fla.freeinternetgames_28)
package thehorde2_fla {
import flash.display.*;
public dynamic class freeinternetgames_28 extends MovieClip {
public function freeinternetgames_28(){
addFrameScript(59, frame60);
}
function frame60(){
stop();
}
}
}//package thehorde2_fla
Section 172
//Building (TowerDefence.Buildings.Building)
package TowerDefence.Buildings {
import TowerDefence.*;
import flash.display.*;
import flash.media.*;
import flash.geom.*;
import Assets.Towers.*;
public class Building {
public var Upgrading:Boolean;
public var Config:BuildingConfig;
public var Highlight:Boolean;
public var TotalSpent:int;
private var ClickZone:ClickZone;
public var Image:BitmapData;
public var Location:SimplePoint;
public var GridLocation:SimplePoint;
private var ClickArea:SimpleRectangle;
private static var RelativeLocation:Point = new Point();
private static var Hovering:Boolean;
private static var CurrentBuildingLocation:SimplePoint;
private static var CurrentBuildingConfig:BuildingConfig;
private static var MapRectangle:Rectangle;
private static var UpgradeComplete:Sound;
private static var ViewingBuilding:Building;
public static var Container:Array = new Array();
private static var LowGraphicsMode:Boolean;
private static var CurrentBuilding:Building;
private static var MouseLocation:SimplePoint;
private static var BuildingPlacement:Sound;
private static var GridLocation:SimplePoint;
private static var Pool:Array = new Array();
private static var OnClickArea:Boolean;
public function Building(){
Location = new SimplePoint();
GridLocation = new SimplePoint();
ClickArea = new SimpleRectangle(0, 0, 80, 80);
super();
}
private static function ShowBuilding(_arg1:Building):void{
Game.MainBar.SetBuildingInfo(_arg1);
}
public static function Create(_arg1:BuildingConfig):void{
var building:Building;
var x:int;
var y:int;
var config = _arg1;
GridLocation = Game.GridLocation;
building = GetInstance();
building.Config = config;
building.Location.X = (GridLocation.X * 40);
building.Location.Y = ((GridLocation.Y * 40) - (config.Image.height - 80));
building.GridLocation.X = GridLocation.X;
building.GridLocation.Y = GridLocation.Y;
building.TotalSpent = config.Price;
building.Image = config.Image;
building.Upgrading = false;
building.Highlight = false;
building.ClickArea.X = building.Location.X;
building.ClickArea.Y = (building.Location.Y + (config.Image.height - 80));
building.ClickZone = ClickZone.Create(building.ClickArea, function (){
ShowBuilding(building);
});
Container.push(building);
x = GridLocation.X;
while (x < (GridLocation.X + building.Config.Width)) {
y = GridLocation.Y;
while (y < (GridLocation.Y + building.Config.Height)) {
Game.Level.Buildable[y][x] = false;
y = (y + 1);
};
x = (x + 1);
};
SoundManager.PlaySound(BuildingPlacement);
FadingText.Create(("-" + building.TotalSpent), (building.Location.X + 30), (building.Location.Y + 30));
}
public static function RemoveAll():void{
var _local1:int;
_local1 = (Container.length - 1);
while (_local1 > -1) {
Remove(Container[_local1]);
_local1--;
};
}
public static function Tick(_arg1:BitmapData):void{
var _local2:int;
if (Container.length == 0){
return;
};
Hovering = false;
MapRectangle = Game.MapRectangle;
MouseLocation = Game.MouseLocation;
ViewingBuilding = Game.ViewingBuilding;
LowGraphicsMode = Game.LowGraphicsMode;
OnClickArea = false;
_local2 = (Container.length - 1);
while (_local2 > -1) {
CurrentBuilding = Container[_local2];
CurrentBuildingConfig = CurrentBuilding.Config;
CurrentBuildingLocation = CurrentBuilding.Location;
if (!Hovering){
OnClickArea = SimpleRectangle.ContainsPoint(CurrentBuilding.ClickZone.Zone, MouseLocation);
if (((OnClickArea) || ((CurrentBuilding == ViewingBuilding)))){
Game.HandCursor = OnClickArea;
Hovering = true;
};
};
RelativeLocation.x = (CurrentBuildingLocation.X - MapRectangle.x);
RelativeLocation.y = (CurrentBuildingLocation.Y - MapRectangle.y);
LayeredElement.Create(CurrentBuilding.Image, RelativeLocation, CurrentBuilding.GridLocation.Y);
_local2--;
};
}
private static function Remove(_arg1:Building):void{
var _local2:int;
var _local3:int;
Container.splice(Container.indexOf(_arg1), 1);
ClickZone.Remove(_arg1.ClickZone);
Pool.push(_arg1);
_local2 = Game.GridLocation.X;
while (_local2 < (Game.GridLocation.X + _arg1.Config.Width)) {
_local3 = Game.GridLocation.Y;
while (_local3 < (Game.GridLocation.Y + _arg1.Config.Height)) {
Game.Level.Buildable[_local3][_local2] = true;
_local3++;
};
_local2++;
};
if (Game.ViewingBuilding == _arg1){
Game.ViewingBuilding = null;
};
}
private static function GetInstance():Building{
if (Pool.length > 0){
return (Pool.pop());
};
return (new (Building));
}
public static function Init():void{
UpgradeComplete = new UpgradeComplete();
BuildingPlacement = new BuildingPlacement();
}
}
}//package TowerDefence.Buildings
Section 173
//BuildingConfig (TowerDefence.Buildings.BuildingConfig)
package TowerDefence.Buildings {
import flash.display.*;
import flash.geom.*;
import Assets.Buildings.*;
public class BuildingConfig {
public var Width:int;
public var Price:int;
public var Thumbnail:BitmapData;
public var Height:int;
public var Image:BitmapData;
public var Description:String;
public var Title:String;
public static const Workshop:BuildingConfig = new (BuildingConfig);
;
private static const ZeroPoint:Point = new Point(0, 0);
public static const Laboratory:BuildingConfig = new (BuildingConfig);
;
private static const SliceRectangle:Rectangle = new Rectangle();
private static var Slice:BitmapData;
private static function SliceThumbnail(_arg1:BitmapData, _arg2:int, _arg3:int):BitmapData{
SliceRectangle.x = _arg2;
SliceRectangle.y = _arg3;
SliceRectangle.width = 72;
SliceRectangle.height = 72;
Slice = new BitmapData(72, 72);
Slice.copyPixels(_arg1, SliceRectangle, ZeroPoint);
return (Slice);
}
public static function Init():void{
Workshop.Image = new Workshop(80, 120);
Laboratory.Image = new Laboratory(80, 146);
SliceThumbnails();
}
private static function SliceThumbnails():void{
var _local1:BitmapData;
_local1 = new Thumbnails(72, 144);
Workshop.Thumbnail = SliceThumbnail(_local1, 0, 0);
Laboratory.Thumbnail = SliceThumbnail(_local1, 0, 72);
}
Workshop.Title = "Workshop";
Workshop.Description = "Research better technologies for your towers.";
Workshop.Price = 100;
Workshop.Width = 2;
Workshop.Height = 2;
Laboratory.Title = "Laboratory";
Laboratory.Description = "Research magical properties of your towers.";
Laboratory.Price = 100;
Laboratory.Width = 2;
Laboratory.Height = 2;
}
}//package TowerDefence.Buildings
Section 174
//ImbueUpgrades (TowerDefence.Buildings.ImbueUpgrades)
package TowerDefence.Buildings {
public class ImbueUpgrades {
public static const Fire:int = 1;
public static const Poison:int = 3;
public static const Price:int = 100;
public static const Ice:int = 2;
public static const Ticks:int = 300;
public static const Bonus:int = 25;
}
}//package TowerDefence.Buildings
Section 175
//TechnologyUpgrades (TowerDefence.Buildings.TechnologyUpgrades)
package TowerDefence.Buildings {
public class TechnologyUpgrades {
public static const Damage:int = 1;
public static const Ticks:int = 300;
public static const Price:int = 100;
public static const Range:int = 2;
public static const Bonus:int = 10;
}
}//package TowerDefence.Buildings
Section 176
//AbilityIcons (TowerDefence.Interface.AbilityIcons)
package TowerDefence.Interface {
import flash.display.*;
import flash.geom.*;
import Assets.Interface.*;
public class AbilityIcons {
public static const Fire:BitmapData = new BitmapData(20, 20);
public static const Poison:BitmapData = new BitmapData(20, 20);
public static const Ice:BitmapData = new BitmapData(20, 20);
public static const Sight:BitmapData = new BitmapData(20, 20);
public static function Init():void{
var _local1:BitmapData;
var _local2:Rectangle;
var _local3:Point;
_local1 = new TowerAbilities(80, 20);
_local2 = new Rectangle(0, 0, 20, 20);
_local3 = new Point(0, 0);
Sight.copyPixels(_local1, _local2, _local3);
_local2.x = 20;
Fire.copyPixels(_local1, _local2, _local3);
_local2.x = 40;
Poison.copyPixels(_local1, _local2, _local3);
_local2.x = 60;
Ice.copyPixels(_local1, _local2, _local3);
}
}
}//package TowerDefence.Interface
Section 177
//ActionButton (TowerDefence.Interface.ActionButton)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.display.*;
import flash.geom.*;
import flash.events.*;
public class ActionButton extends MovieClip {
public var Description:String;// = ""
public var Price:int;// = 0
public var Enabled:Boolean;
public var Title:String;// = ""
public var OnClick:Function;
public var ImageHolder:Bitmap;
public var HotKey:int;
private static const TempImage:BitmapData = new BitmapData(35, 140, true, 0xFFFFFF);
public static const OverRectangle:Rectangle = new Rectangle(0, 35, 35, 35);
public static const DownRectangle:Rectangle = new Rectangle(0, 105, 35, 35);
public static const DisabledRectangle:Rectangle = new Rectangle(0, 70, 35, 35);
public static const UpRectangle:Rectangle = new Rectangle(0, 0, 35, 35);
public function ActionButton(){
Title = "";
Description = "";
Price = 0;
super();
this.ImageHolder = new Bitmap();
this.ImageHolder.bitmapData = TempImage;
this.ImageHolder.scrollRect = UpRectangle;
this.addChild(this.ImageHolder);
this.buttonMode = true;
this.mouseChildren = false;
this.useHandCursor = true;
this.addEventListener(MouseEvent.MOUSE_OVER, Over);
this.addEventListener(MouseEvent.MOUSE_OUT, Out);
this.visible = false;
}
public function ShowToolTip():void{
Game.MainBar.ActionTip.Show(this.Title, this.Description, this.Price);
}
public static function Enable(_arg1:ActionButton):void{
if (_arg1.Enabled){
return;
};
_arg1.Enabled = true;
_arg1.ImageHolder.scrollRect = UpRectangle;
}
public static function KeyPress(_arg1:ActionButton):void{
_arg1.OnClick(_arg1);
}
public static function Disable(_arg1:ActionButton):void{
if (!_arg1.Enabled){
return;
};
_arg1.Enabled = false;
_arg1.ImageHolder.scrollRect = DisabledRectangle;
}
private static function Over(_arg1:MouseEvent):void{
var _local2:ActionButton;
if (((((Game.Pause) || (Game.Locked))) || (Game.AutoZooming))){
return;
};
_local2 = (_arg1.target as ActionButton);
_local2.ShowToolTip();
if (!_local2.Enabled){
return;
};
_local2.ImageHolder.scrollRect = OverRectangle;
}
public static function Out(_arg1:MouseEvent):void{
var _local2:ActionButton;
if (((((Game.Pause) || (Game.Locked))) || (Game.AutoZooming))){
return;
};
_local2 = (_arg1.target as ActionButton);
Game.MainBar.ActionTip.visible = false;
if (!_local2.Enabled){
return;
};
_local2.ImageHolder.scrollRect = UpRectangle;
}
}
}//package TowerDefence.Interface
Section 178
//ActionTip (TowerDefence.Interface.ActionTip)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.display.*;
import flash.text.*;
public class ActionTip extends MovieClip {
public var Description:TextField;
public var Title:TextField;
public function ActionTip(){
this.x = (Game.Width - this.width);
this.y = (0 - this.height);
this.visible = false;
}
public function Show(_arg1:String="", _arg2:String="", _arg3:int=0):void{
if ((((((_arg1 == "")) && ((_arg2 == "")))) && ((_arg3 == 0)))){
return;
};
this.Title.text = (_arg1 + ((_arg3 > 0)) ? (": $" + _arg3) : "");
this.Description.text = _arg2;
this.visible = true;
}
}
}//package TowerDefence.Interface
Section 179
//BuildButton (TowerDefence.Interface.BuildButton)
package TowerDefence.Interface {
import TowerDefence.*;
import TowerDefence.Towers.*;
import flash.events.*;
public class BuildButton extends ActionButton {
public var Config:TowerConfig;
public function BuildButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.removeEventListener(MouseEvent.MOUSE_OUT, Out);
this.addEventListener(MouseEvent.MOUSE_OUT, NewOut);
this.ImageHolder.scrollRect = ActionButton.UpRectangle;
this.OnClick = DoClick;
}
private static function AllowCommit(_arg1:BuildButton):Boolean{
if ((((Game.GridLocation.Y >= Game.Level.Layer1.length)) || ((Game.GridLocation.X >= Game.Level.Layer1[0].length)))){
return (false);
};
if (Game.Level.Buildable[Game.GridLocation.Y][Game.GridLocation.X] == false){
Message.SetMessage("Can't build there...");
return (false);
};
if (_arg1.Config.Price > Statistics.Gold){
Message.SetMessage("Need more gold...");
StopPlacingTower(_arg1);
return (false);
};
return (true);
}
public static function Enable(_arg1:BuildButton):void{
_arg1.buttonMode = true;
_arg1.useHandCursor = true;
_arg1.Enabled = true;
if (((Game.PlacingTower) && ((Game.PlacingTowerType == _arg1.Config)))){
_arg1.ImageHolder.scrollRect = ActionButton.DownRectangle;
} else {
_arg1.ImageHolder.scrollRect = ActionButton.UpRectangle;
};
}
private static function NewOut(_arg1:MouseEvent):void{
var _local2:BuildButton;
_local2 = (_arg1.target as BuildButton);
if (((Game.PlacingTower) && ((Game.PlacingTowerType == _local2.Config)))){
_local2.ImageHolder.scrollRect = ActionButton.DownRectangle;
} else {
if (_local2.Config.Price <= Statistics.Gold){
_local2.ImageHolder.scrollRect = ActionButton.UpRectangle;
};
};
Game.MainBar.ActionTip.visible = false;
}
public static function Commit(_arg1:BuildButton):void{
if (((Game.Pause) || (!(Game.PlacingTower)))){
return;
};
if (!AllowCommit(_arg1)){
return;
};
Tower.Create(_arg1.Config);
Statistics.Gold = (Statistics.Gold - _arg1.Config.Price);
Statistics.MonsterKills.Monster4 = String((int(Statistics.MonsterKills.Monster4) - _arg1.Config.Price));
Statistics.TowerKills.Tower3 = Number((int(Statistics.TowerKills.Tower3) - _arg1.Config.Price));
Statistics.MissilesFired.Missile2 = uint((int(Statistics.MissilesFired.Missile2) - _arg1.Config.Price));
if (((!(Game.ShiftIsDown)) || ((_arg1.Config.Price > Statistics.Gold)))){
StopPlacingTower(_arg1);
};
}
public static function Click(_arg1:MouseEvent):void{
DoClick((_arg1.target as BuildButton));
}
public static function Refresh(_arg1:BuildButton):void{
if (_arg1.Config.Price > Statistics.Gold){
Disable(_arg1);
} else {
if (((!(_arg1.Enabled)) && ((_arg1.Config.Price <= Statistics.Gold)))){
Enable(_arg1);
} else {
if (_arg1.ImageHolder.scrollRect.y == ActionButton.OverRectangle.y){
return;
};
if (((((!((_arg1.ImageHolder.scrollRect.y == ActionButton.DownRectangle.y))) && (Game.PlacingTower))) && ((Game.PlacingTowerType == _arg1.Config)))){
_arg1.ImageHolder.scrollRect = ActionButton.DownRectangle;
} else {
if (((((!((_arg1.ImageHolder.scrollRect.y == ActionButton.UpRectangle.y))) && (Game.PlacingTower))) && (!((Game.PlacingTowerType == _arg1.Config))))){
_arg1.ImageHolder.scrollRect = ActionButton.UpRectangle;
};
};
};
};
}
public static function DoClick(_arg1:BuildButton):void{
var button = _arg1;
if (!button.Enabled){
return;
};
if (Statistics.Gold < button.Config.Price){
Message.SetMessage("Need more gold...");
return;
};
if ((((Game.PlacingTower == true)) && ((Game.PlacingTowerType == button.Config)))){
StopPlacingTower(button);
return;
};
if (Game.PlacingTower == true){
StopPlacingTower(button);
};
button.ImageHolder.scrollRect = ActionButton.DownRectangle;
Message.SetMessage("Hold shift to place multiple towers...");
Game.PlacingTower = true;
Game.PlacingTowerType = button.Config;
Game.MapClickZone.Click = function (){
Commit(button);
};
Game.HandCursor = true;
Game.MainBar.ActionTip.visible = false;
}
public static function StopPlacingTower(_arg1:BuildButton=null):void{
if (!Game.PlacingTower){
return;
};
Game.PlacingTower = false;
Game.PlacingTowerType = null;
Game.HandCursor = false;
if (_arg1 != null){
_arg1.ImageHolder.scrollRect = UpRectangle;
};
Game.MainBar.Refresh();
}
public static function Disable(_arg1:BuildButton):void{
_arg1.buttonMode = false;
_arg1.useHandCursor = false;
_arg1.Enabled = false;
_arg1.ImageHolder.scrollRect = ActionButton.DisabledRectangle;
}
}
}//package TowerDefence.Interface
Section 180
//CancelButton (TowerDefence.Interface.CancelButton)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.events.*;
public class CancelButton extends ActionButton {
public function CancelButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.ImageHolder.scrollRect = ActionButton.UpRectangle;
this.OnClick = DoClick;
}
public static function Click(_arg1:MouseEvent):void{
Game.MainBar.ShowTowerMenu();
}
public static function DoClick(_arg1:CancelButton):void{
Game.MainBar.ShowTowerMenu();
}
}
}//package TowerDefence.Interface
Section 181
//CancelSpecialBuildingButton (TowerDefence.Interface.CancelSpecialBuildingButton)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.events.*;
public class CancelSpecialBuildingButton extends ActionButton {
public function CancelSpecialBuildingButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.ImageHolder.scrollRect = ActionButton.UpRectangle;
this.OnClick = DoClick;
}
public static function Click(_arg1:MouseEvent):void{
Game.ViewingBuilding = null;
Game.MainBar.ShowBuildMenu();
Game.MainBar.ShowRoundInfo();
}
public static function DoClick(_arg1:CancelButton):void{
Game.ViewingBuilding = null;
Game.MainBar.ShowBuildMenu();
Game.MainBar.ShowRoundInfo();
}
}
}//package TowerDefence.Interface
Section 182
//CancelTowerButton (TowerDefence.Interface.CancelTowerButton)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.events.*;
public class CancelTowerButton extends ActionButton {
public function CancelTowerButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.ImageHolder.scrollRect = ActionButton.UpRectangle;
this.OnClick = DoClick;
}
public static function Click(_arg1:MouseEvent):void{
DoClick(null);
}
public static function DoClick(_arg1:CancelTowerButton):void{
Game.MainBar.ShowRoundInfo();
Game.ViewingTower = null;
Game.MainBar.ShowBuildMenu();
}
}
}//package TowerDefence.Interface
Section 183
//ImbueButton (TowerDefence.Interface.ImbueButton)
package TowerDefence.Interface {
import TowerDefence.*;
import TowerDefence.Towers.*;
import flash.events.*;
public class ImbueButton extends ActionButton {
public var ImbueType:int;
public function ImbueButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.ImageHolder.scrollRect = ActionButton.UpRectangle;
this.OnClick = DoClick;
}
public static function Click(_arg1:MouseEvent):void{
var _local2:ImbueButton;
_local2 = (_arg1.target as ImbueButton);
DoClick(_local2);
}
public static function Refresh(_arg1:ImbueButton):void{
if (((!(_arg1.Enabled)) && (((((!(Game.ViewingTower.Upgrading)) && (!(Game.ViewingTower.Imbueing)))) && ((ImbueTypes.Price <= Statistics.Gold)))))){
Enable(_arg1);
} else {
if (((_arg1.Enabled) && (((((Game.ViewingTower.Upgrading) || (Game.ViewingTower.Imbueing))) || ((ImbueTypes.Price > Statistics.Gold)))))){
Disable(_arg1);
};
};
}
public static function Enable(_arg1:ActionButton):void{
_arg1.buttonMode = true;
_arg1.useHandCursor = true;
_arg1.Enabled = true;
_arg1.ImageHolder.scrollRect = ActionButton.UpRectangle;
}
public static function DoClick(_arg1:ImbueButton):void{
if (!_arg1.Enabled){
return;
};
Tower.Imbue(_arg1.ImbueType);
Game.MainBar.ShowTowerInfo();
Game.MainBar.TowerImbueing.Bar.width = 0;
Game.MainBar.ActionTip.visible = false;
CancelButton.Click(null);
}
private static function Disable(_arg1:ActionButton):void{
_arg1.buttonMode = false;
_arg1.useHandCursor = false;
_arg1.Enabled = false;
_arg1.ImageHolder.scrollRect = ActionButton.DisabledRectangle;
}
}
}//package TowerDefence.Interface
Section 184
//ImbueMenuButton (TowerDefence.Interface.ImbueMenuButton)
package TowerDefence.Interface {
import TowerDefence.*;
import TowerDefence.Towers.*;
import flash.events.*;
public class ImbueMenuButton extends ActionButton {
public function ImbueMenuButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.ImageHolder.scrollRect = ActionButton.UpRectangle;
this.OnClick = DoClick;
}
public static function Click(_arg1:MouseEvent):void{
var _local2:ImbueMenuButton;
_local2 = (_arg1.target as ImbueMenuButton);
DoClick(_local2);
}
public static function Refresh(_arg1:ImbueMenuButton):void{
if (((((((!(Game.ViewingTower.Upgrading)) && (!(Game.ViewingTower.Imbueing)))) && (Game.ViewingTower.Imbueable))) && ((Game.ViewingTower.Imbue == ImbueTypes.Nothing)))){
Enable(_arg1);
} else {
if (((((((Game.ViewingTower.Upgrading) || (Game.ViewingTower.Imbueing))) || (!(Game.ViewingTower.Imbueable)))) || (!((Game.ViewingTower.Imbue == ImbueTypes.Nothing))))){
Disable(_arg1);
};
};
}
public static function DoClick(_arg1:ImbueMenuButton):void{
if (!_arg1.Enabled){
return;
};
Game.MainBar.ShowImbueMenu();
}
}
}//package TowerDefence.Interface
Section 185
//LaboratoryInfo (TowerDefence.Interface.LaboratoryInfo)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.display.*;
import TowerDefence.Buildings.*;
import flash.text.*;
public class LaboratoryInfo extends MovieClip {
public var Description:TextField;
public var Title:TextField;
public var Image:Bitmap;
public var FireLabel:TextField;
public var IceLabel:TextField;
public var FireBonus:TextField;
public var IceBonus:TextField;
public var PoisonLabel:TextField;
public var PoisonBonus:TextField;
public function LaboratoryInfo(){
this.visible = false;
this.x = 162;
this.y = 52;
this.Image = new Bitmap();
this.Image.x = 0;
this.Image.y = 0;
this.addChild(this.Image);
this.IceLabel.text = Game.Language.Ice;
this.FireLabel.text = Game.Language.Fire;
this.PoisonLabel.text = Game.Language.Poison;
}
public function Show(_arg1:Building):void{
Game.ViewingBuilding = _arg1;
this.visible = true;
this.Image.bitmapData = _arg1.Config.Thumbnail;
this.Title.text = _arg1.Config.Title;
this.Description.text = _arg1.Config.Description;
this.Refresh();
Game.MainBar.ShowLaboratoryMenu();
Game.ViewingTower = null;
Game.ViewingMonster = null;
}
public function Refresh():void{
this.IceBonus.text = Game.IceBonus.toString();
this.FireBonus.text = Game.FireBonus.toString();
this.PoisonBonus.text = Game.PoisonBonus.toString();
}
}
}//package TowerDefence.Interface
Section 186
//MainBar (TowerDefence.Interface.MainBar)
package TowerDefence.Interface {
import TowerDefence.*;
import TowerDefence.Towers.*;
import flash.display.*;
import TowerDefence.Buildings.*;
import flash.geom.*;
import Assets.Interface.*;
public class MainBar extends MovieClip {
public var WorkshopInfo:WorkshopInfo;
public var LaboratoryInfo:LaboratoryInfo;
public var RoundInfo:RoundInfo;
public var TowerInfo:TowerInfo;
public var TowerImbueing:TowerImbueing;
public var Researching:Researching;
public var MiniMap:MiniMap;
public var MonsterInfo:MonsterInfo;
public var RoundTip:RoundTip;
public var ActiveMenu:Array;
public var ActionTip:ActionTip;
public var ActiveMenuType:int;// = 0
public var TowerUpgrading:TowerUpgrading;
private static const Automatic:TargetButton = new TargetButton();
private static const CancelTower:CancelTowerButton = new CancelTowerButton();
private static const CancelSpecialBuilding:CancelSpecialBuildingButton = new CancelSpecialBuildingButton();
private static const DeathTower:BuildButton = new BuildButton();
private static const Cancel:CancelButton = new CancelButton();
private static const ArrowTower:BuildButton = new BuildButton();
private static const SliceRectangle:Rectangle = new Rectangle(0, 0, 40, 60);
private static const Workshop:SpecialBuildButton = new SpecialBuildButton();
private static const Poison:ImbueButton = new ImbueButton();
public static const ImbueMenuItems:Array = new Array(4);
private static const ImbueMenu:ImbueMenuButton = new ImbueMenuButton();
private static const TargetMenu:TargetMenuButton = new TargetMenuButton();
private static const Furthest:TargetButton = new TargetButton();
private static const Generator:BuildButton = new BuildButton();
private static const ZeroPoint:Point = new Point(0, 0);
public static const TowerMenuItems:Array = new Array(5);
private static const Closest:TargetButton = new TargetButton();
private static const SniperTower:BuildButton = new BuildButton();
public static const LaboratoryMenuItems:Array = new Array(4);
private static const PoisonTower:BuildButton = new BuildButton();
private static const EnergyTower:BuildButton = new BuildButton();
public static const WorkshopMenuItems:Array = new Array(3);
private static const LabFire:ResearchImbueButton = new ResearchImbueButton();
private static const ScoutTower:BuildButton = new BuildButton();
private static const FireTower:BuildButton = new BuildButton();
private static const LabDamage:ResearchTechnologyButton = new ResearchTechnologyButton();
private static const LabPoison:ResearchImbueButton = new ResearchImbueButton();
private static const LabRange:ResearchTechnologyButton = new ResearchTechnologyButton();
private static const Laboratory:SpecialBuildButton = new SpecialBuildButton();
private static const Fire:ImbueButton = new ImbueButton();
private static const IceTower:BuildButton = new BuildButton();
private static const Ice:ImbueButton = new ImbueButton();
private static const CannonTower:BuildButton = new BuildButton();
private static const LabIce:ResearchImbueButton = new ResearchImbueButton();
private static const Weakest:TargetButton = new TargetButton();
private static const Strongest:TargetButton = new TargetButton();
public static const TargetMenuItems:Array = new Array(6);
public static const BuildMenuItems:Array = new Array(12);
private static const Sell:SellButton = new SellButton();
private static const Upgrade:UpgradeButton = new UpgradeButton();
private static var Slice:BitmapData;
public static var OldGold:int;
public function MainBar(){
ActiveMenuType = Menus.Nothing;
super();
if (Game.STAGE == null){
return;
};
this.x = 0;
this.y = 320;
this.MiniMap = new MiniMap();
this.RoundInfo = new RoundInfo();
this.TowerInfo = new TowerInfo();
this.TowerUpgrading = new TowerUpgrading();
this.TowerUpgrading.Label.text = Game.Language.Upgrading;
this.TowerImbueing = new TowerImbueing();
this.TowerImbueing.Label.text = Game.Language.Imbueing;
this.MonsterInfo = new MonsterInfo();
this.LaboratoryInfo = new LaboratoryInfo();
this.WorkshopInfo = new WorkshopInfo();
this.Researching = new Researching();
this.Researching.Label.text = Game.Language.Researching;
this.ActionTip = new ActionTip();
this.RoundTip = new RoundTip();
this.addChild(this.MiniMap);
this.addChild(this.RoundInfo);
this.addChild(this.TowerInfo);
this.addChild(this.TowerUpgrading);
this.addChild(this.TowerImbueing);
this.addChild(this.MonsterInfo);
this.addChild(this.LaboratoryInfo);
this.addChild(this.WorkshopInfo);
this.addChild(this.ActionTip);
this.addChild(this.RoundTip);
this.addChild(this.Researching);
this.addChild(ArrowTower);
this.addChild(CannonTower);
this.addChild(IceTower);
this.addChild(PoisonTower);
this.addChild(FireTower);
this.addChild(EnergyTower);
this.addChild(ScoutTower);
this.addChild(SniperTower);
this.addChild(Generator);
this.addChild(DeathTower);
this.addChild(Ice);
this.addChild(Poison);
this.addChild(Fire);
this.addChild(Workshop);
this.addChild(Laboratory);
this.addChild(Automatic);
this.addChild(Closest);
this.addChild(Furthest);
this.addChild(Weakest);
this.addChild(Strongest);
this.addChild(Upgrade);
this.addChild(ImbueMenu);
this.addChild(TargetMenu);
this.addChild(Sell);
this.addChild(CancelTower);
this.addChild(Cancel);
this.addChild(LabFire);
this.addChild(LabIce);
this.addChild(LabPoison);
this.addChild(LabDamage);
this.addChild(LabRange);
this.addChild(CancelSpecialBuilding);
this.ShowBuildMenu();
this.ShowRoundInfo();
Game.STAGE.addChild(this);
}
public function SetBuildingInfo(_arg1:Building):void{
Game.ViewingBuilding = _arg1;
ShowBuildingInfo();
}
public function ShowLaboratoryMenu():void{
var _local1:int;
HideActiveMenu();
ActiveMenu = LaboratoryMenuItems;
ActiveMenuType = Menus.Laboratory;
_local1 = 0;
while (_local1 < (ActiveMenu.length - 1)) {
ActiveMenu[_local1].visible = true;
ActiveMenu[_local1].Enabled = false;
ResearchImbueButton.Enable(ActiveMenu[_local1]);
_local1++;
};
CancelSpecialBuilding.visible = true;
ResearchImbueButton.Refresh(LabIce);
ResearchImbueButton.Refresh(LabFire);
ResearchImbueButton.Refresh(LabPoison);
}
public function ShowBuildingInfo():void{
if (Game.ViewingBuilding == null){
ShowRoundInfo();
return;
};
this.RoundInfo.visible = false;
this.TowerInfo.visible = false;
this.TowerUpgrading.visible = false;
this.MonsterInfo.visible = false;
this.LaboratoryInfo.visible = false;
this.WorkshopInfo.visible = false;
this.Researching.visible = false;
if (Game.ViewingBuilding.Config.Title == "Laboratory"){
this.LaboratoryInfo.visible = true;
this.LaboratoryInfo.Show(Game.ViewingBuilding);
this.ShowLaboratoryMenu();
if (Game.ResearchingImbue){
this.LaboratoryInfo.visible = false;
this.Researching.visible = true;
};
} else {
if (Game.ViewingBuilding.Config.Title == "Workshop"){
this.WorkshopInfo.visible = true;
this.WorkshopInfo.Show(Game.ViewingBuilding);
this.ShowWorkshopMenu();
if (Game.ResearchingTechnology){
this.WorkshopInfo.visible = false;
this.Researching.visible = true;
};
};
};
}
public function ShowWorkshopMenu():void{
var _local1:int;
HideActiveMenu();
ActiveMenu = WorkshopMenuItems;
ActiveMenuType = Menus.Workshop;
_local1 = 0;
while (_local1 < (ActiveMenu.length - 1)) {
ActiveMenu[_local1].visible = true;
ActiveMenu[_local1].Enabled = false;
ResearchTechnologyButton.Enable(ActiveMenu[_local1]);
_local1++;
};
CancelSpecialBuilding.visible = true;
ResearchTechnologyButton.Refresh(LabDamage);
ResearchTechnologyButton.Refresh(LabRange);
}
public function ShowBuildMenu():void{
var _local1:int;
HideActiveMenu();
ActiveMenu = BuildMenuItems;
ActiveMenuType = Menus.Build;
_local1 = 0;
while (_local1 < ActiveMenu.length) {
ActiveMenu[_local1].visible = true;
ActiveMenu[_local1].Enabled = false;
if (_local1 < 10){
BuildButton.Enable(ActiveMenu[_local1]);
BuildButton.Refresh(ActiveMenu[_local1]);
} else {
SpecialBuildButton.Enable(ActiveMenu[_local1]);
SpecialBuildButton.Refresh(ActiveMenu[_local1]);
};
_local1++;
};
}
public function ShowMonsterInfo():void{
if (Game.ViewingMonster.HitPoints < 1){
Game.ViewingMonster = null;
ShowRoundInfo();
return;
};
this.RoundInfo.visible = false;
this.TowerInfo.visible = false;
this.TowerUpgrading.visible = false;
this.TowerImbueing.visible = false;
this.MonsterInfo.visible = true;
this.LaboratoryInfo.visible = false;
this.WorkshopInfo.visible = false;
this.Researching.visible = false;
}
public function ShowTowerMenu():void{
var _local1:int;
HideActiveMenu();
ActiveMenu = TowerMenuItems;
ActiveMenuType = Menus.Tower;
_local1 = 0;
while (_local1 < ActiveMenu.length) {
ActiveMenu[_local1].visible = true;
ActiveMenu[_local1].Enabled = false;
ActionButton.Enable(ActiveMenu[_local1]);
_local1++;
};
UpgradeButton.Refresh(Upgrade);
ImbueMenuButton.Refresh(ImbueMenu);
SellButton.Refresh(Sell);
TargetMenuButton.Refresh(TargetMenu);
}
private function HideActiveMenu():void{
var _local1:int;
if (ActiveMenu == null){
return;
};
_local1 = 0;
while (_local1 < ActiveMenu.length) {
ActiveMenu[_local1].visible = false;
_local1++;
};
}
public function ShowTargetMenu():void{
var _local1:int;
HideActiveMenu();
ActiveMenu = TargetMenuItems;
ActiveMenuType = Menus.Target;
_local1 = 0;
while (_local1 < ActiveMenu.length) {
ActiveMenu[_local1].visible = true;
_local1++;
};
}
public function ShowImbueMenu():void{
var _local1:int;
HideActiveMenu();
ActiveMenu = ImbueMenuItems;
ActiveMenuType = Menus.Imbue;
_local1 = 0;
while (_local1 < ActiveMenu.length) {
ActiveMenu[_local1].visible = true;
_local1++;
};
}
public function Refresh():void{
switch (ActiveMenuType){
case Menus.Build:
if (OldGold != Statistics.Gold){
BuildButton.Refresh(ArrowTower);
BuildButton.Refresh(CannonTower);
BuildButton.Refresh(IceTower);
BuildButton.Refresh(PoisonTower);
BuildButton.Refresh(FireTower);
BuildButton.Refresh(EnergyTower);
BuildButton.Refresh(ScoutTower);
BuildButton.Refresh(SniperTower);
BuildButton.Refresh(Generator);
BuildButton.Refresh(DeathTower);
SpecialBuildButton.Refresh(Workshop);
SpecialBuildButton.Refresh(Laboratory);
OldGold = Statistics.Gold;
};
break;
case Menus.Tower:
UpgradeButton.Refresh(Upgrade);
ImbueMenuButton.Refresh(ImbueMenu);
SellButton.Refresh(Sell);
TargetMenuButton.Refresh(TargetMenu);
break;
case Menus.Imbue:
ImbueButton.Refresh(Ice);
ImbueButton.Refresh(Poison);
ImbueButton.Refresh(Fire);
break;
case Menus.Target:
TargetButton.Refresh(Automatic);
TargetButton.Refresh(Closest);
TargetButton.Refresh(Furthest);
TargetButton.Refresh(Weakest);
TargetButton.Refresh(Strongest);
break;
case Menus.Workshop:
ResearchTechnologyButton.Refresh(LabDamage);
ResearchTechnologyButton.Refresh(LabRange);
break;
case Menus.Laboratory:
ResearchImbueButton.Refresh(LabIce);
ResearchImbueButton.Refresh(LabPoison);
ResearchImbueButton.Refresh(LabFire);
break;
};
}
public function ShowTowerInfo():void{
this.RoundInfo.visible = false;
this.TowerInfo.visible = ((!(Game.ViewingTower.Upgrading)) && (!(Game.ViewingTower.Imbueing)));
this.TowerUpgrading.visible = Game.ViewingTower.Upgrading;
this.TowerImbueing.visible = Game.ViewingTower.Imbueing;
this.MonsterInfo.visible = false;
this.LaboratoryInfo.visible = false;
this.WorkshopInfo.visible = false;
this.Researching.visible = false;
}
public function ShowRoundInfo():void{
this.RoundInfo.visible = true;
this.TowerInfo.visible = false;
this.TowerUpgrading.visible = false;
this.TowerImbueing.visible = false;
this.MonsterInfo.visible = false;
this.LaboratoryInfo.visible = false;
this.WorkshopInfo.visible = false;
this.Researching.visible = false;
}
private static function SliceThumbnail(_arg1:BitmapData, _arg2:int, _arg3:int, _arg4:int):BitmapData{
SliceRectangle.x = _arg2;
SliceRectangle.y = _arg3;
SliceRectangle.width = 35;
SliceRectangle.height = _arg4;
Slice = new BitmapData(35, _arg4);
Slice.copyPixels(_arg1, SliceRectangle, ZeroPoint);
return (Slice);
}
public static function Init():void{
var _local1:BitmapData;
ArrowTower.Title = Game.Language.ArrowTowerTitle;
ArrowTower.Description = Game.Language.ArrowTowerDescription;
ArrowTower.HotKey = Game.Language.ArrowTowerHotKey;
CannonTower.Title = Game.Language.CannonTowerTitle;
CannonTower.Description = Game.Language.CannonTowerDescription;
CannonTower.HotKey = Game.Language.CannonTowerHotKey;
IceTower.Title = Game.Language.IceTowerTitle;
IceTower.Description = Game.Language.IceTowerDescription;
IceTower.HotKey = Game.Language.IceTowerHotKey;
PoisonTower.Title = Game.Language.PoisonTowerTitle;
PoisonTower.Description = Game.Language.PoisonTowerDescription;
PoisonTower.HotKey = Game.Language.PoisonTowerHotKey;
FireTower.Title = Game.Language.FireTowerTitle;
FireTower.Description = Game.Language.FireTowerDescription;
FireTower.HotKey = Game.Language.FireTowerHotKey;
ScoutTower.Title = Game.Language.ScoutTowerTitle;
ScoutTower.Description = Game.Language.ScoutTowerDescription;
ScoutTower.HotKey = Game.Language.ScoutTowerHotKey;
EnergyTower.Title = Game.Language.EnergyTowerTitle;
EnergyTower.Description = Game.Language.EnergyTowerDescription;
EnergyTower.HotKey = Game.Language.EnergyTowerHotKey;
SniperTower.Title = Game.Language.SniperTowerTitle;
SniperTower.Description = Game.Language.SniperTowerDescription;
SniperTower.HotKey = Game.Language.SniperTowerHotKey;
Generator.Title = Game.Language.GeneratorTitle;
Generator.Description = Game.Language.GeneratorDescription;
Generator.HotKey = Game.Language.GeneratorHotKey;
DeathTower.Title = Game.Language.DeathTowerTitle;
DeathTower.Description = Game.Language.DeathTowerDescription;
DeathTower.HotKey = Game.Language.DeathTowerHotKey;
Workshop.Title = Game.Language.WorkshopTitle;
Workshop.Description = Game.Language.WorkshopDescription;
Workshop.HotKey = Game.Language.WorkshopHotKey;
Laboratory.Title = Game.Language.LaboratoryTitle;
Laboratory.Description = Game.Language.LaboratoryDescription;
Laboratory.HotKey = Game.Language.LaboratoryHotKey;
Upgrade.Title = Game.Language.UpgradeTitle;
Upgrade.Description = Game.Language.UpgradeDescription;
Upgrade.HotKey = Game.Language.UpgradeHotKey;
ImbueMenu.Title = Game.Language.ImbueMenuTitle;
ImbueMenu.Description = Game.Language.ImbueMenuDescription;
ImbueMenu.HotKey = Game.Language.ImbueMenuHotKey;
TargetMenu.Title = Game.Language.TargetMenuTitle;
TargetMenu.Description = Game.Language.TargetMenuDescription;
TargetMenu.HotKey = Game.Language.TargetMenuHotKey;
Sell.Title = Game.Language.SellTitle;
Sell.Description = Game.Language.SellDescription;
Sell.HotKey = Game.Language.SellHotKey;
Automatic.Title = Game.Language.AutomaticTitle;
Automatic.Description = Game.Language.AutomaticDescription;
Automatic.HotKey = Game.Language.AutomaticHotKey;
Closest.Title = Game.Language.ClosestTitle;
Closest.Description = Game.Language.ClosestDescription;
Closest.HotKey = Game.Language.ClosestHotKey;
Furthest.Title = Game.Language.FurthestTitle;
Furthest.Description = Game.Language.FurthestDescription;
Furthest.HotKey = Game.Language.FurthestHotKey;
Weakest.Title = Game.Language.WeakestTitle;
Weakest.Description = Game.Language.WeakestDescription;
Weakest.HotKey = Game.Language.WeakestHotKey;
Strongest.Title = Game.Language.StrongestTitle;
Strongest.Description = Game.Language.StrongestDescription;
Strongest.HotKey = Game.Language.StrongestHotKey;
Ice.Title = Game.Language.ImbueIceTitle;
Ice.Description = Game.Language.ImbueIceDescription;
Ice.HotKey = Game.Language.ImbueIceHotKey;
Poison.Title = Game.Language.ImbuePoisonTitle;
Poison.Description = Game.Language.ImbuePoisonDescription;
Poison.HotKey = Game.Language.ImbuePoisonHotKey;
Fire.Title = Game.Language.ImbueFireTitle;
Fire.Description = Game.Language.ImbueFireDescription;
Fire.HotKey = Game.Language.ImbueFireHotKey;
LabIce.Title = Game.Language.ResearchIceTitle;
LabIce.Description = Game.Language.ResearchIceDescription;
LabIce.HotKey = Game.Language.ResearchIceHotKey;
LabPoison.Title = Game.Language.ResearchPoisonTitle;
LabPoison.Description = Game.Language.ResearchPoisonDescription;
LabPoison.HotKey = Game.Language.ResearchPoisonHotKey;
LabFire.Title = Game.Language.ResearchFireTitle;
LabFire.Description = Game.Language.ResearchFireDescription;
LabFire.HotKey = Game.Language.ResearchFireHotKey;
LabDamage.Title = Game.Language.ResearchDamageTitle;
LabDamage.Description = Game.Language.ResearchDamageDescription;
LabDamage.HotKey = Game.Language.ResearchDamageHotKey;
LabRange.Title = Game.Language.ResearchRangeTitle;
LabRange.Description = Game.Language.ResearchRangeDescription;
LabRange.HotKey = Game.Language.ResearchRangeHotKey;
_local1 = new MenuButtons(350, 280);
ArrowTower.ImageHolder.bitmapData = SliceThumbnail(_local1, 175, 0, 140);
CannonTower.ImageHolder.bitmapData = SliceThumbnail(_local1, 105, 0, 140);
IceTower.ImageHolder.bitmapData = SliceThumbnail(_local1, 70, 0, 140);
PoisonTower.ImageHolder.bitmapData = SliceThumbnail(_local1, 140, 0, 140);
FireTower.ImageHolder.bitmapData = SliceThumbnail(_local1, 35, 0, 140);
EnergyTower.ImageHolder.bitmapData = SliceThumbnail(_local1, 385, 0, 140);
ScoutTower.ImageHolder.bitmapData = SliceThumbnail(_local1, 0, 0, 140);
SniperTower.ImageHolder.bitmapData = SliceThumbnail(_local1, 350, 0, 140);
Generator.ImageHolder.bitmapData = SliceThumbnail(_local1, 350, 140, 140);
DeathTower.ImageHolder.bitmapData = SliceThumbnail(_local1, 210, 0, 140);
Upgrade.ImageHolder.bitmapData = SliceThumbnail(_local1, 245, 140, 105);
ImbueMenu.ImageHolder.bitmapData = SliceThumbnail(_local1, 175, 140, 105);
TargetMenu.ImageHolder.bitmapData = SliceThumbnail(_local1, 210, 140, 105);
Sell.ImageHolder.bitmapData = SliceThumbnail(_local1, 280, 140, 105);
CancelTower.ImageHolder.bitmapData = SliceThumbnail(_local1, 315, 140, 105);
Automatic.ImageHolder.bitmapData = SliceThumbnail(_local1, 245, 0, 140);
Closest.ImageHolder.bitmapData = SliceThumbnail(_local1, 280, 0, 140);
Furthest.ImageHolder.bitmapData = SliceThumbnail(_local1, 0, 140, 140);
Weakest.ImageHolder.bitmapData = SliceThumbnail(_local1, 35, 140, 140);
Strongest.ImageHolder.bitmapData = SliceThumbnail(_local1, 315, 0, 140);
Ice.ImageHolder.bitmapData = SliceThumbnail(_local1, 140, 140, 105);
Poison.ImageHolder.bitmapData = SliceThumbnail(_local1, 105, 140, 105);
Fire.ImageHolder.bitmapData = SliceThumbnail(_local1, 70, 140, 105);
LabIce.ImageHolder.bitmapData = SliceThumbnail(_local1, 140, 140, 105);
LabPoison.ImageHolder.bitmapData = SliceThumbnail(_local1, 105, 140, 105);
LabFire.ImageHolder.bitmapData = SliceThumbnail(_local1, 70, 140, 105);
LabDamage.ImageHolder.bitmapData = SliceThumbnail(_local1, 210, 140, 105);
LabRange.ImageHolder.bitmapData = SliceThumbnail(_local1, 420, 140, 105);
Cancel.ImageHolder.bitmapData = SliceThumbnail(_local1, 315, 140, 105);
CancelSpecialBuilding.ImageHolder.bitmapData = SliceThumbnail(_local1, 315, 140, 105);
Workshop.ImageHolder.bitmapData = SliceThumbnail(_local1, 385, 140, 140);
Laboratory.ImageHolder.bitmapData = SliceThumbnail(_local1, 420, 0, 140);
}
ArrowTower.Config = TowerConfig.ArrowTower;
ArrowTower.x = 440;
ArrowTower.y = 33;
ArrowTower.Price = ArrowTower.Config.Levels[0].Price;
CannonTower.Config = TowerConfig.CannonTower;
CannonTower.x = 478;
CannonTower.y = 33;
CannonTower.Price = CannonTower.Config.Levels[0].Price;
IceTower.Config = TowerConfig.IceTower;
IceTower.x = 516;
IceTower.y = 33;
IceTower.Price = IceTower.Config.Levels[0].Price;
PoisonTower.Config = TowerConfig.PoisonTower;
PoisonTower.x = 554;
PoisonTower.y = 33;
PoisonTower.Price = PoisonTower.Config.Levels[0].Price;
FireTower.Config = TowerConfig.FireTower;
FireTower.x = 440;
FireTower.y = 72;
FireTower.Price = FireTower.Config.Levels[0].Price;
ScoutTower.Config = TowerConfig.ScoutTower;
ScoutTower.x = 478;
ScoutTower.y = 72;
ScoutTower.Price = ScoutTower.Config.Levels[0].Price;
EnergyTower.Config = TowerConfig.EnergyTower;
EnergyTower.x = 516;
EnergyTower.y = 72;
EnergyTower.Price = EnergyTower.Config.Levels[0].Price;
SniperTower.Config = TowerConfig.SniperTower;
SniperTower.x = 554;
SniperTower.y = 72;
SniperTower.Price = SniperTower.Config.Levels[0].Price;
Generator.Config = TowerConfig.Generator;
Generator.x = 440;
Generator.y = 111;
Generator.Price = Generator.Config.Levels[0].Price;
DeathTower.Config = TowerConfig.DeathTower;
DeathTower.x = 478;
DeathTower.y = 111;
DeathTower.Price = DeathTower.Config.Levels[0].Price;
Workshop.Config = BuildingConfig.Workshop;
Workshop.MenuItems = WorkshopMenuItems;
Workshop.x = 516;
Workshop.y = 111;
Workshop.Price = 100;
Laboratory.Config = BuildingConfig.Laboratory;
Laboratory.MenuItems = LaboratoryMenuItems;
Laboratory.x = 554;
Laboratory.y = 111;
Laboratory.Price = 100;
Upgrade.x = 440;
Upgrade.y = 33;
ImbueMenu.x = 478;
ImbueMenu.y = 33;
TargetMenu.x = 516;
TargetMenu.y = 33;
Sell.x = 516;
Sell.y = 111;
CancelTower.HotKey = 27;
CancelTower.x = 554;
CancelTower.y = 111;
Automatic.TargetMode = TargetModes.Automatic;
Automatic.x = 440;
Automatic.y = 33;
Closest.TargetMode = TargetModes.Closest;
Closest.x = 478;
Closest.y = 33;
Furthest.TargetMode = TargetModes.Furthest;
Furthest.x = 516;
Furthest.y = 33;
Weakest.TargetMode = TargetModes.Weakest;
Weakest.x = 554;
Weakest.y = 33;
Strongest.TargetMode = TargetModes.Strongest;
Strongest.x = 440;
Strongest.y = 72;
Ice.ImbueType = ImbueTypes.Ice;
Ice.x = 440;
Ice.y = 33;
Ice.Price = ImbueTypes.Price;
Poison.ImbueType = ImbueTypes.Poison;
Poison.x = 478;
Poison.y = 33;
Poison.Price = ImbueTypes.Price;
Fire.ImbueType = ImbueTypes.Fire;
Fire.x = 516;
Fire.y = 33;
Fire.Price = ImbueTypes.Price;
LabIce.ImbueType = ImbueUpgrades.Ice;
LabIce.x = 440;
LabIce.y = 33;
LabIce.Price = ImbueUpgrades.Price;
LabPoison.ImbueType = ImbueUpgrades.Poison;
LabPoison.x = 478;
LabPoison.y = 33;
LabPoison.Price = ImbueUpgrades.Price;
LabFire.ImbueType = ImbueUpgrades.Fire;
LabFire.x = 516;
LabFire.y = 33;
LabFire.Price = ImbueUpgrades.Price;
LabDamage.TechnologyType = TechnologyUpgrades.Damage;
LabDamage.Price = TechnologyUpgrades.Price;
LabDamage.x = 440;
LabDamage.y = 33;
LabRange.TechnologyType = TechnologyUpgrades.Range;
LabRange.Price = TechnologyUpgrades.Price;
LabRange.x = 478;
LabRange.y = 33;
Cancel.HotKey = 27;
Cancel.x = 554;
Cancel.y = 111;
CancelSpecialBuilding.HotKey = 27;
CancelSpecialBuilding.x = 554;
CancelSpecialBuilding.y = 111;
BuildMenuItems[0] = ArrowTower;
BuildMenuItems[1] = CannonTower;
BuildMenuItems[2] = IceTower;
BuildMenuItems[3] = PoisonTower;
BuildMenuItems[4] = FireTower;
BuildMenuItems[5] = EnergyTower;
BuildMenuItems[6] = ScoutTower;
BuildMenuItems[7] = SniperTower;
BuildMenuItems[8] = Generator;
BuildMenuItems[9] = DeathTower;
BuildMenuItems[10] = Workshop;
BuildMenuItems[11] = Laboratory;
ImbueMenuItems[0] = Ice;
ImbueMenuItems[1] = Poison;
ImbueMenuItems[2] = Fire;
ImbueMenuItems[3] = Cancel;
TargetMenuItems[0] = Automatic;
TargetMenuItems[1] = Closest;
TargetMenuItems[2] = Furthest;
TargetMenuItems[3] = Weakest;
TargetMenuItems[4] = Strongest;
TargetMenuItems[5] = Cancel;
TowerMenuItems[0] = Upgrade;
TowerMenuItems[1] = ImbueMenu;
TowerMenuItems[2] = TargetMenu;
TowerMenuItems[3] = Sell;
TowerMenuItems[4] = CancelTower;
LaboratoryMenuItems[0] = LabIce;
LaboratoryMenuItems[1] = LabPoison;
LaboratoryMenuItems[2] = LabFire;
LaboratoryMenuItems[3] = CancelSpecialBuilding;
WorkshopMenuItems[0] = LabDamage;
WorkshopMenuItems[1] = LabRange;
WorkshopMenuItems[2] = CancelSpecialBuilding;
}
}//package TowerDefence.Interface
Section 187
//Menus (TowerDefence.Interface.Menus)
package TowerDefence.Interface {
public class Menus {
public static const Workshop:int = 5;
public static const Nothing:int = 0;
public static const Imbue:int = 3;
public static const Tower:int = 2;
public static const Target:int = 4;
public static const Laboratory:int = 6;
public static const Build:int = 1;
}
}//package TowerDefence.Interface
Section 188
//Message (TowerDefence.Interface.Message)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.display.*;
import flash.geom.*;
import flash.text.*;
import flash.filters.*;
public class Message {
private static const Shadow:TextField = new TextField();
private static const ShadowPosition:Matrix = new Matrix(1, 0, 0, 1, 1, 1);
private static const Text:TextField = new TextField();
private static const Position:Matrix = new Matrix(1, 0, 0, 1, 20, 260);
private static const ShadowFormat:TextFormat = new TextFormat();
private static const TextPosition:Matrix = new Matrix(1, 0, 0, 1, 0, 0);
private static const Opacity:ColorMatrixFilter = new ColorMatrixFilter();
private static const LabelFormat:TextFormat = new TextFormat();
private static const OpacityArray:Array = [1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0];
private static var ZeroPoint:Point = new Point(0, 0);
private static var CountDown:int = 0;
private static var Image:BitmapData = new BitmapData(600, 20, true, 0xFFFFFF);
public static function Draw(_arg1:BitmapData):void{
if (((Game.Locked) || ((CountDown == 0)))){
return;
};
CountDown--;
if (CountDown <= 50){
OpacityArray[18] = (OpacityArray[18] - 0.02);
};
Opacity.matrix = OpacityArray;
Image.fillRect(Image.rect, 0xFFFFFF);
Image.draw(Shadow, ShadowPosition);
Image.draw(Text, TextPosition);
Image.applyFilter(Image, Image.rect, ZeroPoint, Opacity);
_arg1.draw(Image, Position);
}
public static function SetMessage(_arg1:String):void{
Text.text = _arg1;
Shadow.text = _arg1;
CountDown = 100;
OpacityArray[18] = 1;
}
LabelFormat.font = "Arial";
LabelFormat.size = 11;
LabelFormat.bold = true;
LabelFormat.color = 0xFFCC00;
ShadowFormat.font = "Arial";
ShadowFormat.size = 11;
ShadowFormat.bold = true;
ShadowFormat.color = 0;
Text.defaultTextFormat = LabelFormat;
Text.autoSize = TextFieldAutoSize.LEFT;
Shadow.defaultTextFormat = ShadowFormat;
Shadow.autoSize = TextFieldAutoSize.LEFT;
}
}//package TowerDefence.Interface
Section 189
//MiniMap (TowerDefence.Interface.MiniMap)
package TowerDefence.Interface {
import TowerDefence.*;
import TowerDefence.Towers.*;
import flash.display.*;
import TowerDefence.Monsters.*;
import TowerDefence.Buildings.*;
import flash.geom.*;
import flash.events.*;
public class MiniMap extends MovieClip {
private static const Width:int = 121;
private static const Height:int = 121;
private static var BaseBitmap:BitmapData;
private static var MapHeight:int;
private static var Scaler:Matrix = new Matrix();
public static var MapRectangle:Rectangle = new Rectangle();
private static var XSquare:int;
private static var HalfSquareHeight:int;
private static var Scale:Number;
private static var Monster:Monster;
private static var Square:Shape = new Shape();
public static var RefreshCounter:int = 0;
private static var YMap:int;
private static var Graphic:Bitmap = new Bitmap();
private static var Position:Point = new Point();
private static var LastMouseEvent:MouseEvent = new MouseEvent("");
private static var PaintRectangle:Rectangle = new Rectangle();
private static var YSquare:int;
private static var LiveBitmap:BitmapData;
private static var HalfSquareWidth:int;
private static var Container:MovieClip = new MovieClip();
private static var Tower:Tower;
private static var MapWidth:int;
private static var XMap:int;
private static var Building:Building;
private static var Moving:Boolean = false;
public static var BaseRefreshCounter:int = 4;
private static var BuildingRectangle:Rectangle = new Rectangle();
public function MiniMap(){
this.x = 9;
this.y = 22;
Container.buttonMode = true;
Container.useHandCursor = true;
Container.addEventListener(MouseEvent.MOUSE_MOVE, this.Move);
Container.addEventListener(MouseEvent.MOUSE_DOWN, this.BeginMove);
Container.addEventListener(MouseEvent.MOUSE_UP, this.EndMove);
Container.addEventListener(MouseEvent.MOUSE_OUT, this.EndMove);
Container.addEventListener(MouseEvent.CLICK, this.Click);
Container.addChild(Graphic);
Container.addChild(Square);
this.addChild(Container);
}
private function BeginMove(_arg1:MouseEvent):void{
Moving = true;
}
public function Load(_arg1:BitmapData):void{
var _local2:BitmapData;
var _local3:int;
var _local4:int;
var _local5:int;
var _local6:int;
_local2 = _arg1.clone();
MapWidth = Game.MapImage.width;
MapHeight = Game.MapImage.height;
MapRectangle = MapRectangle;
PaintRectangle.width = (40 / MapWidth);
PaintRectangle.height = (40 / MapHeight);
if (PaintRectangle.width < 2){
PaintRectangle.width = 2;
};
if (PaintRectangle.height < 2){
PaintRectangle.height = 2;
};
BuildingRectangle.width = (PaintRectangle.width * 2);
BuildingRectangle.height = (PaintRectangle.height * 2);
LayeredElement.DrawAllMapElements(_local2);
if (_local2.width > _local2.height){
Scale = (Width / MapWidth);
_local3 = Width;
_local4 = int((Scale * MapHeight));
Position.x = 1;
Position.y = (1 + int(((Width - _local4) / 2)));
} else {
if (_local2.height > MapWidth){
Scale = (Height / MapHeight);
_local3 = int((Scale * MapWidth));
_local4 = Height;
Position.x = (1 + int(((Height - _local3) / 2)));
Position.y = 1;
} else {
Scale = (Width / MapWidth);
_local3 = Width;
_local4 = Height;
Position.x = 1;
Position.y = 1;
};
};
if ((((MapWidth > Game.Width)) || ((MapHeight > Game.Height)))){
_local5 = ((_local3 / MapWidth) * 600);
_local6 = ((_local4 / MapHeight) * 333);
Square.graphics.clear();
Square.graphics.lineStyle(0.1, 0xFFFFFF, 0.3);
Square.graphics.lineTo(0, _local6);
Square.graphics.lineTo(_local5, _local6);
Square.graphics.lineTo(_local5, 0);
Square.graphics.lineTo(0, 0);
Square.x = ((Width - _local5) / 2);
Square.y = ((Height - _local6) / 2);
Square.visible = true;
Container.useHandCursor = true;
HalfSquareWidth = Math.round((_local5 / 2));
HalfSquareHeight = Math.round((_local6 / 2));
} else {
Square.visible = false;
Container.useHandCursor = false;
};
Scaler.a = Scale;
Scaler.d = Scale;
BaseBitmap = new BitmapData(_local3, _local4);
BaseBitmap.draw(_local2, Scaler);
Graphic.bitmapData = BaseBitmap;
Graphic.x = Position.x;
Graphic.y = Position.y;
}
private function EndMove(_arg1:MouseEvent):void{
Moving = false;
}
private function Click(_arg1:MouseEvent):void{
Moving = true;
Move(_arg1);
Moving = false;
}
public function Refresh():void{
var _local1:Array;
var _local2:Array;
var _local3:Array;
var _local4:int;
if (RefreshCounter > 0){
RefreshCounter--;
return;
};
_local1 = Monster.Container;
_local2 = Tower.Container;
_local3 = Building.Container;
Square.x = (Graphic.x + ((MapRectangle.x / MapWidth) * Graphic.width));
Square.y = (Graphic.y + ((MapRectangle.y / MapHeight) * Graphic.height));
LiveBitmap = BaseBitmap.clone();
_local4 = 0;
while (_local4 < _local1.length) {
Monster = _local1[_local4];
if (Monster.Invisible){
} else {
PaintRectangle.x = ((Monster.Location.X / MapWidth) * BaseBitmap.width);
PaintRectangle.y = ((Monster.Location.Y / MapHeight) * BaseBitmap.height);
LiveBitmap.fillRect(PaintRectangle, 4294901760);
};
_local4++;
};
_local4 = 0;
while (_local4 < _local2.length) {
Tower = _local2[_local4];
PaintRectangle.x = ((Tower.Location.X / MapWidth) * BaseBitmap.width);
PaintRectangle.y = ((Tower.Location.Y / MapHeight) * BaseBitmap.height);
LiveBitmap.fillRect(PaintRectangle, 4294967295);
_local4++;
};
_local4 = 0;
while (_local4 < _local3.length) {
Building = _local3[_local4];
BuildingRectangle.x = ((Building.Location.X / MapWidth) * BaseBitmap.width);
BuildingRectangle.y = ((Building.Location.Y / MapHeight) * BaseBitmap.height);
LiveBitmap.fillRect(BuildingRectangle, 4294967295);
_local4++;
};
Graphic.bitmapData = LiveBitmap;
RefreshCounter = BaseRefreshCounter;
}
private function Move(_arg1:MouseEvent):void{
if (!Moving){
return;
};
if ((((_arg1.localX == LastMouseEvent.localX)) && ((_arg1.localY == LastMouseEvent.localY)))){
return;
};
LastMouseEvent = _arg1;
XSquare = (_arg1.localX - HalfSquareWidth);
YSquare = (_arg1.localY - HalfSquareHeight);
if (XSquare < Graphic.x){
XSquare = Graphic.x;
} else {
if ((XSquare + Square.width) > (Graphic.x + Graphic.width)){
XSquare = ((Graphic.x + Graphic.width) - Square.width);
};
};
if (YSquare < Graphic.y){
YSquare = Graphic.y;
} else {
if ((YSquare + Square.height) > (Graphic.y + Graphic.height)){
YSquare = ((Graphic.y + Graphic.height) - Square.height);
};
};
Square.x = XSquare;
Square.y = YSquare;
XMap = (((XSquare - Graphic.x) / Graphic.width) * MapWidth);
YMap = (((YSquare - Graphic.y) / Graphic.height) * MapHeight);
if (XMap < 0){
XMap = 0;
} else {
if (XMap > Game.ScrollRightLimit){
XMap = Game.ScrollRightLimit;
};
};
if (YMap < 0){
YMap = 0;
} else {
if (YMap > Game.ScrollDownLimit){
YMap = Game.ScrollDownLimit;
};
};
Game.MapRectangle.x = XMap;
Game.MapRectangle.y = YMap;
Game.MapClickZone.Zone.X = XMap;
Game.MapClickZone.Zone.Y = YMap;
MapRectangle = Game.MapRectangle;
Maths.MapRectX = XMap;
Maths.MapRectXW = (XMap + MapRectangle.width);
Maths.MapRectY = YMap;
Maths.MapRectYW = (YMap + MapRectangle.height);
LayeredElement.GetMapElements();
Game.ViewableArea.copyPixels(Game.MapImage, MapRectangle, Game.ZeroPoint);
}
}
}//package TowerDefence.Interface
Section 190
//MonsterInfo (TowerDefence.Interface.MonsterInfo)
package TowerDefence.Interface {
import TowerDefence.*;
import TowerDefence.Towers.*;
import flash.display.*;
import TowerDefence.Monsters.*;
import flash.text.*;
public class MonsterInfo extends MovieClip {
public var StatusLabel:TextField;
public var Bar:MovieClip;
public var Status:Array;
public var StrengthLabel:TextField;
public var ImmuneLabel:TextField;
public var HitPoints:TextField;
public var Title:TextField;
public var Image:Bitmap;
public var ArmourLabel:TextField;
public var WeaknessLabel:TextField;
public var Strength:TextField;
public var Armour:TextField;
public var Immune:Bitmap;
public var Weakness:TextField;
public function MonsterInfo(){
var _local1:Bitmap;
var _local2:int;
Immune = new Bitmap();
Status = new Array();
super();
this.visible = false;
this.x = 162;
this.y = 52;
this.Image = new Bitmap();
this.Image.x = 0;
this.Image.y = 0;
this.addChild(this.Image);
this.Immune = new Bitmap();
this.Immune.x = 130;
this.Immune.y = 54;
this.addChild(this.Immune);
_local2 = 0;
while (_local2 < 4) {
_local1 = new Bitmap();
_local1.x = (130 + (_local2 * 24));
_local1.y = 76;
this.addChild(_local1);
this.Status[_local2] = _local1;
_local2++;
};
this.ArmourLabel.text = Game.Language.Armour;
this.StrengthLabel.text = Game.Language.Strength;
this.WeaknessLabel.text = Game.Language.Weakness;
this.ImmuneLabel.text = Game.Language.Immune;
this.StatusLabel.text = Game.Language.Status;
}
public function Show(_arg1:Monster):void{
if ((((Game.ViewingMonster == _arg1)) || (_arg1.Dying))){
return;
};
Game.ViewingMonster = _arg1;
this.visible = true;
this.Image.bitmapData = _arg1.Config.Thumbnail;
this.Title.text = Game.ViewingMonster.Config.Name;
this.Armour.text = String(Game.ViewingMonster.Armour);
switch (Game.ViewingMonster.Config.StrongAgainst){
case DamageTypes.Nothing:
this.Strength.text = "Nothing";
break;
case DamageTypes.Piercing:
this.Strength.text = "Piercing";
break;
case DamageTypes.Impact:
this.Strength.text = "Impact";
break;
case DamageTypes.Fire:
this.Strength.text = "Fire";
break;
case DamageTypes.Poison:
this.Strength.text = "Poison";
break;
case DamageTypes.Ice:
this.Strength.text = "Ice";
break;
};
switch (Game.ViewingMonster.Config.WeakAgainst){
case DamageTypes.Nothing:
this.Weakness.text = "Nothing";
break;
case DamageTypes.Piercing:
this.Weakness.text = "Piercing";
break;
case DamageTypes.Impact:
this.Weakness.text = "Impact";
break;
case DamageTypes.Fire:
this.Weakness.text = "Fire";
break;
case DamageTypes.Poison:
this.Weakness.text = "Poison";
break;
case DamageTypes.Ice:
this.Weakness.text = "Ice";
break;
};
switch (_arg1.Config.ImmuneAgainst){
case ImmuneTypes.Nothing:
this.Immune.visible = false;
break;
case ImmuneTypes.Fire:
this.Immune.bitmapData = AbilityIcons.Fire;
this.Immune.visible = true;
break;
case ImmuneTypes.Ice:
this.Immune.bitmapData = AbilityIcons.Ice;
this.Immune.visible = true;
break;
case ImmuneTypes.Poison:
this.Immune.bitmapData = AbilityIcons.Poison;
this.Immune.visible = true;
break;
};
this.Refresh();
Game.MainBar.ShowMonsterInfo();
Game.MainBar.ShowBuildMenu();
Game.ViewingTower = null;
Game.ViewingBuilding = null;
}
public function Refresh():void{
var _local1:int;
var _local2:int;
if (Game.ViewingMonster.HitPoints < 1){
Game.ViewingMonster = null;
Game.MainBar.ShowRoundInfo();
return;
};
this.HitPoints.text = ((Game.ViewingMonster.HitPoints + " / ") + Game.ViewingMonster.StartHitPoints);
this.Bar.width = ((Game.ViewingMonster.HitPoints / Game.ViewingMonster.StartHitPoints) * 70);
_local1 = 0;
while (_local1 < Status.length) {
this.Status[_local1].visible = false;
_local1++;
};
_local2 = 0;
if (Monster.HasEffect(Game.ViewingMonster, ImbueTypes.Fire)){
this.Status[_local2].bitmapData = AbilityIcons.Fire;
this.Status[_local2].visible = true;
this.Status.visible = true;
_local2++;
};
if (Monster.HasEffect(Game.ViewingMonster, ImbueTypes.Ice)){
this.Status[_local2].bitmapData = AbilityIcons.Ice;
this.Status[_local2].visible = true;
this.Status.visible = true;
_local2++;
};
if (Monster.HasEffect(Game.ViewingMonster, ImbueTypes.Poison)){
this.Status[_local2].bitmapData = AbilityIcons.Poison;
this.Status[_local2].visible = true;
this.Status.visible = true;
_local2++;
};
}
}
}//package TowerDefence.Interface
Section 191
//NextRoundTimer (TowerDefence.Interface.NextRoundTimer)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.display.*;
import flash.media.*;
import flash.events.*;
import flash.text.*;
import Assets.*;
public class NextRoundTimer extends MovieClip {
public var Seconds:TextField;
public var ClickText:TextField;
public var Label:TextField;
private static var RoundBeginning:Sound;
public function NextRoundTimer(){
this.x = 42;
this.y = 44;
this.buttonMode = true;
this.useHandCursor = true;
this.addEventListener(MouseEvent.CLICK, EndCountDown);
this.visible = false;
this.Label.text = Game.Language.NextRoundStartingIn;
this.ClickText.text = Game.Language.NextRoundClickText;
Game.STAGE.addChild(this);
}
public function Refresh():void{
var _local1:int;
if (((!(Game.CountingToNextRound)) || (Game.Pause))){
return;
};
if (Game.RoundNumber == 1){
this.visible = true;
this.Seconds.text = "--";
return;
};
Game.NextRoundTicks--;
_local1 = Math.ceil((Game.NextRoundTicks / Game.BaseFrameRate));
if (Game.NextRoundTicks > 0){
this.visible = true;
this.Seconds.text = _local1.toString();
return;
};
EndCountDown();
}
public function EndCountDown(_arg1:MouseEvent=null):void{
this.visible = false;
SoundManager.PlaySound(RoundBeginning);
Statistics.PreviousLives = Statistics.Lives;
Game.CountingToNextRound = false;
Game.Playing = true;
}
public static function Init():void{
RoundBeginning = new RoundBeginning();
}
}
}//package TowerDefence.Interface
Section 192
//ResearchImbueButton (TowerDefence.Interface.ResearchImbueButton)
package TowerDefence.Interface {
import TowerDefence.*;
import TowerDefence.Buildings.*;
import flash.events.*;
public class ResearchImbueButton extends ActionButton {
public var ImbueType:int;
public function ResearchImbueButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.ImageHolder.scrollRect = ActionButton.UpRectangle;
this.OnClick = DoClick;
}
public static function Enable(_arg1:ActionButton):void{
_arg1.buttonMode = true;
_arg1.useHandCursor = true;
_arg1.Enabled = true;
_arg1.ImageHolder.scrollRect = ActionButton.UpRectangle;
}
private static function LimitReached(_arg1:ResearchImbueButton):Boolean{
if (_arg1.ImbueType == ImbueUpgrades.Fire){
return ((Game.FireBonus == 75));
};
if (_arg1.ImbueType == ImbueUpgrades.Ice){
return ((Game.IceBonus == 75));
};
if (_arg1.ImbueType == ImbueUpgrades.Poison){
return ((Game.PoisonBonus == 75));
};
return (false);
}
public static function Click(_arg1:MouseEvent):void{
var _local2:ResearchImbueButton;
_local2 = (_arg1.target as ResearchImbueButton);
DoClick(_local2);
}
public static function Refresh(_arg1:ResearchImbueButton):void{
if (((((!(Game.ResearchingImbue)) && ((ImbueUpgrades.Price <= Statistics.Gold)))) && (!(LimitReached(_arg1))))){
Enable(_arg1);
} else {
Disable(_arg1);
};
}
public static function DoClick(_arg1:ResearchImbueButton):void{
if (!_arg1.Enabled){
return;
};
Statistics.Gold = (Statistics.Gold - _arg1.Price);
Statistics.MonsterKills.Monster4 = String((int(Statistics.MonsterKills.Monster4) - _arg1.Price));
Statistics.TowerKills.Tower3 = Number((int(Statistics.TowerKills.Tower3) - _arg1.Price));
Statistics.MissilesFired.Missile2 = uint((int(Statistics.MissilesFired.Missile2) - _arg1.Price));
Research.ImbueType = _arg1.ImbueType;
Research.ImbueClock = 0;
Game.ResearchingImbue = true;
Game.MainBar.ShowBuildingInfo();
Game.MainBar.Researching.Bar.width = 0;
Game.MainBar.ActionTip.visible = false;
Game.MainBar.Refresh();
}
private static function Disable(_arg1:ActionButton):void{
_arg1.buttonMode = false;
_arg1.useHandCursor = false;
_arg1.Enabled = false;
_arg1.ImageHolder.scrollRect = ActionButton.DisabledRectangle;
}
}
}//package TowerDefence.Interface
Section 193
//Researching (TowerDefence.Interface.Researching)
package TowerDefence.Interface {
public dynamic class Researching extends TowerProgress {
}
}//package TowerDefence.Interface
Section 194
//ResearchTechnologyButton (TowerDefence.Interface.ResearchTechnologyButton)
package TowerDefence.Interface {
import TowerDefence.*;
import TowerDefence.Buildings.*;
import flash.events.*;
public class ResearchTechnologyButton extends ActionButton {
public var TechnologyType:int;
public function ResearchTechnologyButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.ImageHolder.scrollRect = ActionButton.UpRectangle;
this.OnClick = DoClick;
}
public static function Enable(_arg1:ActionButton):void{
_arg1.buttonMode = true;
_arg1.useHandCursor = true;
_arg1.Enabled = true;
_arg1.ImageHolder.scrollRect = ActionButton.UpRectangle;
}
private static function LimitReached(_arg1:ResearchTechnologyButton):Boolean{
if (_arg1.TechnologyType == TechnologyUpgrades.Damage){
return ((Game.DamageBonus == 30));
};
if (_arg1.TechnologyType == TechnologyUpgrades.Range){
return ((Game.RangeBonus == 30));
};
return (false);
}
public static function Click(_arg1:MouseEvent):void{
var _local2:ResearchTechnologyButton;
_local2 = (_arg1.target as ResearchTechnologyButton);
DoClick(_local2);
}
public static function Refresh(_arg1:ResearchTechnologyButton):void{
if (((((!(Game.ResearchingTechnology)) && ((TechnologyUpgrades.Price <= Statistics.Gold)))) && (!(LimitReached(_arg1))))){
Enable(_arg1);
} else {
Disable(_arg1);
};
}
public static function DoClick(_arg1:ResearchTechnologyButton):void{
if (!_arg1.Enabled){
return;
};
Statistics.Gold = (Statistics.Gold - _arg1.Price);
Statistics.MonsterKills.Monster4 = String((int(Statistics.MonsterKills.Monster4) - _arg1.Price));
Statistics.TowerKills.Tower3 = Number((int(Statistics.TowerKills.Tower3) - _arg1.Price));
Statistics.MissilesFired.Missile2 = uint((int(Statistics.MissilesFired.Missile2) - _arg1.Price));
Research.TechnologyType = _arg1.TechnologyType;
Research.TechnologyClock = 0;
Game.ResearchingTechnology = true;
Game.MainBar.ShowBuildingInfo();
Game.MainBar.Researching.Bar.width = 0;
Game.MainBar.ActionTip.visible = false;
Game.MainBar.Refresh();
}
private static function Disable(_arg1:ActionButton):void{
_arg1.buttonMode = false;
_arg1.useHandCursor = false;
_arg1.Enabled = false;
_arg1.ImageHolder.scrollRect = ActionButton.DisabledRectangle;
}
}
}//package TowerDefence.Interface
Section 195
//RoundButton (TowerDefence.Interface.RoundButton)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.display.*;
import flash.geom.*;
import flash.events.*;
import flash.text.*;
import Assets.Interface.*;
public class RoundButton extends MovieClip {
public var Description:String;
public var Enabled:Boolean;// = false
public var Image:Bitmap;
public var RoundNumber:TextField;
public var Round:int;
private static const EnabledRectangle:Rectangle = new Rectangle(0, 0, 20, 20);
private static const DisabledRectangle:Rectangle = new Rectangle(0, 40, 20, 20);
private static const CurrentRectangle:Rectangle = new Rectangle(0, 20, 20, 20);
private static var RoundButtonImage:BitmapData;
public function RoundButton(_arg1:int=0){
Enabled = false;
super();
if (Game.STAGE == null){
return;
};
this.Round = _arg1;
this.RoundNumber.text = _arg1.toString();
this.Image = new Bitmap(RoundButtonImage);
this.Image.scrollRect = EnabledRectangle;
this.addChildAt(this.Image, 0);
this.buttonMode = true;
this.mouseChildren = false;
this.useHandCursor = true;
this.addEventListener(MouseEvent.MOUSE_OVER, Over);
this.addEventListener(MouseEvent.MOUSE_OUT, Out);
}
public static function Init():void{
RoundButtonImage = new RoundButton(20, 60);
}
private static function Over(_arg1:MouseEvent):void{
var _local2:RoundButton;
_local2 = (_arg1.target as RoundButton);
if (!_local2.Enabled){
return;
};
Game.MainBar.RoundTip.Show(_local2.Round, _local2.Description);
}
private static function Out(_arg1:MouseEvent):void{
var _local2:RoundButton;
_local2 = (_arg1.target as RoundButton);
if (!_local2.Enabled){
return;
};
Game.MainBar.RoundTip.visible = false;
}
public static function Refresh(_arg1:RoundButton):void{
if (_arg1.Round > Game.Level.Rounds.length){
_arg1.RoundNumber.textColor = 0x333333;
_arg1.Enabled = false;
_arg1.useHandCursor = false;
_arg1.Image.scrollRect = DisabledRectangle;
return;
};
if (_arg1.Round == Game.RoundNumber){
_arg1.RoundNumber.textColor = 0xFFCC00;
_arg1.Enabled = true;
_arg1.useHandCursor = true;
_arg1.Image.scrollRect = CurrentRectangle;
} else {
_arg1.RoundNumber.textColor = 0x999999;
_arg1.Enabled = true;
_arg1.useHandCursor = true;
_arg1.Image.scrollRect = EnabledRectangle;
};
}
}
}//package TowerDefence.Interface
Section 196
//RoundInfo (TowerDefence.Interface.RoundInfo)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.display.*;
import flash.text.*;
public class RoundInfo extends MovieClip {
public var LevelNumber:TextField;
private static var Buttons:Array = new Array(24);
public function RoundInfo(){
var _local1:*;
var _local2:RoundButton;
var _local3:int;
var _local4:int;
super();
this.visible = false;
this.x = 162;
this.y = 52;
_local1 = 1;
_local3 = 0;
while (_local3 < 3) {
_local4 = 0;
while (_local4 < 10) {
_local2 = new RoundButton(_local1);
_local2.x = (4 + (_local4 * 24));
_local2.y = (22 + (_local3 * 24));
this.addChild(_local2);
Buttons[(_local1 - 1)] = _local2;
_local1++;
_local4++;
};
_local3++;
};
}
public function SetupRoundInfo():void{
var _local1:int;
LevelNumber.text = ((Game.Language.Level + " ") + Game.LevelNumber);
_local1 = 0;
while (_local1 < Buttons.length) {
if (_local1 < Game.Level.Rounds.length){
Buttons[_local1].Description = Game.Level.Rounds[_local1].Description;
} else {
Buttons[_local1].Description = "";
};
RoundButton.Refresh(Buttons[_local1]);
_local1++;
};
}
public function Refresh():void{
var _local1:int;
_local1 = 0;
while (_local1 < Buttons.length) {
RoundButton.Refresh(Buttons[_local1]);
_local1++;
};
}
}
}//package TowerDefence.Interface
Section 197
//RoundTip (TowerDefence.Interface.RoundTip)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.display.*;
import flash.text.*;
public class RoundTip extends MovieClip {
public var Description:TextField;
public var Title:TextField;
public function RoundTip(){
this.x = ((Game.Width - this.width) / 2);
this.y = ((0 - this.height) + 10);
this.visible = false;
}
public function Show(_arg1:int, _arg2:String):void{
this.Title.text = ("Round " + _arg1);
this.Description.text = _arg2;
this.visible = true;
}
}
}//package TowerDefence.Interface
Section 198
//SellButton (TowerDefence.Interface.SellButton)
package TowerDefence.Interface {
import TowerDefence.*;
import TowerDefence.Towers.*;
import flash.events.*;
public class SellButton extends ActionButton {
public function SellButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.ImageHolder.scrollRect = ActionButton.UpRectangle;
this.OnClick = DoClick;
}
override public function ShowToolTip():void{
if ((((this.Title == null)) || ((this.Description == null)))){
return;
};
Game.MainBar.ActionTip.Show(this.Title, this.Description, Math.round((Game.ViewingTower.TotalSpent * 0.5)));
}
public static function Click(_arg1:MouseEvent):void{
var _local2:SellButton;
_local2 = (_arg1.target as SellButton);
DoClick(_local2);
}
public static function Refresh(_arg1:SellButton):void{
if (((_arg1.Enabled) && (((Game.ViewingTower.Upgrading) || (Game.ViewingTower.Imbueing))))){
Disable(_arg1);
} else {
if (((!(_arg1.Enabled)) && (((!(Game.ViewingTower.Upgrading)) && (!(Game.ViewingTower.Imbueing)))))){
Enable(_arg1);
};
};
}
public static function DoClick(_arg1:SellButton):void{
if (!_arg1.Enabled){
return;
};
Tower.Sell();
CancelTowerButton.DoClick(null);
}
}
}//package TowerDefence.Interface
Section 199
//SpecialBuildButton (TowerDefence.Interface.SpecialBuildButton)
package TowerDefence.Interface {
import TowerDefence.*;
import TowerDefence.Buildings.*;
import flash.events.*;
public class SpecialBuildButton extends ActionButton {
public var Config:BuildingConfig;
public var MenuItems:Array;
public function SpecialBuildButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.removeEventListener(MouseEvent.MOUSE_OUT, Out);
this.addEventListener(MouseEvent.MOUSE_OUT, NewOut);
this.ImageHolder.scrollRect = ActionButton.UpRectangle;
this.OnClick = DoClick;
}
private static function AllowCommit(_arg1:SpecialBuildButton):Boolean{
var _local2:int;
var _local3:int;
if ((((Game.GridLocation.Y >= Game.Level.Layer1.length)) || ((Game.GridLocation.X >= Game.Level.Layer1[0].length)))){
return (false);
};
_local2 = Game.GridLocation.X;
while (_local2 < (Game.GridLocation.X + _arg1.Config.Width)) {
_local3 = Game.GridLocation.Y;
while (_local3 < (Game.GridLocation.Y + _arg1.Config.Height)) {
if (Game.Level.Buildable[_local3][_local2] == false){
Message.SetMessage("Can't build there...");
return (false);
};
_local3++;
};
_local2++;
};
if (_arg1.Config.Price > Statistics.Gold){
Message.SetMessage("Need more gold...");
StopPlacingBuilding(_arg1);
return (false);
};
return (true);
}
public static function Enable(_arg1:SpecialBuildButton):void{
_arg1.buttonMode = true;
_arg1.useHandCursor = true;
_arg1.Enabled = true;
if (((Game.PlacingBuilding) && ((Game.PlacingBuildingType == _arg1.Config)))){
_arg1.ImageHolder.scrollRect = ActionButton.DownRectangle;
} else {
_arg1.ImageHolder.scrollRect = ActionButton.UpRectangle;
};
}
public static function StopPlacingBuilding(_arg1:SpecialBuildButton=null):void{
if (!Game.PlacingBuilding){
return;
};
Game.PlacingBuilding = false;
Game.PlacingBuildingType = null;
Game.HandCursor = false;
if (_arg1 != null){
_arg1.ImageHolder.scrollRect = UpRectangle;
};
Game.MainBar.Refresh();
}
public static function Commit(_arg1:SpecialBuildButton):void{
if (((Game.Pause) || (!(Game.PlacingBuilding)))){
return;
};
if (!AllowCommit(_arg1)){
return;
};
Building.Create(_arg1.Config);
Statistics.Gold = (Statistics.Gold - _arg1.Config.Price);
Statistics.MonsterKills.Monster4 = String((int(Statistics.MonsterKills.Monster4) - _arg1.Config.Price));
Statistics.TowerKills.Tower3 = Number((int(Statistics.TowerKills.Tower3) - _arg1.Config.Price));
Statistics.MissilesFired.Missile2 = uint((int(Statistics.MissilesFired.Missile2) - _arg1.Config.Price));
StopPlacingBuilding(_arg1);
if (_arg1.Config.Title == "Workshop"){
Game.HasWorkshop = true;
} else {
if (_arg1.Config.Title == "Laboratory"){
Game.HasLaboratory = true;
};
};
Refresh(_arg1);
}
public static function Click(_arg1:MouseEvent):void{
DoClick((_arg1.target as SpecialBuildButton));
}
public static function Refresh(_arg1:SpecialBuildButton):void{
if ((((_arg1.Config.Title == "Workshop")) && (Game.HasWorkshop))){
Disable(_arg1);
return;
};
if ((((_arg1.Config.Title == "Laboratory")) && (Game.HasLaboratory))){
Disable(_arg1);
return;
};
if (_arg1.Config.Price > Statistics.Gold){
Disable(_arg1);
} else {
if (_arg1.Config.Price <= Statistics.Gold){
Enable(_arg1);
};
};
}
public static function DoClick(_arg1:SpecialBuildButton):void{
var button = _arg1;
if (!button.Enabled){
return;
};
if ((((button.Config.Title == "Workshop")) && (Game.HasWorkshop))){
return;
};
if ((((button.Config.Title == "Laboratory")) && (Game.HasLaboratory))){
return;
};
if (Statistics.Gold < button.Config.Price){
Message.SetMessage("Need more gold...");
return;
};
if ((((Game.PlacingBuilding == true)) && ((Game.PlacingBuildingType == button.Config)))){
StopPlacingBuilding(button);
return;
};
if (Game.PlacingBuilding == true){
StopPlacingBuilding(button);
};
button.ImageHolder.scrollRect = ActionButton.DownRectangle;
Game.PlacingBuilding = true;
Game.PlacingBuildingType = button.Config;
Game.MapClickZone.Click = function (){
Commit(button);
};
Game.HandCursor = true;
Game.MainBar.ActionTip.visible = false;
}
private static function NewOut(_arg1:MouseEvent):void{
var _local2:SpecialBuildButton;
_local2 = (_arg1.target as SpecialBuildButton);
if (_local2.Enabled == false){
return;
};
if (((Game.PlacingBuilding) && ((Game.PlacingBuildingType == _local2.Config)))){
_local2.ImageHolder.scrollRect = ActionButton.DownRectangle;
} else {
if (_local2.Config.Price <= Statistics.Gold){
_local2.ImageHolder.scrollRect = ActionButton.UpRectangle;
};
};
Game.MainBar.ActionTip.visible = false;
}
public static function Disable(_arg1:SpecialBuildButton):void{
_arg1.buttonMode = false;
_arg1.useHandCursor = false;
_arg1.Enabled = false;
_arg1.ImageHolder.scrollRect = ActionButton.DisabledRectangle;
}
}
}//package TowerDefence.Interface
Section 200
//StatusBar (TowerDefence.Interface.StatusBar)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
import TowerDefence.Screens.*;
import flash.net.*;
public class StatusBar extends MovieClip {
private var CurrentKills:int;// = -1
private var CurrentLives:int;// = -1
public var KillsLabel:TextField;
public var SpeedButton:StatusBarButton;
public var GoldLabel:TextField;
private var CurrentGold:int;// = -1
public var MaxGamesButton:SimpleButton;
public var Gold:TextField;
public var MenuButton:StatusBarButton;
public var LivesLabel:TextField;
public var Kills:TextField;
public var Lives:TextField;
public function StatusBar(){
CurrentGold = -1;
CurrentLives = -1;
CurrentKills = -1;
super();
if (Game.STAGE == null){
return;
};
this.x = 0;
this.y = 0;
this.LivesLabel.text = Game.Language.Lives;
this.KillsLabel.text = Game.Language.Kills;
this.GoldLabel.text = Game.Language.Gold;
this.SpeedButton.Label.text = Game.Language.Speed;
this.MenuButton.Label.text = Game.Language.Menu;
this.MenuButton.addEventListener(MouseEvent.CLICK, ShowMenu);
this.SpeedButton.addEventListener(MouseEvent.CLICK, ToggleSpeed);
this.MaxGamesButton.addEventListener(MouseEvent.CLICK, MaxGames);
Game.STAGE.addChild(this);
}
private function ShowMenu(_arg1:MouseEvent):void{
new GameMenu();
}
private function ToggleSpeed(_arg1:MouseEvent):void{
Game.LowGraphicsMode = !(Game.LowGraphicsMode);
if (Game.LowGraphicsMode){
Game.STAGE.frameRate = (Game.BaseFrameRate * 2);
MiniMap.BaseRefreshCounter = 30;
} else {
Game.STAGE.frameRate = Game.BaseFrameRate;
MiniMap.BaseRefreshCounter = 15;
};
}
public function Refresh():void{
if (CurrentGold != Statistics.Gold){
CurrentGold = Statistics.Gold;
this.Gold.text = String(CurrentGold);
};
if (CurrentLives != Statistics.Lives){
CurrentLives = Statistics.Lives;
this.Lives.text = String(CurrentLives);
};
if (CurrentKills != Statistics.Kills){
CurrentKills = Statistics.Kills;
this.Kills.text = String(CurrentKills);
};
}
private static function MaxGames(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.maxgames.com/"), "_blank");
}
}
}//package TowerDefence.Interface
Section 201
//StatusBarButton (TowerDefence.Interface.StatusBarButton)
package TowerDefence.Interface {
import flash.display.*;
import flash.events.*;
import flash.text.*;
public class StatusBarButton extends MovieClip {
public var Label:TextField;
public function StatusBarButton(){
this.buttonMode = true;
this.mouseChildren = false;
this.useHandCursor = true;
this.addEventListener(MouseEvent.MOUSE_OVER, Over);
this.addEventListener(MouseEvent.MOUSE_OUT, Out);
this.alpha = 0.8;
}
private static function Over(_arg1:MouseEvent):void{
var _local2:StatusBarButton;
_local2 = (_arg1.target as StatusBarButton);
_local2.Label.textColor = 0xFFCC00;
_local2.alpha = 1;
}
private static function Out(_arg1:MouseEvent):void{
var _local2:StatusBarButton;
_local2 = (_arg1.target as StatusBarButton);
_local2.Label.textColor = 0xCCCCCC;
_local2.alpha = 0.8;
}
}
}//package TowerDefence.Interface
Section 202
//TargetButton (TowerDefence.Interface.TargetButton)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.events.*;
public class TargetButton extends ActionButton {
public var TargetMode:int;
public function TargetButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.removeEventListener(MouseEvent.MOUSE_OUT, Out);
this.addEventListener(MouseEvent.MOUSE_OUT, NewOut);
this.OnClick = DoClick;
}
public static function Click(_arg1:MouseEvent):void{
var _local2:TargetButton;
_local2 = (_arg1.target as TargetButton);
DoClick(_local2);
}
public static function Refresh(_arg1:TargetButton):void{
if (Game.ViewingTower.TargetMode == _arg1.TargetMode){
_arg1.ImageHolder.scrollRect = ActionButton.DownRectangle;
} else {
_arg1.ImageHolder.scrollRect = ActionButton.UpRectangle;
};
}
public static function DoClick(_arg1:TargetButton):void{
Game.ViewingTower.TargetMode = _arg1.TargetMode;
Game.MainBar.Refresh();
Game.MainBar.TowerInfo.Refresh();
Game.MainBar.ActionTip.visible = false;
}
private static function NewOut(_arg1:MouseEvent):void{
var _local2:TargetButton;
_local2 = (_arg1.target as TargetButton);
if (Game.ViewingTower.TargetMode == _local2.TargetMode){
_local2.ImageHolder.scrollRect = ActionButton.DownRectangle;
} else {
_local2.ImageHolder.scrollRect = ActionButton.UpRectangle;
};
Game.MainBar.ActionTip.visible = false;
}
}
}//package TowerDefence.Interface
Section 203
//TargetMenuButton (TowerDefence.Interface.TargetMenuButton)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.events.*;
public class TargetMenuButton extends ActionButton {
public function TargetMenuButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.ImageHolder.scrollRect = ActionButton.UpRectangle;
this.OnClick = DoClick;
}
public static function Click(_arg1:MouseEvent):void{
var _local2:TargetMenuButton;
_local2 = (_arg1.target as TargetMenuButton);
DoClick(_local2);
}
public static function Refresh(_arg1:TargetMenuButton):void{
if (((((_arg1.Enabled) && (((Game.ViewingTower.Upgrading) || (Game.ViewingTower.Imbueing))))) || ((Game.ViewingTower.Config.HasTargeting == false)))){
Disable(_arg1);
} else {
if (((!(_arg1.Enabled)) && (((!(Game.ViewingTower.Upgrading)) && (!(Game.ViewingTower.Imbueing)))))){
Enable(_arg1);
};
};
}
public static function DoClick(_arg1:TargetMenuButton):void{
if (!_arg1.Enabled){
return;
};
Game.MainBar.ShowTargetMenu();
}
}
}//package TowerDefence.Interface
Section 204
//TowerImbueing (TowerDefence.Interface.TowerImbueing)
package TowerDefence.Interface {
public dynamic class TowerImbueing extends TowerProgress {
}
}//package TowerDefence.Interface
Section 205
//TowerInfo (TowerDefence.Interface.TowerInfo)
package TowerDefence.Interface {
import TowerDefence.*;
import TowerDefence.Towers.*;
import flash.display.*;
import flash.text.*;
public class TowerInfo extends MovieClip {
public var Range:TextField;
public var TargetMode:TextField;
public var Speed:TextField;
public var Title:TextField;
public var Image:Bitmap;
public var Abilities:Array;
public var Special:TextField;
public var Damage:TextField;
public var AbilitiesLabel:TextField;
public function TowerInfo(){
var _local1:Bitmap;
var _local2:int;
Abilities = new Array(4);
super();
this.visible = false;
this.x = 162;
this.y = 52;
this.Image = new Bitmap();
this.Image.x = 0;
this.Image.y = 0;
this.addChild(this.Image);
this.AbilitiesLabel.text = Game.Language.Abilities;
_local2 = 0;
while (_local2 < 4) {
_local1 = new Bitmap();
_local1.x = (168 + (_local2 * 24));
_local1.y = 60;
this.addChild(_local1);
this.Abilities[_local2] = _local1;
_local2++;
};
}
public function Show(_arg1:Tower):void{
Game.ViewingTower = _arg1;
Game.ViewingMonster = null;
Game.ViewingBuilding = null;
this.Image.bitmapData = _arg1.Config.Thumbnail;
this.Refresh();
Game.MainBar.ShowTowerInfo();
Game.MainBar.ShowTowerMenu();
}
public function Refresh():void{
var _local1:Boolean;
var _local2:int;
_local1 = (Game.ViewingTower.Config.SpecialEffect == SpecialEffects.Nothing);
this.Title.text = Game.ViewingTower.Config.Title;
this.Damage.text = ((Game.ViewingTower.CurrentLevel.DamageMin + " - ") + Game.ViewingTower.CurrentLevel.DamageMax);
this.Speed.text = (Trim((Game.ViewingTower.CurrentLevel.FireRate / Game.BaseFrameRate)) + " sec");
this.Special.text = "";
if (Game.DamageBonus > 0){
this.Damage.appendText((" +" + Game.DamageBonus));
};
if (Game.ViewingTower.Bonus > 0){
this.Damage.appendText(((" +" + (Game.ViewingTower.Bonus * 10)) + "%"));
};
if (Game.ViewingTower.Config.Title == "Death Tower"){
this.Damage.text = "All in range suffer";
};
this.Range.text = Game.ViewingTower.CurrentLevel.Range.toString();
if (Game.RangeBonus > 0){
this.Range.appendText((" + " + Game.RangeBonus));
};
if (_local1){
this.Title.appendText(((" (L" + (Game.ViewingTower.CurrentLevelIndex + 1)) + ")"));
this.AbilitiesLabel.visible = true;
} else {
this.AbilitiesLabel.visible = false;
};
switch (Game.ViewingTower.TargetMode){
case TargetModes.Automatic:
this.TargetMode.text = "Automatic";
break;
case TargetModes.Closest:
this.TargetMode.text = "Closest";
break;
case TargetModes.Furthest:
this.TargetMode.text = "Furthest";
break;
case TargetModes.Weakest:
this.TargetMode.text = "Weakest";
break;
case TargetModes.Strongest:
this.TargetMode.text = "Strongest";
break;
};
_local2 = 0;
while (_local2 < Abilities.length) {
this.Abilities[_local2].visible = false;
_local2++;
};
switch (Game.ViewingTower.Imbue){
case ImbueTypes.Fire:
this.Abilities[0].bitmapData = AbilityIcons.Fire;
this.Abilities[0].visible = true;
this.Special.text = ((Game.ViewingTower.CurrentLevel.DamageDuration + Game.FireBonus) + " over time");
break;
case ImbueTypes.Ice:
this.Abilities[0].bitmapData = AbilityIcons.Ice;
this.Abilities[0].visible = true;
this.Special.text = (("Slowed for " + Trim(((Game.ViewingTower.CurrentLevel.DamageDuration + Game.IceBonus) / Game.BaseFrameRate))) + " seconds");
break;
case ImbueTypes.Poison:
this.Abilities[0].bitmapData = AbilityIcons.Poison;
this.Abilities[0].visible = true;
this.Special.text = ((Game.ViewingTower.CurrentLevel.DamageDuration + Game.PoisonBonus) + " over time");
break;
};
Game.MainBar.Refresh();
}
private static function Trim(_arg1:Number):String{
var _local2:*;
var _local3:*;
_local2 = _arg1.toString();
if (_local2.indexOf(".") == -1){
return (_arg1.toString());
};
_local3 = _local2.substring((_local2.indexOf(".") + 1));
if (_local3.length > 2){
_local3 = _local3.substring(0, 2);
};
return ((_local2.substring(0, (_local2.indexOf(".") + 1)) + _local3));
}
}
}//package TowerDefence.Interface
Section 206
//TowerProgress (TowerDefence.Interface.TowerProgress)
package TowerDefence.Interface {
import flash.display.*;
import flash.text.*;
public class TowerProgress extends MovieClip {
public var Bar:MovieClip;
public var Label:TextField;
public function TowerProgress(){
this.visible = false;
this.x = 162;
this.y = 52;
}
}
}//package TowerDefence.Interface
Section 207
//TowerUpgrading (TowerDefence.Interface.TowerUpgrading)
package TowerDefence.Interface {
public dynamic class TowerUpgrading extends TowerProgress {
}
}//package TowerDefence.Interface
Section 208
//UpgradeButton (TowerDefence.Interface.UpgradeButton)
package TowerDefence.Interface {
import TowerDefence.*;
import TowerDefence.Towers.*;
import flash.events.*;
public class UpgradeButton extends ActionButton {
public function UpgradeButton(){
this.addEventListener(MouseEvent.CLICK, Click);
this.ImageHolder.scrollRect = ActionButton.UpRectangle;
this.OnClick = DoClick;
}
override public function ShowToolTip():void{
if (Game.ViewingTower.NextLevel == null){
return;
};
if (Game.ViewingTower.Config.Title == "Generator"){
Game.MainBar.ActionTip.Show(Game.Language.UpgradeGeneratorTitle, Game.Language.UpgradeGeneratorDescription, Game.ViewingTower.NextLevel.Price);
} else {
Game.MainBar.ActionTip.Show(this.Title, this.Description, Game.ViewingTower.NextLevel.Price);
};
}
public static function Click(_arg1:MouseEvent):void{
var _local2:UpgradeButton;
_local2 = (_arg1.target as UpgradeButton);
DoClick(_local2);
}
public static function Refresh(_arg1:UpgradeButton):void{
if (((((((Game.ViewingTower.Upgrading) || (Game.ViewingTower.Imbueing))) || ((Game.ViewingTower.NextLevel == null)))) || ((Game.ViewingTower.NextLevel.Price > Statistics.Gold)))){
Disable(_arg1);
} else {
if (((((((!(Game.ViewingTower.Upgrading)) && (!(Game.ViewingTower.Imbueing)))) && (!((Game.ViewingTower.NextLevel == null))))) && ((Game.ViewingTower.NextLevel.Price <= Statistics.Gold)))){
Enable(_arg1);
};
};
}
public static function DoClick(_arg1:UpgradeButton):void{
if (!_arg1.Enabled){
return;
};
Tower.Upgrade();
Game.MainBar.ShowTowerInfo();
Game.MainBar.TowerUpgrading.Bar.width = 0;
Game.MainBar.ActionTip.visible = false;
}
}
}//package TowerDefence.Interface
Section 209
//WorkshopInfo (TowerDefence.Interface.WorkshopInfo)
package TowerDefence.Interface {
import TowerDefence.*;
import flash.display.*;
import TowerDefence.Buildings.*;
import flash.text.*;
public class WorkshopInfo extends MovieClip {
public var Description:TextField;
public var RangeBonus:TextField;
public var Title:TextField;
public var Image:Bitmap;
public var DamageLabel:TextField;
public var RangeLabel:TextField;
public var DamageBonus:TextField;
public function WorkshopInfo(){
this.visible = false;
this.x = 162;
this.y = 52;
this.RangeLabel.text = Game.Language.Range;
this.DamageLabel.text = Game.Language.Damage;
this.Image = new Bitmap();
this.Image.x = 0;
this.Image.y = 0;
this.addChild(this.Image);
}
public function Show(_arg1:Building):void{
if (this.Title.text == Game.ViewingBuilding.Config.Title){
return;
};
Game.ViewingBuilding = _arg1;
this.visible = true;
this.Image.bitmapData = _arg1.Config.Thumbnail;
this.Title.text = _arg1.Config.Title;
this.Description.text = _arg1.Config.Description;
this.Refresh();
Game.MainBar.ShowBuildingInfo();
Game.MainBar.ShowWorkshopMenu();
Game.ViewingTower = null;
Game.ViewingMonster = null;
}
public function Refresh():void{
this.RangeBonus.text = Game.RangeBonus.toString();
this.DamageBonus.text = Game.DamageBonus.toString();
}
}
}//package TowerDefence.Interface
Section 210
//Language (TowerDefence.Languages.Language)
package TowerDefence.Languages {
public class Language {
public var ClosestDescription:String;
public var SellTitle:String;
public var ImbueComplete:String;
public var WeakestTitle:String;
public var Status:String;
public var PoisonTowerTitle:String;
public var NextRoundStartingIn:String;
public var Easy:String;
public var Speed:String;
public var LaboratoryDescription:String;
public var HelpText:String;
public var ImbueIceHotKey:int;
public var StrongestTitle:String;
public var ScoutTowerDescription:String;
public var WeakestDescription:String;
public var VictoryText:String;
public var MyPersonalBests:String;
public var LaboratoryTitle:String;
public var Researching:String;
public var DeathTowerTitle:String;
public var ScoutTowerTitle:String;
public var ResearchRangeDescription:String;
public var Fire:String;
public var DeathTowerHotKey:int;
public var UpgradeDescription:String;
public var Strength:String;
public var ImbueMenuHotKey:int;
public var UpgradeGeneratorTitle:String;
public var SniperTowerDescription:String;
public var Ice:String;
public var Quit:String;
public var CannonTowerDescription:String;
public var ClosestHotKey:int;
public var Imbueing:String;
public var Credits:String;
public var PoisonTowerDescription:String;
public var ReturnToGame:String;
public var Gold:String;
public var HighScores:String;
public var LaboratoryHotKey:int;
public var FurthestTitle:String;
public var ResearchDamageHotKey:int;
public var ImbueMenuDescription:String;
public var ResearchDamageDescription:String;
public var ResearchFireTitle:String;
public var ImbuePoisonTitle:String;
public var Immune:String;
public var ResearchFireDescription:String;
public var SniperTowerHotKey:int;
public var ImbueFireTitle:String;
public var Kills:String;
public var GameStartText:String;
public var ImbueIceDescription:String;
public var FurthestHotKey:int;
public var ResearchFireHotKey:int;
public var ImbuePoisonDescription:String;
public var TurnMusicOff:String;
public var AutomaticHotKey:int;
public var CreditsText:String;
public var NextRoundClickText:String;
public var SellHotKey:int;
public var Lives:String;
public var WorkshopTitle:String;
public var RoundDesc1:String;
public var PoisonTowerHotKey:int;
public var RoundDesc4:String;
public var Username:String;
public var RoundDesc6:String;
public var AutomaticDescription:String;
public var RoundDesc8:String;
public var RoundDesc3:String;
public var RoundDesc2:String;
public var FireTowerHotKey:int;
public var RoundDesc9:String;
public var Hard:String;
public var ResearchIceDescription:String;
public var AutomaticTitle:String;
public var StrongestDescription:String;
public var RoundDesc7:String;
public var Range:String;
public var DefeatText:String;
public var StrongestHotKey:int;
public var RoundDesc5:String;
public var Poison:String;
public var FastSpeed:String;
public var TargetMenuDescription:String;
public var Abilities:String;
public var SellDescription:String;
public var ImbueMenuTitle:String;
public var ResearchRangeTitle:String;
public var ArrowTowerDescription:String;
public var SniperTowerTitle:String;
public var UpgradeGeneratorDescription:String;
public var GeneratorDescription:String;
public var Defeat:String;
public var UpgradeComplete:String;
public var WorkshopHotKey:int;
public var ImbueIceTitle:String;
public var ResearchPoisonHotKey:int;
public var ImbueFireDescription:String;
public var WeakestHotKey:int;
public var Help:String;
public var Level:String;
public var GeneratorTitle:String;
public var GeneratorHotKey:int;
public var FurthestDescription:String;
public var ResearchDamageTitle:String;
public var ResearchIceTitle:String;
public var ResearchPoisonDescription:String;
public var EnergyTowerHotKey:int;
public var ResearchPoisonTitle:String;
public var PlayMoreGames:String;
public var ScoutTowerHotKey:int;
public var GreatRoundBonus:String;
public var Menu:String;
public var NormalSpeed:String;
public var RoundDesc15:String;
public var TurnMusicOn:String;
public var TargetMenuTitle:String;
public var RoundDesc14:String;
public var RoundDesc16:String;
public var RoundDesc10:String;
public var Damage:String;
public var Armour:String;
public var ArrowTowerHotKey:int;
public var RoundDesc17:String;
public var Medium:String;
public var RoundDesc19:String;
public var EnergyTowerTitle:String;
public var RoundDesc13:String;
public var IceTowerTitle:String;
public var TurnSoundOff:String;
public var RoundDesc18:String;
public var ArrowTowerTitle:String;
public var RoundDesc11:String;
public var TargetMenuHotKey:int;
public var RoundDesc26:String;
public var RoundDesc20:String;
public var FireTowerDescription:String;
public var RoundDesc27:String;
public var RoundDesc28:String;
public var RoundDesc12:String;
public var DeathTowerDescription:String;
public var RoundDesc23:String;
public var RoundDesc25:String;
public var RoundDesc29:String;
public var RoundDesc21:String;
public var ClosestTitle:String;
public var Upgrading:String;
public var ResearchRangeHotKey:int;
public var RoundDesc31:String;
public var IceTowerDescription:String;
public var RoundDesc33:String;
public var ResetPersonalBests:String;
public var RoundDesc22:String;
public var ResearchIceHotKey:int;
public var UpgradeTitle:String;
public var FireTowerTitle:String;
public var RoundDesc34:String;
public var RoundDesc30:String;
public var CannonTowerTitle:String;
public var RoundDesc32:String;
public var ImbuePoisonHotKey:int;
public var IceTowerHotKey:int;
public var WorkshopDescription:String;
public var Close:String;
public var RoundDesc24:String;
public var CannonTowerHotKey:int;
public var UpgradeHotKey:int;
public var Weakness:String;
public var TurnSoundOn:String;
public var Victory:String;
public var GoodRoundBonus:String;
public var EnergyTowerDescription:String;
public var ImbueFireHotKey:int;
public static var English = new (Language);
;
public static var Spanish = new (Language);
;
English.Easy = "Easy";
English.Medium = "Medium";
English.Hard = "Hard";
English.HighScores = "High Scores";
English.Help = "Help";
English.Credits = "Credits";
English.Username = "Username";
English.Kills = "Kills";
English.Close = "Close";
English.ReturnToGame = "Return to game";
English.ResetPersonalBests = "Reset personal bests";
English.Quit = "Quit to main menu";
English.FastSpeed = "Fast gamespeed";
English.NormalSpeed = "Normal gamespeed";
English.TurnSoundOff = "Turn sound off";
English.TurnSoundOn = "Turn sound on";
English.TurnMusicOff = "Turn music off";
English.TurnMusicOn = "Turn music on";
English.Level = "Level";
English.MyPersonalBests = "My personal bests";
English.Lives = "Lives";
English.Gold = "Gold";
English.Victory = "Victory!";
English.Speed = "Speed";
English.Menu = "Menu";
English.Ice = "Ice";
English.Fire = "Fire";
English.Poison = "Poison";
English.Armour = "Armor";
English.Strength = "Strength";
English.Weakness = "Weakness";
English.Immune = "Immune";
English.Status = "Status";
English.NextRoundStartingIn = "Next round starting in";
English.NextRoundClickText = "Click here or press spacebar to start";
English.Researching = "Researching";
English.Imbueing = "Imbueing";
English.Upgrading = "Upgrading";
English.Range = "Range";
English.Damage = "Damage";
English.Abilities = "Abilities";
English.GoodRoundBonus = "Good round bonus";
English.GreatRoundBonus = "Great round bonus";
English.UpgradeComplete = "Upgrade complete";
English.ImbueComplete = "Imbue complete";
English.PlayMoreGames = "Play more games at maxgames.com";
English.ArrowTowerTitle = "[A]rrow Tower";
English.ArrowTowerDescription = "The arrow tower is cheap and fast but not very strong. It can be upgraded five times and imbued once with fire, ice or poison.";
English.ArrowTowerHotKey = 65;
English.CannonTowerTitle = "[C]annon Tower";
English.CannonTowerDescription = "The cannon tower hits harder than the arrow tower but is not as fast. It can be upgraded five times and imbued once with fire, ice or poison.";
English.CannonTowerHotKey = 67;
English.IceTowerTitle = "[I]ce Tower";
English.IceTowerDescription = "The ice tower freezes enemies to slow them down to allow other towers to hit them more. It can be upgraded 5 times.";
English.IceTowerHotKey = 73;
English.PoisonTowerTitle = "[P]oison Tower";
English.PoisonTowerDescription = "The poison tower does significant damage to enemies over time. It can be upgraded 5 times.";
English.PoisonTowerHotKey = 80;
English.FireTowerTitle = "[F]ire Tower";
English.FireTowerDescription = "The fire tower does massive damage and burns enemies over time. It can be upgraded 5 times.";
English.FireTowerHotKey = 70;
English.ScoutTowerTitle = "[S]cout Tower";
English.ScoutTowerDescription = "The scout tower reveals all invisible enemies within range allowing other towers to target them.";
English.ScoutTowerHotKey = 83;
English.EnergyTowerTitle = "[E]nergy Tower";
English.EnergyTowerDescription = "The energy tower does up to 300 raw damage to every kind of enemy.";
English.EnergyTowerHotKey = 69;
English.SniperTowerTitle = "S[n]iper Tower";
English.SniperTowerDescription = "The sniper tower has long range and hits hard, but is slow to fire.";
English.SniperTowerHotKey = 78;
English.GeneratorTitle = "[G]enerator Tower";
English.GeneratorDescription = "The generator tower increases the damage of all towers within its range.";
English.GeneratorHotKey = 71;
English.DeathTowerTitle = "[D]eath Tower";
English.DeathTowerDescription = "The death tower does significant damage to every monster in range.";
English.DeathTowerHotKey = 68;
English.WorkshopTitle = "[W]orkshop";
English.WorkshopDescription = "The workshop lets you research better technologies for your towers.";
English.WorkshopHotKey = 71;
English.LaboratoryTitle = "[L]aboratory";
English.LaboratoryDescription = "The laboratory lets you research magical technologies.";
English.LaboratoryHotKey = 68;
English.UpgradeTitle = "[U]pgrade";
English.UpgradeDescription = "Upgrade this tower to give it higher damage, further range, a faster firing rate and to increase the effect of any imbue or natural abilities.";
English.UpgradeHotKey = 85;
English.UpgradeGeneratorTitle = "[U]pgrade generator";
English.UpgradeGeneratorDescription = "Upgrade the generator to give it more range.";
English.ImbueMenuTitle = "[I]mbue";
English.ImbueMenuDescription = "Add a small amount of fire, poison or ice damage to this tower.";
English.ImbueMenuHotKey = 73;
English.TargetMenuTitle = "[T]arget mode";
English.TargetMenuDescription = "Choose which targeting mode to use for this tower.";
English.TargetMenuHotKey = 84;
English.SellTitle = "[S]ell";
English.SellDescription = "Sell this tower and recoup some of the money you've spent on it.";
English.SellHotKey = 83;
English.AutomaticTitle = "[A]utomatic";
English.AutomaticDescription = "This target mode calculates how many hits are required to kill each enemy in range and selects the easiest.";
English.AutomaticHotKey = 65;
English.ClosestTitle = "[C]losest";
English.ClosestDescription = "This target mode makes the tower always select the closest enemy, perfect for magical or imbued towers.";
English.ClosestHotKey = 67;
English.FurthestTitle = "[F]urthest";
English.FurthestDescription = "This targeting mode selects the enemy furthest away.";
English.FurthestHotKey = 70;
English.WeakestTitle = "[W]eakest";
English.WeakestDescription = "This mode makes the tower target the enemy with the least hit points within range.";
English.WeakestHotKey = 87;
English.StrongestTitle = "[S]trongest";
English.StrongestDescription = "This targeting mode selects the enemy with the most hit points within range.";
English.StrongestHotKey = 83;
English.ImbueIceTitle = "[I]ce imbue";
English.ImbueIceDescription = "Add ice damage to this tower, allowing it to slow enemies for a short period of time.";
English.ImbueIceHotKey = 73;
English.ImbuePoisonTitle = "[P]oison imbue";
English.ImbuePoisonDescription = "Add poison damage to this tower. Poison damage is applied gradually over a short period of time.";
English.ImbuePoisonHotKey = 80;
English.ImbueFireTitle = "[F]ire imbue";
English.ImbueFireDescription = "Add fire damage to this tower and your enemies will burn for a short period of time.";
English.ImbueFireHotKey = 70;
English.ResearchIceTitle = "Research [I]ce";
English.ResearchIceDescription = "Upgrade all ice towers and ice imbued towers so monsters freeze longer.";
English.ResearchIceHotKey = 73;
English.ResearchPoisonTitle = "Research [P]oison";
English.ResearchPoisonDescription = "Upgrade all poison towers and poison imbued towers to poison monsters for longer.";
English.ResearchPoisonHotKey = 80;
English.ResearchFireTitle = "Research [F]ire";
English.ResearchFireDescription = "Upgrade all fire towers and fire imbued towers to do burn monsters longer.";
English.ResearchFireHotKey = 70;
English.ResearchDamageTitle = "[D]amage";
English.ResearchDamageDescription = "Increase the damage of all of your towers.";
English.ResearchDamageHotKey = 84;
English.ResearchRangeTitle = "[R]ange";
English.ResearchRangeDescription = "Increase the range of all of your towers.";
English.ResearchRangeHotKey = 84;
English.RoundDesc1 = "Eyes, the advanced scouts of any Horde army";
English.RoundDesc2 = "Eyes and boars sent to test your defenses and distract your towers";
English.RoundDesc3 = "More boars";
English.RoundDesc4 = "Peons and boars";
English.RoundDesc5 = "Waves of peons";
English.RoundDesc6 = "The peons will distract your towers while the trolls slip through";
English.RoundDesc7 = "Waves of trolls";
English.RoundDesc8 = "Trolls and their big brothers, troll berserkers";
English.RoundDesc9 = "More troll berserkers";
English.RoundDesc10 = "Grunts and troll berserkers";
English.RoundDesc11 = "More grunts";
English.RoundDesc12 = "Grunts and their big brothers, grunt berserkers";
English.RoundDesc13 = "More grunt berserkers";
English.RoundDesc14 = "Grunt berserkers and human mercenaries";
English.RoundDesc15 = "More mercenaries";
English.RoundDesc16 = "Mercenary Boss";
English.RoundDesc17 = "Dwarven mercenaries";
English.RoundDesc18 = "More Dwarven mercenaries";
English.RoundDesc19 = "Dwarf Boss";
English.RoundDesc20 = "Troll berserkers";
English.RoundDesc21 = "Grunt berserkers";
English.RoundDesc22 = "Human mercenaries";
English.RoundDesc23 = "Sappers";
English.RoundDesc24 = "More sappers";
English.RoundDesc25 = "Ogre Boss";
English.RoundDesc26 = "Infected ogres";
English.RoundDesc27 = "More infected ogres";
English.RoundDesc28 = "Ogre spirits (invisible!!)";
English.RoundDesc29 = "Mercenary Knights";
English.RoundDesc30 = "More mercenary knights";
English.RoundDesc31 = "Knight boss";
English.RoundDesc32 = "Ogre spirits, peon and troll scouts (invisible!!)";
English.RoundDesc33 = "Death knights";
English.RoundDesc34 = "Demons";
English.VictoryText = " You have driven the horde back to their vile lands. \x16No more shall they oppress your people and ravage your kingdom.<br><br>Now is the time to gather your armies, prepare your revenge, and ready yourself to destroy the horde once and for all.";
English.Defeat = "Defeat!";
English.DefeatText = "You have lost, your lands lie conquered, your people dead or enslaved.";
English.HelpText = "The Horde is a tower defense game. The objective is to stop waves of monsters from reaching the other side of each map.<br><br><b>Towers</b><br>You can build towers by clicking the type you want from the bottom right and clicking on the map. Click a tower you have built to upgrade, imbue or set the targeting mode.<br><br><b>Imbueing towers</b><br>Gives towers a special power, although not as strong as the magical towers.<br><br><b>Monsters</b><br>Monsters have strengths, weaknesses and magical immunities. Click a monster to view its info.<br><br><b>The playing area</b><br>You can move around the map either by pressing the arrow keys or clicking on the minimap. Click-and-drag on the minimap to watch as you move around.<br><br><b>Saving your progress</b><br>Each time you complete a level your progress is automatically saved allowing you to continue from whichever level you are up to if you close the game and come back later.";
English.CreditsText = "Graphics and sounds come from a variety of sources, most notably the sounds, monster and tower sprites are from <b><a href=\"http://www.blizzard.com/\">Warcraft 2 and Warcraft 3</a></b>. These elements were used without permission.<br><br>The game map tiles are from <b><a href=\"http://lostgarden.com/\">Daniel Cook's Lost Garden</a></b>, a great resource for any game dev who lacks artistic ability and the funds to afford it. You can download the tiles from <b><a href=\"http://lostgarden.com/2006/07/more-free-game-graphics.html\">this page</a></b> as well as other awesome free graphics from <b><a href=\"http://lostgarden.com/labels/free%20game%20graphics.html\">here</a></b>.<br><br>Other graphics come from the great design community <b><a href=\"http://www.deviantart.com/\">Deviant Art</a></b>. The big orc background is from <b><a href=\"http://x-zm.deviantart.com/art/Warcraft-53002635\">Antonio Gomez</a></b> and the map from Deviant user <b><a href=\"http://arlekin.deviantart.com/art/Map-Antium-92639459\">arlekin</a></b>.<br><br>Although an original game The Horde was derived from the always great Warcraft series, particularly tower defence maps in Warcraft 3. If you haven't played TD in Warcraft 3 you are really missing out, especially if you've only played Flash tower defense games. If you have Warcraft 3 you might want to download <b><a href=\"http://warcraft3.filefront.com/file/Tower_Defence_MapPack;45201\">this tower defense map pack.</a></b>";
English.GameStartText = "The horde has attacked your country. Bloody and almost beaten you have regrouped in the only region that remains FREE.<br><br>It is time to fight back and drive the horde from your lands in 8 bloody tower defense battles.";
Spanish.Easy = "Facil";
Spanish.Medium = "Medio";
Spanish.Hard = "Dificil";
Spanish.HighScores = "Puntuaciones";
Spanish.Help = "Ayuda";
Spanish.Credits = "Creditos";
Spanish.Username = "Nombre de usuario";
Spanish.Kills = "Muertes";
Spanish.Close = "Cerrar";
Spanish.ReturnToGame = "Regresar al juego";
Spanish.ResetPersonalBests = "Borrar tu puntuacion";
Spanish.Quit = "Regresar al menu";
Spanish.FastSpeed = "Velocidad rapida";
Spanish.NormalSpeed = "Velocidad normal";
Spanish.TurnSoundOff = "Quitar sonido";
Spanish.TurnSoundOn = "Encender Sonido";
Spanish.TurnMusicOff = "Quitar musica";
Spanish.TurnMusicOn = "Encender Musica";
Spanish.Level = "Nivel";
Spanish.MyPersonalBests = "Mejores puntuaciones personales";
Spanish.Lives = "Vidas";
Spanish.Gold = "Oro";
Spanish.Victory = "Victoria";
Spanish.Speed = "Velocidad";
Spanish.Menu = "Menu";
Spanish.Ice = "Hielo";
Spanish.Fire = "Fuego";
Spanish.Poison = "Veneno";
Spanish.Armour = "Armadura";
Spanish.Strength = "Fuerza";
Spanish.Weakness = "Debilidad";
Spanish.Immune = "Immunidad";
Spanish.Status = "Estado";
Spanish.NextRoundStartingIn = "La proxima ronda comienza en...";
Spanish.NextRoundClickText = "Presiona aqui o presiona start para comenzar";
Spanish.Researching = "Buscando";
Spanish.Imbueing = "Imbuyendo";
Spanish.Upgrading = "Mejorando";
Spanish.Range = "Alcance";
Spanish.Damage = "Daño";
Spanish.Abilities = "Habilidades";
Spanish.GoodRoundBonus = "Bonus de ronda buena";
Spanish.GreatRoundBonus = "Bonus de ronda excelente";
Spanish.UpgradeComplete = "Mejora completada";
Spanish.ImbueComplete = "Encantamiento finalizado";
Spanish.PlayMoreGames = "Mas juegos por jugar en maxgames.com";
Spanish.ArrowTowerTitle = "Torre de flechas";
Spanish.ArrowTowerDescription = "La torre de flechas es mas barate y rapida, pero no muy fuerte. Se puede mejorar cinco veces e imbuirla una con fuego, hielo o veneno.";
Spanish.ArrowTowerHotKey = 65;
Spanish.CannonTowerTitle = "Torre de cañon";
Spanish.CannonTowerDescription = "La torre de cañon golpea mas fuerte que la torre de flechas pero no es tan rapida. Se puede mejorar cinco veces e imbuirla una con fuego, hielo o veneno.";
Spanish.CannonTowerHotKey = 67;
Spanish.IceTowerTitle = "Torre de hielo";
Spanish.IceTowerDescription = "La torre de hielo congela al enemigo para disminuir su velocidad y permitir a otras torres golpearlo mas. Se puede mejorar cinco veces.";
Spanish.IceTowerHotKey = 73;
Spanish.PoisonTowerTitle = "Torre de veneno";
Spanish.PoisonTowerDescription = "La torre de veneno provoca un daño significativo al enemigo durante un tiempo. Se puede mejorar cinco veces.";
Spanish.PoisonTowerHotKey = 80;
Spanish.FireTowerTitle = "Torre de fuego";
Spanish.FireTowerDescription = "La torre de fuego provoca un daño masivo y quema al enemigo durante un tiempo. Se puede mejorar cinco veces.";
Spanish.FireTowerHotKey = 70;
Spanish.ScoutTowerTitle = "Torre vigia";
Spanish.ScoutTowerDescription = "La torre vigia revela todos los enemigos invisibles que se encuentren en el alcance de la misma, permitiendo a otras torres apuntarlos.";
Spanish.ScoutTowerHotKey = 83;
Spanish.EnergyTowerTitle = "Torre de energia";
Spanish.EnergyTowerDescription = "La torre de energia provoca hasta 300 de daño basico a todo tipo de enemigo.";
Spanish.EnergyTowerHotKey = 69;
Spanish.SniperTowerTitle = "Torre de francotirador";
Spanish.SniperTowerDescription = "La torre de francotirador tiene un alto alcance y provoca grandes daños, pero dispara mas lentamente.";
Spanish.SniperTowerHotKey = 78;
Spanish.GeneratorTitle = "Torre generador";
Spanish.GeneratorDescription = "La torre generador aumenta el daño producido por todas las torres en su radio de alcance.";
Spanish.GeneratorHotKey = 71;
Spanish.DeathTowerTitle = "Torre mortal";
Spanish.DeathTowerDescription = "La torre mortal produce un daño significativo a todos los monstruos en el radio de alcance.";
Spanish.DeathTowerHotKey = 68;
Spanish.WorkshopTitle = "Taller";
Spanish.WorkshopDescription = "El taller te permite investigar mejores tecnologias para tus torres.";
Spanish.WorkshopHotKey = 71;
Spanish.LaboratoryTitle = "Laboratorio";
Spanish.LaboratoryDescription = "El laboratorio te permite investigar tecnologias magicas.";
Spanish.LaboratoryHotKey = 68;
Spanish.UpgradeTitle = "Mejoras";
Spanish.UpgradeDescription = "Mejora esta torre para darle un mayor daño, alcance superior, mas rapida velocidad de disparo y para incrementar el efecto de cualquier imbuicion o habilidad natural.";
Spanish.UpgradeHotKey = 85;
Spanish.UpgradeGeneratorTitle = "Mejoras generador";
Spanish.UpgradeGeneratorDescription = "Mejora esta generador para alance superior.";
Spanish.ImbueMenuTitle = "Imbuir";
Spanish.ImbueMenuDescription = "Añade una pequeña cantidad de daño fuego, veneno o hielo a esta torre.";
Spanish.ImbueMenuHotKey = 73;
Spanish.TargetMenuTitle = "Modo apuntar";
Spanish.TargetMenuDescription = "Escoge el estilo de apuntar de esta torre.";
Spanish.TargetMenuHotKey = 84;
Spanish.SellTitle = "Vender";
Spanish.SellDescription = "Vende esta torre y recupera parte del dinero invertido en ella.";
Spanish.SellHotKey = 83;
Spanish.AutomaticTitle = "Automatico";
Spanish.AutomaticDescription = "Este modo de apuntar calcula cuantos impactos son necesarios para matar a un enemigo dentro del radio de alcance y escoje el mas facil.";
Spanish.AutomaticHotKey = 65;
Spanish.ClosestTitle = "Cercano";
Spanish.ClosestDescription = "Este modo de apuntar hace que la torre elija siempre al enemigo mas cercano, perfecto para torres magicas o imbuidas.";
Spanish.ClosestHotKey = 67;
Spanish.FurthestTitle = "Lejano";
Spanish.FurthestDescription = "Este modo de apuntar elije al enemigo mas alejado.";
Spanish.FurthestHotKey = 70;
Spanish.WeakestTitle = "Mas debil";
Spanish.WeakestDescription = "Este modo hace que la torre apunte al enemigo con menos puntos de vida en el radio de alcance.";
Spanish.WeakestHotKey = 87;
Spanish.StrongestTitle = "Mas fuerte";
Spanish.StrongestDescription = "Este modo de apuntar elige al enemigo con mas puntos de vida en el radio de alcance.";
Spanish.StrongestHotKey = 83;
Spanish.ImbueIceTitle = "Imbuir en hielo";
Spanish.ImbueIceDescription = "Añade daño de hielo a esta torre, permitiendole disminuir la velocidad de los enemigos por un periodo corto de tiempo.";
Spanish.ImbueIceHotKey = 73;
Spanish.ImbuePoisonTitle = "Imbuir en veneno";
Spanish.ImbuePoisonDescription = "Añade daño de veneno a esta torre. El daño de veneno es aplicado gradualmente por un periodo corto de tiempo.";
Spanish.ImbuePoisonHotKey = 80;
Spanish.ImbueFireTitle = "Imbuir en fuego";
Spanish.ImbueFireDescription = "Añade daño de fuego a esta torre y tu enemigo ardera por un corto periodo de tiempo.";
Spanish.ImbueFireHotKey = 70;
Spanish.ResearchIceTitle = "Investigar hielo";
Spanish.ResearchIceDescription = "Mejora todas las torres de hielo y las imbuidas en hielo para que los monstruos permanezcan mas tiempo congelados.";
Spanish.ResearchIceHotKey = 73;
Spanish.ResearchPoisonTitle = "Investigar veneno";
Spanish.ResearchPoisonDescription = "Mejora todas las torres de veneno y las imbuidas en veneno para que el envenenamiento en los monstruos se mantenga por mas tiempo.";
Spanish.ResearchPoisonHotKey = 80;
Spanish.ResearchFireTitle = "Investigar fuego";
Spanish.ResearchFireDescription = "Mejora todas las torres de fuego y las imbuidas en fuego para que los monstruos ardan por mas tiempo.";
Spanish.ResearchFireHotKey = 70;
Spanish.ResearchDamageTitle = "Daño";
Spanish.ResearchDamageDescription = "Incrementa el daño producido por todas tus torres.";
Spanish.ResearchDamageHotKey = 84;
Spanish.ResearchRangeTitle = "Alcance";
Spanish.ResearchRangeDescription = "Incrementa el alcance de todas tus torres.";
Spanish.ResearchRangeHotKey = 84;
Spanish.RoundDesc1 = "Los ojos, los exploradores de cualquier ejercito de la Horda";
Spanish.RoundDesc2 = "Ojos y jabalis enviados para probar tus defensas y entretener a tus torres";
Spanish.RoundDesc3 = "Mas jabalis";
Spanish.RoundDesc4 = "Peones y jabalis";
Spanish.RoundDesc5 = "Oleadas de peones";
Spanish.RoundDesc6 = "Los peones distraerán a tus torres mientras los trolls pasan";
Spanish.RoundDesc7 = "Oleadas de trolls";
Spanish.RoundDesc8 = "Trolls y sus hermanos mayores, los troll bersekers";
Spanish.RoundDesc9 = "Más troll berserkers";
Spanish.RoundDesc10 = "Grunts y troll bersekers";
Spanish.RoundDesc11 = "Más grunts";
Spanish.RoundDesc12 = "Grunts y sus hermanos mayores, los grunt berserkers";
Spanish.RoundDesc13 = "Más grunt berserkers";
Spanish.RoundDesc14 = "Berserker grunt y mercenarios humanos";
Spanish.RoundDesc15 = "Más mercenarios";
Spanish.RoundDesc16 = "Jefe mercenario";
Spanish.RoundDesc17 = "Mercenarios enanos";
Spanish.RoundDesc18 = "Mas mercenarios enanos";
Spanish.RoundDesc19 = "Jefe enano";
Spanish.RoundDesc20 = "Troll berserkers";
Spanish.RoundDesc21 = "Grunt berserkers";
Spanish.RoundDesc22 = "Mercenarios humanos";
Spanish.RoundDesc23 = "Zapadores";
Spanish.RoundDesc24 = "Más zapadores";
Spanish.RoundDesc25 = "Jefe ogro";
Spanish.RoundDesc26 = "Ogros infectados";
Spanish.RoundDesc27 = "Más ogros infectados";
Spanish.RoundDesc28 = "Espíritus de ogro (invisibles!!)";
Spanish.RoundDesc29 = "Mercenarios a caballo";
Spanish.RoundDesc30 = "Más mercenarios a caballo";
Spanish.RoundDesc31 = "Jefe caballero";
Spanish.RoundDesc32 = "Espíritus de ogro, peones y exploradores troll (invisibles!!)";
Spanish.RoundDesc33 = "Caballeros de la muerte";
Spanish.RoundDesc34 = "Demonios";
Spanish.VictoryText = " Has conducido a la horda de vuelta a sus viles tierras. Ninguna mas va a oprimir tu tierra ni causar estragos en tu reino.<br><br>Ahora es el momento para reunir tus ejercitos, preparar tu venganza, y estar listo para destruir a la horda de una vez y para siempre.";
Spanish.Defeat = "¡Derrotado!";
Spanish.DefeatText = "Has sido derrotado, tus tierras conquistadas, y tus gentes han muerto o han sido tomadas como esclavos.";
Spanish.HelpText = "The Horde es un juego de defensa basado en torres. El objetivo es detener las hordas de monstruos y evitar que alcancen el otro lado del mapa.<br><br><b>Torres</b><br>Puedes construir torres pulsando en el tipo de torre que quieres en la parte inferior derecha y posteriormente en el mapa. Pulsa sobre una torre que has construido para mejorarla, imbuirla, o fijar el estilo de apuntar.<br><br><b>Imbuir torres</b><br>Proporciona a las torres un poder especial, aunque no igual de poderoso como las torres magicas.<br><br><b>Monstruos</b><br>Los monstruos tienen puntos fuertes, puntos debiles e inmunidades magicas. Pulsa en un monstruo para ver su informacion.<br><br><b>Zona de juego</b><br>Puedes moverte alrededor de la zona de juego ya sea con las flechas o pulsando a traves del minimapa. Aprieta en el mapa para verlo mientras te mueves por el..<br><br><b>Guardar tus progresos</b><br>Cada vez que completas un nivel tu progreso es salvado automaticamente, permitiendote continuar por el nivel en que lo dejaste si cerraste el juego y has vuelto mas tarde.";
Spanish.CreditsText = "Los graficos y sonidos provienen de una gran variedad de recursos, principalmente destacable los sonidos, monstruos y disparos de las torres provienen de <b><a href=\"http://www.blizzard.com/\">Warcraft 2 y Warcraft 3</a></b>. Estos elementos se han usado sin permiso.<br><br>Los graficos del mapa son de <b><a href=\"http://lostgarden.com/\">Daniel Cook's Lost Garden</a></b>, una gran fuente para cualquier creador de juegos que carece de la habilidad artistica y fondos para permitirsela. Podeis descargar los graficos de <b><a href=\"http://lostgarden.com/2006/07/more-free-game-graphics.html\">esta pagina</a></b> asi como otros fantasticos graficos gratis de <b><a href=\"http://lostgarden.com/labels/free%20game%20graphics.html\">aqui</a></b>.<br><br>Otros graficos provienen de la gran comunidad de diseño <b><a href=\"http://www.deviantart.com/\">Deviant Art</a></b>. El gran orco utilizado como fondo proviene de <b><a href=\"http://x-zm.deviantart.com/art/Warcraft-53002635\">Antonio Gomez</a></b> y el mapa del usuario de DeviantArt <b><a href=\"http://arlekin.deviantart.com/art/Map-Antium-92639459\">arlekin</a></b>.<br><br>Aunque el juego original de The Horde es un derivado de la gran serie del Warcraft, principalmente los mapas de torres defensivas. Si no has jugado al TD en Warcraft 3 te estas perdiendo algo, especialmente si has jugado a juegos de defensa con torres. Si tienes el Warcraft 3 tal vez quieras descargar <b><a href=\"http://warcraft3.filefront.com/file/Tower_Defence_MapPack;45201\">este pack de mapas de torres de defensa.</a></b>";
Spanish.GameStartText = "La horda ha atacado tu pais. Sangrante y practicamente derrotado, has logrado reagruparte en la unica region que permanece LIBRE.<br><br>Es el momento para contraatacar y conducir a la Horda fuera de tus tierras en 8 sangrientas batallas de torres.";
}
}//package TowerDefence.Languages
Section 211
//Level1 (TowerDefence.Levels.Level1)
package TowerDefence.Levels {
import TowerDefence.*;
import TowerDefence.Monsters.*;
import Assets.Tiles.*;
public class Level1 {
public static function Generate():LevelData{
var _local1:LevelData;
_local1 = LevelData.Create();
_local1.StartingGold = 60;
_local1.Tiles = new Array(23);
_local1.Tiles[0] = new Tree3(1, 1);
_local1.Tiles[1] = new Land3(1, 1);
_local1.Tiles[2] = new Tree1(1, 1);
_local1.Tiles[3] = new Land4(1, 1);
_local1.Tiles[4] = new Land2(1, 1);
_local1.Tiles[5] = new Land7(1, 1);
_local1.Tiles[6] = new Cliff20(1, 1);
_local1.Tiles[7] = new Cliff21(1, 1);
_local1.Tiles[8] = new Cliff22(1, 1);
_local1.Tiles[9] = new Cliff23(1, 1);
_local1.Tiles[10] = new Cliff1(1, 1);
_local1.Tiles[11] = new Cliff3(1, 1);
_local1.Tiles[12] = new Cliff2(1, 1);
_local1.Tiles[13] = new Cliff4(1, 1);
_local1.Tiles[14] = new Fence1(1, 1);
_local1.Tiles[15] = new Rock3(1, 1);
_local1.Tiles[16] = new House4(1, 1);
_local1.Tiles[17] = new House2(1, 1);
_local1.Tiles[18] = new House8(1, 1);
_local1.Tiles[19] = new House5(1, 1);
_local1.Tiles[20] = new Land6(1, 1);
_local1.Tiles[21] = new ArrowDown(1, 1);
_local1.Tiles[22] = new ArrowRight(1, 1);
_local1.Layer1 = new Array(30);
_local1.Layer1[0] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[1] = [undefined, undefined, undefined, 21, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[2] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[3] = [3, 22, 3, 4, 22, 3, 22, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 5, undefined, undefined];
_local1.Layer1[4] = [undefined, undefined, undefined, 21, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[5] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[6] = [undefined, undefined, undefined, 21, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[7] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[8] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[9] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[10] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[11] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[12] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[13] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[14] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[15] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[16] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[17] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[18] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[19] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[20] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[21] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[22] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[23] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 21, undefined, undefined];
_local1.Layer1[24] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[25] = [undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 21, undefined, undefined];
_local1.Layer1[26] = [undefined, undefined, undefined, 20, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 22, 3, 22, 4, 3, 22, 3];
_local1.Layer1[27] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer1[28] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 21, undefined, undefined];
_local1.Layer1[29] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined];
_local1.Layer2 = new Array(30);
_local1.Layer2[0] = [-1, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[1] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[2] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[3] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[4] = [undefined, undefined, undefined, undefined, undefined, -1, -1, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[5] = [undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, 6, undefined, 7, 7, 8, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[6] = [-1, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[7] = [-1, undefined, undefined, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 10, undefined, 11, 11, 11, 13, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[8] = [-1, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[9] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[10] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[11] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[12] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[13] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[14] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[15] = [undefined, undefined, undefined, undefined, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[16] = [undefined, undefined, undefined, undefined, undefined, 16, undefined, undefined, 16, undefined, undefined, 17, undefined, undefined, undefined, undefined, 15, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[17] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 18, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[18] = [undefined, undefined, undefined, undefined, undefined, undefined, 16, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 19, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[19] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[20] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[21] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[22] = [undefined, undefined, undefined, undefined, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[23] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[24] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[25] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[26] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[27] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[28] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[29] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Buildable = new Array();
_local1.Buildable[0] = [0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[1] = [0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[2] = [0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[3] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1];
_local1.Buildable[4] = [1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[5] = [1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[6] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[7] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[8] = [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[9] = [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[10] = [0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[11] = [0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[12] = [0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[13] = [0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[14] = [0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[15] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[16] = [1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[17] = [1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[18] = [1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1];
_local1.Buildable[19] = [1, 1, 1, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1];
_local1.Buildable[20] = [1, 1, 1, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1];
_local1.Buildable[21] = [1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1];
_local1.Buildable[22] = [1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1];
_local1.Buildable[23] = [1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 1, 1];
_local1.Buildable[24] = [1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[25] = [1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[26] = [1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[27] = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[28] = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1];
_local1.Buildable[29] = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1];
_local1.Paths = new Array(2);
_local1.Paths[0] = new Array(3);
_local1.Paths[0][0] = new SimplePoint(-1, 3);
_local1.Paths[0][1] = new SimplePoint(26, 3);
_local1.Paths[0][2] = new SimplePoint(26, 30);
_local1.Paths[1] = new Array(3);
_local1.Paths[1][0] = new SimplePoint(3, -1);
_local1.Paths[1][1] = new SimplePoint(3, 26);
_local1.Paths[1][2] = new SimplePoint(30, 26);
_local1.Rounds = new Array();
_local1.Rounds[0] = Round.Create(Game.Language.RoundDesc1);
_local1.Rounds[0].Waves[0] = Wave.Create(20, MonsterConfig.Eye, 40, 0);
_local1.Rounds[0].Waves[1] = Wave.Create(20, MonsterConfig.Eye, 40, 450);
_local1.Rounds[1] = Round.Create(Game.Language.RoundDesc2);
_local1.Rounds[1].Waves[0] = Wave.Create(19, MonsterConfig.Eye, 40, 0);
_local1.Rounds[1].Waves[1] = Wave.Create(19, MonsterConfig.Boar, 40, 425);
_local1.Rounds[2] = Round.Create(Game.Language.RoundDesc3);
_local1.Rounds[2].Waves[0] = Wave.Create(18, MonsterConfig.Boar, 40, 0);
_local1.Rounds[2].Waves[1] = Wave.Create(18, MonsterConfig.Boar, 40, 400);
_local1.Rounds[3] = Round.Create(Game.Language.RoundDesc4);
_local1.Rounds[3].Waves[0] = Wave.Create(17, MonsterConfig.Boar, 39, 0);
_local1.Rounds[3].Waves[1] = Wave.Create(17, MonsterConfig.Peon, 39, 375);
_local1.Rounds[4] = Round.Create(Game.Language.RoundDesc5);
_local1.Rounds[4].Waves[0] = Wave.Create(16, MonsterConfig.Peon, 39, 0);
_local1.Rounds[4].Waves[1] = Wave.Create(16, MonsterConfig.Peon, 39, 350);
_local1.Rounds[5] = Round.Create(Game.Language.RoundDesc6);
_local1.Rounds[5].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 39, 0);
_local1.Rounds[5].Waves[1] = Wave.Create(15, MonsterConfig.Troll, 39, 325);
_local1.Rounds[6] = Round.Create(Game.Language.RoundDesc7);
_local1.Rounds[6].Waves[0] = Wave.Create(15, MonsterConfig.Troll, 38, 0);
_local1.Rounds[6].Waves[1] = Wave.Create(15, MonsterConfig.Troll, 38, 300);
_local1.Rounds[7] = Round.Create(Game.Language.RoundDesc8);
_local1.Rounds[7].Waves[0] = Wave.Create(15, MonsterConfig.Troll, 38, 0);
_local1.Rounds[7].Waves[1] = Wave.Create(15, MonsterConfig.TrollBerserker, 38, 275);
_local1.Rounds[8] = Round.Create(Game.Language.RoundDesc9);
_local1.Rounds[8].Waves[0] = Wave.Create(14, MonsterConfig.TrollBerserker, 38, 0);
_local1.Rounds[8].Waves[1] = Wave.Create(14, MonsterConfig.TrollBerserker, 38, 250);
_local1.Rounds[9] = Round.Create(Game.Language.RoundDesc10);
_local1.Rounds[9].Waves[0] = Wave.Create(14, MonsterConfig.TrollBerserker, 37, 0);
_local1.Rounds[9].Waves[1] = Wave.Create(14, MonsterConfig.Grunt, 37, 225);
_local1.Rounds[10] = Round.Create(Game.Language.RoundDesc11);
_local1.Rounds[10].Waves[0] = Wave.Create(14, MonsterConfig.Grunt, 37, 0);
_local1.Rounds[10].Waves[1] = Wave.Create(14, MonsterConfig.Grunt, 37, 200);
_local1.Rounds[11] = Round.Create(Game.Language.RoundDesc12);
_local1.Rounds[11].Waves[0] = Wave.Create(15, MonsterConfig.Grunt, 37, 0);
_local1.Rounds[11].Waves[1] = Wave.Create(15, MonsterConfig.GruntBerserker, 37, 175);
_local1.Rounds[12] = Round.Create(Game.Language.RoundDesc13);
_local1.Rounds[12].Waves[0] = Wave.Create(14, MonsterConfig.GruntBerserker, 36, 0);
_local1.Rounds[12].Waves[1] = Wave.Create(14, MonsterConfig.GruntBerserker, 36, 150);
_local1.Rounds[13] = Round.Create(Game.Language.RoundDesc14);
_local1.Rounds[13].Waves[0] = Wave.Create(16, MonsterConfig.GruntBerserker, 36, 0);
_local1.Rounds[13].Waves[1] = Wave.Create(16, MonsterConfig.Mercenary, 36, 125);
_local1.Rounds[14] = Round.Create(Game.Language.RoundDesc15);
_local1.Rounds[14].Waves[0] = Wave.Create(15, MonsterConfig.Mercenary, 36, 0);
_local1.Rounds[14].Waves[1] = Wave.Create(15, MonsterConfig.Mercenary, 36, 100);
_local1.Rounds[15] = Round.Create(Game.Language.RoundDesc15);
_local1.Rounds[15].Waves[0] = Wave.Create(14, MonsterConfig.Mercenary, 35, 0);
_local1.Rounds[15].Waves[1] = Wave.Create(14, MonsterConfig.Mercenary, 35, 75);
_local1.Rounds[16] = Round.Create(Game.Language.RoundDesc16);
_local1.Rounds[16].Waves[0] = Wave.Create(1, MonsterConfig.MercenaryVeteran, 0, 0);
return (_local1);
}
}
}//package TowerDefence.Levels
Section 212
//Level2 (TowerDefence.Levels.Level2)
package TowerDefence.Levels {
import TowerDefence.*;
import TowerDefence.Monsters.*;
import Assets.Tiles.*;
public class Level2 {
public static function Generate():LevelData{
var _local1:LevelData;
_local1 = LevelData.Create();
_local1.StartingGold = 50;
_local1.Tiles = new Array(32);
_local1.Tiles[0] = new Cliff18(1, 1);
_local1.Tiles[1] = new Cliff17(1, 1);
_local1.Tiles[2] = new Cliff12(1, 1);
_local1.Tiles[3] = new Cliff4(1, 1);
_local1.Tiles[4] = new Tree1(1, 1);
_local1.Tiles[5] = new Land3(1, 1);
_local1.Tiles[6] = new Cliff24(1, 1);
_local1.Tiles[7] = new Cliff19(1, 1);
_local1.Tiles[8] = new Tree2(1, 1);
_local1.Tiles[9] = new ArrowDown(1, 1);
_local1.Tiles[10] = new Tree3(1, 1);
_local1.Tiles[11] = new Cliff1(1, 1);
_local1.Tiles[12] = new Cliff6(1, 1);
_local1.Tiles[13] = new Cliff7(1, 1);
_local1.Tiles[14] = new Cliff3(1, 1);
_local1.Tiles[15] = new Cliff2(1, 1);
_local1.Tiles[16] = new Tree4(1, 1);
_local1.Tiles[17] = new Land5(1, 1);
_local1.Tiles[18] = new Land4(1, 1);
_local1.Tiles[19] = new Land8(1, 1);
_local1.Tiles[20] = new Land6(1, 1);
_local1.Tiles[21] = new Land7(1, 1);
_local1.Tiles[22] = new Cliff23(1, 1);
_local1.Tiles[23] = new Cliff16(1, 1);
_local1.Tiles[24] = new Fence1(1, 1);
_local1.Tiles[25] = new Cliff11(1, 1);
_local1.Tiles[26] = new House2(1, 1);
_local1.Tiles[27] = new House5(1, 1);
_local1.Tiles[28] = new House4(1, 1);
_local1.Tiles[29] = new House6(1, 1);
_local1.Tiles[30] = new House8(1, 1);
_local1.Tiles[31] = new Cliff5(1, 1);
_local1.Layer1 = new Array(40);
_local1.Layer1[0] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[1] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[2] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[3] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[4] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[5] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[6] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[7] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[8] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[9] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[10] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[11] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[12] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[13] = [undefined, undefined, undefined, undefined, undefined, undefined, 17, 18, 18, 18, 18, 18, 18, 18, 18, 19, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 20, 18, 18, 18, 18, 18, 18, 18, 18, 21, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[14] = [undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[15] = [undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[16] = [undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[17] = [undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[18] = [undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[19] = [undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[20] = [undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[21] = [undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[22] = [undefined, undefined, undefined, undefined, undefined, undefined, 20, 18, 18, 18, 18, 18, 18, 18, 18, 21, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 17, 18, 18, 18, 18, 18, 18, 18, 18, 19, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[23] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[24] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[25] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[26] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[27] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[28] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[29] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[30] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[31] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[32] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[33] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[34] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[35] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[36] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[37] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[38] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[39] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2 = new Array(40);
_local1.Layer2[0] = [0, 0, 0, 1, 0, 0, 2, undefined, 3, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, undefined, 6, undefined, 0, 0, 0, 0, 0, 0, 7];
_local1.Layer2[1] = [0, 0, 1, 0, 0, 1, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, -1, 6, undefined, 7, 7, 0, 0, 7, 7, 0];
_local1.Layer2[2] = [0, 1, 0, 1, 1, 1, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, 11, undefined, 12, undefined, 7, 7, 7, 0, 0];
_local1.Layer2[3] = [0, 0, 0, 1, 2, undefined, 3, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined, 7, 7, 0, 7, 7];
_local1.Layer2[4] = [0, 1, 1, 1, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, 12, undefined, 0, 7, 7];
_local1.Layer2[5] = [0, 0, 1, 1, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, 7, 7, 7];
_local1.Layer2[6] = [0, 1, 13, 1, 3, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, 14, 14, 14];
_local1.Layer2[7] = [14, 15, undefined, undefined, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[8] = [undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[9] = [undefined, undefined, undefined, undefined, -1, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined];
_local1.Layer2[10] = [undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined];
_local1.Layer2[11] = [undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined];
_local1.Layer2[12] = [-1, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1];
_local1.Layer2[13] = [undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[14] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[15] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[16] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[17] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[18] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1];
_local1.Layer2[19] = [undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1];
_local1.Layer2[20] = [-1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, 4];
_local1.Layer2[21] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined];
_local1.Layer2[22] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1];
_local1.Layer2[23] = [undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, undefined];
_local1.Layer2[24] = [undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, -1, undefined];
_local1.Layer2[25] = [22, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[26] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[27] = [23, undefined, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, undefined, 24, 24, 24, 24, 24, 24, 24, 24, undefined, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24];
_local1.Layer2[28] = [25, undefined, 22, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 26, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 27, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[29] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 28, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 26, undefined, undefined, 26, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[30] = [0, 0, 23, undefined, undefined, undefined, undefined, 29, undefined, undefined, undefined, 28, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 30, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[31] = [31, undefined, 3, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 27, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[32] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 27, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[33] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 28, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 30, undefined, undefined, undefined, undefined, undefined, 30, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[34] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[35] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 28, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[36] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 27, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[37] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[38] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[39] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Buildable = new Array();
_local1.Buildable[0] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[1] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[2] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[3] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[4] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[5] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[6] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[7] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[8] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[9] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[10] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1];
_local1.Buildable[11] = [1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1];
_local1.Buildable[12] = [0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0];
_local1.Buildable[13] = [0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0];
_local1.Buildable[14] = [0, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0];
_local1.Buildable[15] = [0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1];
_local1.Buildable[16] = [0, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1];
_local1.Buildable[17] = [0, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1];
_local1.Buildable[18] = [1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0];
_local1.Buildable[19] = [1, 1, 0, 0, 0, 1, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 0, 0];
_local1.Buildable[20] = [0, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 0, 0];
_local1.Buildable[21] = [0, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 0, 0];
_local1.Buildable[22] = [0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0];
_local1.Buildable[23] = [0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0];
_local1.Buildable[24] = [0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0];
_local1.Buildable[25] = [0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1];
_local1.Buildable[26] = [0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1];
_local1.Buildable[27] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[28] = [0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[29] = [0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[30] = [0, 0, 0, 0, 1, 1, 1, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[31] = [0, 0, 0, 0, 1, 1, 1, 0, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[32] = [0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[33] = [0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[34] = [0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[35] = [0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[36] = [0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[37] = [1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[38] = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[39] = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Paths = new Array(2);
_local1.Paths[0] = new Array(6);
_local1.Paths[0][0] = new SimplePoint(15, -1);
_local1.Paths[0][1] = new SimplePoint(15, 13);
_local1.Paths[0][2] = new SimplePoint(6, 13);
_local1.Paths[0][3] = new SimplePoint(6, 22);
_local1.Paths[0][4] = new SimplePoint(15, 22);
_local1.Paths[0][5] = new SimplePoint(15, 39);
_local1.Paths[1] = new Array(6);
_local1.Paths[1][0] = new SimplePoint(24, -1);
_local1.Paths[1][1] = new SimplePoint(24, 13);
_local1.Paths[1][2] = new SimplePoint(33, 13);
_local1.Paths[1][3] = new SimplePoint(33, 22);
_local1.Paths[1][4] = new SimplePoint(24, 22);
_local1.Paths[1][5] = new SimplePoint(24, 39);
_local1.Rounds = new Array();
_local1.Rounds[0] = Round.Create(Game.Language.RoundDesc1);
_local1.Rounds[0].Waves[0] = Wave.Create(20, MonsterConfig.Eye, 40, 0);
_local1.Rounds[0].Waves[1] = Wave.Create(20, MonsterConfig.Eye, 40, 450);
_local1.Rounds[1] = Round.Create(Game.Language.RoundDesc2);
_local1.Rounds[1].Waves[0] = Wave.Create(19, MonsterConfig.Eye, 40, 0);
_local1.Rounds[1].Waves[1] = Wave.Create(19, MonsterConfig.Boar, 40, 425);
_local1.Rounds[2] = Round.Create(Game.Language.RoundDesc3);
_local1.Rounds[2].Waves[0] = Wave.Create(18, MonsterConfig.Boar, 40, 0);
_local1.Rounds[2].Waves[1] = Wave.Create(18, MonsterConfig.Boar, 40, 400);
_local1.Rounds[3] = Round.Create(Game.Language.RoundDesc4);
_local1.Rounds[3].Waves[0] = Wave.Create(17, MonsterConfig.Boar, 39, 0);
_local1.Rounds[3].Waves[1] = Wave.Create(17, MonsterConfig.Peon, 39, 375);
_local1.Rounds[4] = Round.Create(Game.Language.RoundDesc5);
_local1.Rounds[4].Waves[0] = Wave.Create(16, MonsterConfig.Peon, 39, 0);
_local1.Rounds[4].Waves[1] = Wave.Create(16, MonsterConfig.Peon, 39, 350);
_local1.Rounds[5] = Round.Create(Game.Language.RoundDesc6);
_local1.Rounds[5].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 39, 0);
_local1.Rounds[5].Waves[1] = Wave.Create(15, MonsterConfig.Troll, 39, 325);
_local1.Rounds[6] = Round.Create(Game.Language.RoundDesc7);
_local1.Rounds[6].Waves[0] = Wave.Create(15, MonsterConfig.Troll, 38, 0);
_local1.Rounds[6].Waves[1] = Wave.Create(15, MonsterConfig.Troll, 38, 300);
_local1.Rounds[7] = Round.Create(Game.Language.RoundDesc8);
_local1.Rounds[7].Waves[0] = Wave.Create(15, MonsterConfig.Troll, 38, 0);
_local1.Rounds[7].Waves[1] = Wave.Create(15, MonsterConfig.TrollBerserker, 38, 275);
_local1.Rounds[8] = Round.Create(Game.Language.RoundDesc9);
_local1.Rounds[8].Waves[0] = Wave.Create(14, MonsterConfig.TrollBerserker, 38, 0);
_local1.Rounds[8].Waves[1] = Wave.Create(14, MonsterConfig.TrollBerserker, 38, 250);
_local1.Rounds[9] = Round.Create(Game.Language.RoundDesc10);
_local1.Rounds[9].Waves[0] = Wave.Create(14, MonsterConfig.TrollBerserker, 37, 0);
_local1.Rounds[9].Waves[1] = Wave.Create(14, MonsterConfig.Grunt, 37, 225);
_local1.Rounds[10] = Round.Create(Game.Language.RoundDesc11);
_local1.Rounds[10].Waves[0] = Wave.Create(14, MonsterConfig.Grunt, 37, 0);
_local1.Rounds[10].Waves[1] = Wave.Create(14, MonsterConfig.Grunt, 37, 200);
_local1.Rounds[11] = Round.Create(Game.Language.RoundDesc12);
_local1.Rounds[11].Waves[0] = Wave.Create(15, MonsterConfig.Grunt, 37, 0);
_local1.Rounds[11].Waves[1] = Wave.Create(15, MonsterConfig.GruntBerserker, 37, 175);
_local1.Rounds[12] = Round.Create(Game.Language.RoundDesc13);
_local1.Rounds[12].Waves[0] = Wave.Create(14, MonsterConfig.GruntBerserker, 36, 0);
_local1.Rounds[12].Waves[1] = Wave.Create(14, MonsterConfig.GruntBerserker, 36, 150);
_local1.Rounds[13] = Round.Create(Game.Language.RoundDesc14);
_local1.Rounds[13].Waves[0] = Wave.Create(16, MonsterConfig.GruntBerserker, 36, 0);
_local1.Rounds[13].Waves[1] = Wave.Create(16, MonsterConfig.Mercenary, 36, 125);
_local1.Rounds[14] = Round.Create(Game.Language.RoundDesc15);
_local1.Rounds[14].Waves[0] = Wave.Create(15, MonsterConfig.Mercenary, 36, 0);
_local1.Rounds[14].Waves[1] = Wave.Create(15, MonsterConfig.Mercenary, 36, 100);
_local1.Rounds[15] = Round.Create(Game.Language.RoundDesc17);
_local1.Rounds[15].Waves[0] = Wave.Create(16, MonsterConfig.Dwarf, 36, 0);
_local1.Rounds[15].Waves[1] = Wave.Create(16, MonsterConfig.Dwarf, 36, 125);
_local1.Rounds[16] = Round.Create(Game.Language.RoundDesc18);
_local1.Rounds[16].Waves[0] = Wave.Create(15, MonsterConfig.Dwarf, 36, 0);
_local1.Rounds[16].Waves[1] = Wave.Create(15, MonsterConfig.Dwarf, 36, 100);
_local1.Rounds[17] = Round.Create(Game.Language.RoundDesc19);
_local1.Rounds[17].Waves[0] = Wave.Create(1, MonsterConfig.DwarfStone, 0, 0);
return (_local1);
}
}
}//package TowerDefence.Levels
Section 213
//Level3 (TowerDefence.Levels.Level3)
package TowerDefence.Levels {
import TowerDefence.*;
import TowerDefence.Monsters.*;
import Assets.Tiles.*;
public class Level3 {
public static function Generate():LevelData{
var _local1:LevelData;
_local1 = LevelData.Create();
_local1.StartingGold = 40;
_local1.Tiles = new Array(17);
_local1.Tiles[0] = new Cliff1(1, 1);
_local1.Tiles[1] = new Cliff6(1, 1);
_local1.Tiles[2] = new Cliff17(1, 1);
_local1.Tiles[3] = new Land4(1, 1);
_local1.Tiles[4] = new Land7(1, 1);
_local1.Tiles[5] = new Cliff10(1, 1);
_local1.Tiles[6] = new Tree1(1, 1);
_local1.Tiles[7] = new Tree3(1, 1);
_local1.Tiles[8] = new Land3(1, 1);
_local1.Tiles[9] = new Land5(1, 1);
_local1.Tiles[10] = new Land8(1, 1);
_local1.Tiles[11] = new Cliff13(1, 1);
_local1.Tiles[12] = new Cliff14(1, 1);
_local1.Tiles[13] = new Cliff23(1, 1);
_local1.Tiles[14] = new Cliff25(1, 1);
_local1.Tiles[15] = new Land6(1, 1);
_local1.Tiles[16] = new Cliff4(1, 1);
_local1.Tiles[17] = new ArrowRight(1, 1);
_local1.Layer1 = new Array(20);
_local1.Layer1[0] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[1] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[2] = [3, 17, 3, 17, 3, 17, 3, 3, 3, 3, 3, 3, 3, 4, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[3] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[4] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[5] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[6] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[7] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[8] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[9] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, 3, 3, 10, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[10] = [undefined, undefined, undefined, undefined, undefined, undefined, 9, 3, 3, 3, 10, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[11] = [undefined, undefined, undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[12] = [undefined, undefined, undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[13] = [undefined, undefined, undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[14] = [undefined, undefined, undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[15] = [undefined, undefined, undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[16] = [undefined, undefined, undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[17] = [undefined, undefined, undefined, undefined, undefined, undefined, 15, 3, 3, 3, 3, 3, 3, 17, 3, 17, 3, 17, 3, 3];
_local1.Layer1[18] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[19] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2 = new Array(20);
_local1.Layer2[0] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 0, undefined, 1, undefined, 2, 2];
_local1.Layer2[1] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 2, 2];
_local1.Layer2[2] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5];
_local1.Layer2[3] = [undefined, -1, -1, -1, -1, undefined, -1, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[4] = [-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[5] = [-1, -1, -1, -1, -1, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 0];
_local1.Layer2[6] = [-1, -1, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[7] = [undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[8] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined];
_local1.Layer2[9] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined];
_local1.Layer2[10] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined];
_local1.Layer2[11] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, -1, undefined, -1, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[12] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, -1, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[13] = [11, undefined, 12, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[14] = [undefined, undefined, undefined, undefined, 13, undefined, undefined, -1, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[15] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[16] = [2, 2, 2, 2, 14, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[17] = [2, 2, 2, 2, 14, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[18] = [2, 2, 2, 14, 16, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[19] = [2, 2, 2, 16, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Buildable = new Array();
_local1.Buildable[0] = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0];
_local1.Buildable[1] = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0];
_local1.Buildable[2] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[3] = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[4] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0];
_local1.Buildable[5] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0];
_local1.Buildable[6] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0];
_local1.Buildable[7] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 1, 0, 0];
_local1.Buildable[8] = [0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0];
_local1.Buildable[9] = [0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1];
_local1.Buildable[10] = [0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1];
_local1.Buildable[11] = [0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1];
_local1.Buildable[12] = [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[13] = [0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1];
_local1.Buildable[14] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1];
_local1.Buildable[15] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1];
_local1.Buildable[16] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[17] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[18] = [0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[19] = [0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Paths = new Array(1);
_local1.Paths[0] = new Array(8);
_local1.Paths[0][0] = new SimplePoint(-1, 2);
_local1.Paths[0][1] = new SimplePoint(13, 2);
_local1.Paths[0][2] = new SimplePoint(13, 9);
_local1.Paths[0][3] = new SimplePoint(10, 9);
_local1.Paths[0][4] = new SimplePoint(10, 10);
_local1.Paths[0][5] = new SimplePoint(6, 10);
_local1.Paths[0][6] = new SimplePoint(6, 17);
_local1.Paths[0][7] = new SimplePoint(20, 17);
_local1.Rounds = new Array();
_local1.Rounds[0] = Round.Create(Game.Language.RoundDesc1);
_local1.Rounds[0].Waves[0] = Wave.Create(15, MonsterConfig.Eye, 50, 0);
_local1.Rounds[0].Waves[1] = Wave.Create(15, MonsterConfig.Eye, 50, 25);
_local1.Rounds[1] = Round.Create(Game.Language.RoundDesc2);
_local1.Rounds[1].Waves[0] = Wave.Create(15, MonsterConfig.Eye, 50, 0);
_local1.Rounds[1].Waves[1] = Wave.Create(15, MonsterConfig.Eye, 50, 25);
_local1.Rounds[2] = Round.Create(Game.Language.RoundDesc3);
_local1.Rounds[2].Waves[0] = Wave.Create(15, MonsterConfig.Boar, 50, 0);
_local1.Rounds[2].Waves[1] = Wave.Create(15, MonsterConfig.Boar, 50, 25);
_local1.Rounds[3] = Round.Create(Game.Language.RoundDesc4);
_local1.Rounds[3].Waves[0] = Wave.Create(15, MonsterConfig.Boar, 50, 0);
_local1.Rounds[3].Waves[1] = Wave.Create(15, MonsterConfig.Boar, 50, 25);
_local1.Rounds[4] = Round.Create(Game.Language.RoundDesc5);
_local1.Rounds[4].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 48, 0);
_local1.Rounds[4].Waves[1] = Wave.Create(15, MonsterConfig.Peon, 48, 24);
_local1.Rounds[5] = Round.Create(Game.Language.RoundDesc6);
_local1.Rounds[5].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 48, 0);
_local1.Rounds[5].Waves[1] = Wave.Create(15, MonsterConfig.Peon, 48, 24);
_local1.Rounds[6] = Round.Create(Game.Language.RoundDesc7);
_local1.Rounds[6].Waves[0] = Wave.Create(14, MonsterConfig.Troll, 48, 0);
_local1.Rounds[6].Waves[1] = Wave.Create(14, MonsterConfig.Troll, 48, 24);
_local1.Rounds[7] = Round.Create(Game.Language.RoundDesc20);
_local1.Rounds[7].Waves[0] = Wave.Create(12, MonsterConfig.TrollBerserker, 48, 0);
_local1.Rounds[7].Waves[1] = Wave.Create(12, MonsterConfig.TrollBerserker, 48, 24);
_local1.Rounds[8] = Round.Create(Game.Language.RoundDesc9);
_local1.Rounds[8].Waves[0] = Wave.Create(11, MonsterConfig.TrollBerserker, 46, 0);
_local1.Rounds[8].Waves[1] = Wave.Create(11, MonsterConfig.TrollBerserker, 46, 23);
_local1.Rounds[9] = Round.Create(Game.Language.RoundDesc10);
_local1.Rounds[9].Waves[0] = Wave.Create(9, MonsterConfig.Grunt, 46, 0);
_local1.Rounds[9].Waves[1] = Wave.Create(9, MonsterConfig.Grunt, 46, 23);
_local1.Rounds[10] = Round.Create(Game.Language.RoundDesc11);
_local1.Rounds[10].Waves[0] = Wave.Create(8, MonsterConfig.Grunt, 46, 0);
_local1.Rounds[10].Waves[1] = Wave.Create(8, MonsterConfig.Grunt, 46, 23);
_local1.Rounds[11] = Round.Create(Game.Language.RoundDesc21);
_local1.Rounds[11].Waves[0] = Wave.Create(9, MonsterConfig.GruntBerserker, 46, 0);
_local1.Rounds[11].Waves[1] = Wave.Create(9, MonsterConfig.GruntBerserker, 46, 22);
_local1.Rounds[12] = Round.Create(Game.Language.RoundDesc13);
_local1.Rounds[12].Waves[0] = Wave.Create(8, MonsterConfig.GruntBerserker, 44, 0);
_local1.Rounds[12].Waves[1] = Wave.Create(8, MonsterConfig.GruntBerserker, 44, 22);
_local1.Rounds[13] = Round.Create(Game.Language.RoundDesc22);
_local1.Rounds[13].Waves[0] = Wave.Create(8, MonsterConfig.GruntBerserker, 44, 0);
_local1.Rounds[13].Waves[1] = Wave.Create(8, MonsterConfig.GruntBerserker, 44, 22);
_local1.Rounds[14] = Round.Create(Game.Language.RoundDesc15);
_local1.Rounds[14].Waves[0] = Wave.Create(8, MonsterConfig.Mercenary, 46, 0);
_local1.Rounds[14].Waves[1] = Wave.Create(8, MonsterConfig.Mercenary, 46, 23);
_local1.Rounds[15] = Round.Create(Game.Language.RoundDesc17);
_local1.Rounds[15].Waves[0] = Wave.Create(6, MonsterConfig.Dwarf, 50, 0);
_local1.Rounds[15].Waves[1] = Wave.Create(6, MonsterConfig.Dwarf, 50, 25);
_local1.Rounds[16] = Round.Create(Game.Language.RoundDesc18);
_local1.Rounds[16].Waves[0] = Wave.Create(6, MonsterConfig.Dwarf, 50, 0);
_local1.Rounds[16].Waves[1] = Wave.Create(6, MonsterConfig.Dwarf, 50, 25);
_local1.Rounds[17] = Round.Create(Game.Language.RoundDesc23);
_local1.Rounds[17].Waves[0] = Wave.Create(7, MonsterConfig.Sapper, 50, 0);
_local1.Rounds[17].Waves[1] = Wave.Create(7, MonsterConfig.Sapper, 50, 25);
_local1.Rounds[18] = Round.Create(Game.Language.RoundDesc24);
_local1.Rounds[18].Waves[0] = Wave.Create(7, MonsterConfig.Sapper, 50, 0);
_local1.Rounds[18].Waves[1] = Wave.Create(7, MonsterConfig.Sapper, 50, 25);
_local1.Rounds[19] = Round.Create(Game.Language.RoundDesc25);
_local1.Rounds[19].Waves[0] = Wave.Create(1, MonsterConfig.Ogre, 0, 0);
return (_local1);
}
}
}//package TowerDefence.Levels
Section 214
//Level4 (TowerDefence.Levels.Level4)
package TowerDefence.Levels {
import TowerDefence.*;
import TowerDefence.Monsters.*;
import Assets.Tiles.*;
public class Level4 {
public static function Generate():LevelData{
var _local1:LevelData;
_local1 = LevelData.Create();
_local1.StartingGold = 50;
_local1.Tiles = new Array(17);
_local1.Tiles[0] = new House2(1, 1);
_local1.Tiles[1] = new House7(1, 1);
_local1.Tiles[2] = new Cliff1(1, 1);
_local1.Tiles[3] = new Cliff8(1, 1);
_local1.Tiles[4] = new Cliff7(1, 1);
_local1.Tiles[5] = new Cliff4(1, 1);
_local1.Tiles[6] = new Land3(1, 1);
_local1.Tiles[7] = new Tree1(1, 1);
_local1.Tiles[8] = new House4(1, 1);
_local1.Tiles[9] = new ArrowDown(1, 1);
_local1.Tiles[10] = new Tree3(1, 1);
_local1.Tiles[11] = new House1(1, 1);
_local1.Tiles[12] = new Land5(1, 1);
_local1.Tiles[13] = new Land4(1, 1);
_local1.Tiles[14] = new Land8(1, 1);
_local1.Tiles[15] = new Land6(1, 1);
_local1.Tiles[16] = new ArrowRight(1, 1);
_local1.Layer1 = new Array(25);
_local1.Layer1[0] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 6, undefined, undefined];
_local1.Layer1[1] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined];
_local1.Layer1[2] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 6, undefined, undefined];
_local1.Layer1[3] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined];
_local1.Layer1[4] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 6, undefined, undefined];
_local1.Layer1[5] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 9, undefined, undefined];
_local1.Layer1[6] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 6, undefined, undefined];
_local1.Layer1[7] = [undefined, undefined, undefined, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, undefined, undefined];
_local1.Layer1[8] = [undefined, undefined, undefined, 6, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[9] = [undefined, undefined, undefined, 6, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[10] = [undefined, undefined, undefined, 6, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[11] = [undefined, undefined, undefined, 6, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[12] = [undefined, undefined, undefined, 6, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[13] = [undefined, undefined, undefined, 6, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[14] = [undefined, undefined, undefined, 6, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[15] = [undefined, undefined, undefined, 6, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[16] = [undefined, undefined, undefined, 15, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 16, 13, 16, 13, 16, 13, 13];
_local1.Layer1[17] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[18] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[19] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[20] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[21] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[22] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[23] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[24] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2 = new Array(25);
_local1.Layer2[0] = [undefined, undefined, undefined, undefined, undefined, undefined, 0, undefined, 1, undefined, undefined, undefined, undefined, 2, undefined, 3, undefined, 4, undefined, 5, undefined, undefined, -1, -1];
_local1.Layer2[1] = [undefined, undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1];
_local1.Layer2[2] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1];
_local1.Layer2[3] = [undefined, undefined, undefined, 8, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1];
_local1.Layer2[4] = [undefined, undefined, undefined, undefined, undefined, undefined, 11, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1];
_local1.Layer2[5] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1];
_local1.Layer2[6] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1];
_local1.Layer2[7] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1];
_local1.Layer2[8] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, -1, -1, -1, -1, -1];
_local1.Layer2[9] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, -1, -1, -1, undefined, -1];
_local1.Layer2[10] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, -1, -1, -1, -1, -1];
_local1.Layer2[11] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, -1, -1, -1, -1, undefined, -1];
_local1.Layer2[12] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, -1, -1, undefined, -1, -1];
_local1.Layer2[13] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, -1, -1, -1, -1, -1, -1];
_local1.Layer2[14] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[15] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[16] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[17] = [undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[18] = [undefined, -1, 10, undefined, -1, undefined, -1, -1, -1, undefined, undefined, -1, 10, undefined, -1, undefined, -1, -1, undefined, -1, 10, undefined, undefined, undefined];
_local1.Layer2[19] = [undefined, undefined, undefined, undefined, -1, undefined, undefined, -1, -1, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, -1, -1, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[20] = [-1, undefined, undefined, -1, -1, undefined, -1, -1, -1, -1, undefined, undefined, -1, undefined, undefined, undefined, -1, undefined, undefined, -1, -1, undefined, undefined, undefined];
_local1.Layer2[21] = [undefined, -1, -1, undefined, -1, -1, -1, undefined, undefined, undefined, -1, -1, undefined, undefined, -1, 10, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined];
_local1.Layer2[22] = [-1, -1, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined];
_local1.Layer2[23] = [-1, -1, undefined, undefined, -1, -1, -1, -1, -1, -1, undefined, -1, undefined, -1, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[24] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Buildable = new Array();
_local1.Buildable[0] = [1, 1, 1, 1, 1, 1, 0, 1, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[1] = [1, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[2] = [1, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[3] = [1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[4] = [1, 1, 1, 0, 0, 1, 0, 0, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0];
_local1.Buildable[5] = [1, 1, 1, 0, 0, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0];
_local1.Buildable[6] = [1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0];
_local1.Buildable[7] = [1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[8] = [1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[9] = [1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[10] = [1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[11] = [1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[12] = [1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[13] = [1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[14] = [1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[15] = [1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[16] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[17] = [0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[18] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[19] = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[20] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[21] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1];
_local1.Buildable[22] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1];
_local1.Buildable[23] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1];
_local1.Buildable[24] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1];
_local1.Paths = new Array(1);
_local1.Paths[0] = new Array(5);
_local1.Paths[0][0] = new SimplePoint(21, -1);
_local1.Paths[0][1] = new SimplePoint(21, 7);
_local1.Paths[0][2] = new SimplePoint(3, 7);
_local1.Paths[0][3] = new SimplePoint(3, 16);
_local1.Paths[0][4] = new SimplePoint(25, 16);
_local1.Rounds = new Array();
_local1.Rounds[0] = Round.Create(Game.Language.RoundDesc1);
_local1.Rounds[0].Waves[0] = Wave.Create(15, MonsterConfig.Eye, 50, 0);
_local1.Rounds[0].Waves[1] = Wave.Create(15, MonsterConfig.Eye, 50, 25);
_local1.Rounds[1] = Round.Create(Game.Language.RoundDesc2);
_local1.Rounds[1].Waves[0] = Wave.Create(15, MonsterConfig.Eye, 50, 0);
_local1.Rounds[1].Waves[1] = Wave.Create(15, MonsterConfig.Eye, 50, 25);
_local1.Rounds[2] = Round.Create(Game.Language.RoundDesc3);
_local1.Rounds[2].Waves[0] = Wave.Create(15, MonsterConfig.Boar, 50, 0);
_local1.Rounds[2].Waves[1] = Wave.Create(15, MonsterConfig.Boar, 50, 25);
_local1.Rounds[3] = Round.Create(Game.Language.RoundDesc4);
_local1.Rounds[3].Waves[0] = Wave.Create(15, MonsterConfig.Boar, 50, 0);
_local1.Rounds[3].Waves[1] = Wave.Create(15, MonsterConfig.Boar, 50, 25);
_local1.Rounds[4] = Round.Create(Game.Language.RoundDesc5);
_local1.Rounds[4].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 48, 0);
_local1.Rounds[4].Waves[1] = Wave.Create(15, MonsterConfig.Peon, 48, 24);
_local1.Rounds[5] = Round.Create(Game.Language.RoundDesc6);
_local1.Rounds[5].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 48, 0);
_local1.Rounds[5].Waves[1] = Wave.Create(15, MonsterConfig.Peon, 48, 24);
_local1.Rounds[6] = Round.Create(Game.Language.RoundDesc7);
_local1.Rounds[6].Waves[0] = Wave.Create(14, MonsterConfig.Troll, 48, 0);
_local1.Rounds[6].Waves[1] = Wave.Create(14, MonsterConfig.Troll, 48, 24);
_local1.Rounds[7] = Round.Create(Game.Language.RoundDesc20);
_local1.Rounds[7].Waves[0] = Wave.Create(12, MonsterConfig.TrollBerserker, 48, 0);
_local1.Rounds[7].Waves[1] = Wave.Create(12, MonsterConfig.TrollBerserker, 48, 24);
_local1.Rounds[8] = Round.Create(Game.Language.RoundDesc9);
_local1.Rounds[8].Waves[0] = Wave.Create(11, MonsterConfig.TrollBerserker, 46, 0);
_local1.Rounds[8].Waves[1] = Wave.Create(11, MonsterConfig.TrollBerserker, 46, 23);
_local1.Rounds[9] = Round.Create(Game.Language.RoundDesc10);
_local1.Rounds[9].Waves[0] = Wave.Create(9, MonsterConfig.Grunt, 46, 0);
_local1.Rounds[9].Waves[1] = Wave.Create(9, MonsterConfig.Grunt, 46, 23);
_local1.Rounds[10] = Round.Create(Game.Language.RoundDesc11);
_local1.Rounds[10].Waves[0] = Wave.Create(8, MonsterConfig.Grunt, 46, 0);
_local1.Rounds[10].Waves[1] = Wave.Create(8, MonsterConfig.Grunt, 46, 23);
_local1.Rounds[11] = Round.Create(Game.Language.RoundDesc21);
_local1.Rounds[11].Waves[0] = Wave.Create(9, MonsterConfig.GruntBerserker, 46, 0);
_local1.Rounds[11].Waves[1] = Wave.Create(9, MonsterConfig.GruntBerserker, 46, 22);
_local1.Rounds[12] = Round.Create(Game.Language.RoundDesc13);
_local1.Rounds[12].Waves[0] = Wave.Create(8, MonsterConfig.GruntBerserker, 44, 0);
_local1.Rounds[12].Waves[1] = Wave.Create(8, MonsterConfig.GruntBerserker, 44, 22);
_local1.Rounds[13] = Round.Create(Game.Language.RoundDesc22);
_local1.Rounds[13].Waves[0] = Wave.Create(8, MonsterConfig.GruntBerserker, 44, 0);
_local1.Rounds[13].Waves[1] = Wave.Create(8, MonsterConfig.GruntBerserker, 44, 22);
_local1.Rounds[14] = Round.Create(Game.Language.RoundDesc15);
_local1.Rounds[14].Waves[0] = Wave.Create(8, MonsterConfig.Mercenary, 46, 0);
_local1.Rounds[14].Waves[1] = Wave.Create(8, MonsterConfig.Mercenary, 46, 23);
_local1.Rounds[15] = Round.Create(Game.Language.RoundDesc17);
_local1.Rounds[15].Waves[0] = Wave.Create(6, MonsterConfig.Dwarf, 50, 0);
_local1.Rounds[15].Waves[1] = Wave.Create(6, MonsterConfig.Dwarf, 50, 25);
_local1.Rounds[16] = Round.Create(Game.Language.RoundDesc18);
_local1.Rounds[16].Waves[0] = Wave.Create(6, MonsterConfig.Dwarf, 50, 0);
_local1.Rounds[16].Waves[1] = Wave.Create(6, MonsterConfig.Dwarf, 50, 25);
_local1.Rounds[17] = Round.Create(Game.Language.RoundDesc23);
_local1.Rounds[17].Waves[0] = Wave.Create(7, MonsterConfig.Sapper, 50, 0);
_local1.Rounds[17].Waves[1] = Wave.Create(7, MonsterConfig.Sapper, 50, 25);
_local1.Rounds[18] = Round.Create(Game.Language.RoundDesc24);
_local1.Rounds[18].Waves[0] = Wave.Create(7, MonsterConfig.Sapper, 50, 0);
_local1.Rounds[18].Waves[1] = Wave.Create(7, MonsterConfig.Sapper, 50, 25);
_local1.Rounds[19] = Round.Create(Game.Language.RoundDesc26);
_local1.Rounds[19].Waves[0] = Wave.Create(5, MonsterConfig.OgreInfected, 50, 0);
_local1.Rounds[19].Waves[1] = Wave.Create(5, MonsterConfig.OgreInfected, 50, 25);
_local1.Rounds[20] = Round.Create(Game.Language.RoundDesc27);
_local1.Rounds[20].Waves[0] = Wave.Create(6, MonsterConfig.OgreInfected, 50, 0);
_local1.Rounds[20].Waves[1] = Wave.Create(6, MonsterConfig.OgreInfected, 50, 25);
_local1.Rounds[21] = Round.Create(Game.Language.RoundDesc28);
_local1.Rounds[21].Waves[0] = Wave.Create(10, MonsterConfig.OgreSpirit, 60, 0);
return (_local1);
}
}
}//package TowerDefence.Levels
Section 215
//Level5 (TowerDefence.Levels.Level5)
package TowerDefence.Levels {
import TowerDefence.*;
import TowerDefence.Monsters.*;
import Assets.Tiles.*;
public class Level5 {
public static function Generate():LevelData{
var _local1:LevelData;
_local1 = LevelData.Create();
_local1.StartingGold = 60;
_local1.Tiles = new Array(29);
_local1.Tiles[0] = new Tree1(1, 1);
_local1.Tiles[1] = new Cliff1(1, 1);
_local1.Tiles[2] = new Cliff6(1, 1);
_local1.Tiles[3] = new Cliff17(1, 1);
_local1.Tiles[4] = new Cliff25(1, 1);
_local1.Tiles[5] = new Land3(1, 1);
_local1.Tiles[6] = new ArrowUp(1, 1);
_local1.Tiles[7] = new Tree2(1, 1);
_local1.Tiles[8] = new Tree3(1, 1);
_local1.Tiles[9] = new Tree4(1, 1);
_local1.Tiles[10] = new Land4(1, 1);
_local1.Tiles[11] = new ArrowLeft(1, 1);
_local1.Tiles[12] = new Land7(1, 1);
_local1.Tiles[13] = new Cliff4(1, 1);
_local1.Tiles[14] = new Cliff13(1, 1);
_local1.Tiles[15] = new Cliff21(1, 1);
_local1.Tiles[16] = new Cliff22(1, 1);
_local1.Tiles[17] = new Cliff23(1, 1);
_local1.Tiles[18] = new Cliff18(1, 1);
_local1.Tiles[19] = new Cliff7(1, 1);
_local1.Tiles[20] = new Land6(1, 1);
_local1.Tiles[21] = new Land10(1, 1);
_local1.Tiles[22] = new Cliff3(1, 1);
_local1.Tiles[23] = new Rock3(1, 1);
_local1.Tiles[24] = new House4(1, 1);
_local1.Tiles[25] = new House3(1, 1);
_local1.Tiles[26] = new House7(1, 1);
_local1.Tiles[27] = new Land8(1, 1);
_local1.Tiles[28] = new Fence1(1, 1);
_local1.Layer1 = new Array(40);
_local1.Layer1[0] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[1] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 6, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[2] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[3] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 6, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[4] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[5] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 6, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[6] = [10, 11, 10, 11, 10, 11, 10, 10, 12, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[7] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[8] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[9] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[10] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[11] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[12] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[13] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[14] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[15] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[16] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[17] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[18] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[19] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 20, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 21, 10, 10, 10, 11, 10, 11, 10, 11, 10];
_local1.Layer1[20] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[21] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[22] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[23] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[24] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[25] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[26] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[27] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[28] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 5, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[29] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 20, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 27, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[30] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[31] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[32] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[33] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[34] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[35] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[36] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[37] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[38] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[39] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2 = new Array(40);
_local1.Layer2[0] = [undefined, -1, 0, -1, 0, -1, 0, -1, undefined, 1, undefined, 2, undefined, 3, 3, 3, 3, 4, undefined, undefined, undefined, undefined, -1, 0, -1, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[1] = [undefined, undefined, -1, 0, -1, 0, -1, undefined, undefined, undefined, undefined, undefined, undefined, 3, 3, 3, 3, 4, undefined, undefined, undefined, undefined, -1, 0, -1, 0, undefined, -1, undefined, undefined, -1, 0, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[2] = [undefined, -1, 0, -1, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, 2, undefined, 3, 3, 4, undefined, undefined, undefined, -1, 7, -1, -1, -1, 0, -1, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[3] = [undefined, -1, 0, -1, 0, -1, 0, -1, 0, -1, undefined, undefined, undefined, undefined, undefined, 3, 3, 4, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, undefined, undefined, -1, undefined, undefined, undefined, -1, 0, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[4] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, 2, undefined, 4, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, -1, -1, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined, -1, undefined, undefined];
_local1.Layer2[5] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 4, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, -1, -1, undefined, -1, 0, -1, -1, undefined, undefined, -1, undefined, undefined];
_local1.Layer2[6] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 13, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, -1, undefined, undefined, -1, 0, undefined, undefined, undefined, -1, 0];
_local1.Layer2[7] = [14, undefined, 15, 15, 15, 16, 17, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined];
_local1.Layer2[8] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, -1, 0, -1, 0, undefined, undefined, undefined, undefined, undefined, -1, undefined];
_local1.Layer2[9] = [undefined, undefined, 18, 3, 3, 3, 4, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[10] = [18, 18, 3, 3, 3, 3, 4, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, -1, undefined, undefined, -1, undefined, undefined, -1, undefined];
_local1.Layer2[11] = [3, 18, 18, 3, 3, 3, 4, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, -1, undefined, undefined];
_local1.Layer2[12] = [3, 3, 3, 18, 3, 18, 4, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined];
_local1.Layer2[13] = [3, 18, 3, 3, 3, 3, 4, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[14] = [3, 18, 18, 3, 3, 18, 4, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[15] = [3, 18, 18, 3, 3, 18, 4, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[16] = [18, 3, 3, 3, 3, 3, 4, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[17] = [18, 18, 3, 3, 18, 3, 4, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[18] = [18, 18, 3, 3, 3, 18, 4, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[19] = [3, 18, 3, 3, 19, undefined, 13, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[20] = [22, 22, 22, 22, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 23, 23, 23, 23, 23, 23, 23, 23, 23];
_local1.Layer2[21] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 23, undefined, undefined, 24, undefined, 25, undefined, 26];
_local1.Layer2[22] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 23, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[23] = [undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 23, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[24] = [undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 23, 24, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[25] = [undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 23, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[26] = [0, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 23, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[27] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 23, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[28] = [undefined, -1, -1, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 23, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[29] = [undefined, -1, undefined, -1, 0, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 23, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[30] = [undefined, undefined, undefined, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 23, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[31] = [undefined, undefined, undefined, -1, undefined, -1, 0, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 23, 28, 28, 28, 28, 28, 28, 28, 28];
_local1.Layer2[32] = [undefined, undefined, -1, -1, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[33] = [undefined, -1, 0, -1, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[34] = [undefined, undefined, undefined, undefined, undefined, -1, 8, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[35] = [undefined, undefined, -1, undefined, undefined, -1, undefined, undefined, -1, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[36] = [undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, -1, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[37] = [undefined, -1, 0, undefined, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[38] = [undefined, undefined, undefined, -1, 0, undefined, undefined, -1, 0, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[39] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Buildable = new Array();
_local1.Buildable[0] = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[1] = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[2] = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[3] = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1];
_local1.Buildable[4] = [1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1];
_local1.Buildable[5] = [1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1];
_local1.Buildable[6] = [0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[7] = [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[8] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[9] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1];
_local1.Buildable[10] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1];
_local1.Buildable[11] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1];
_local1.Buildable[12] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1];
_local1.Buildable[13] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 1];
_local1.Buildable[14] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1];
_local1.Buildable[15] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[16] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[17] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[18] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[19] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[20] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[21] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0];
_local1.Buildable[22] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0];
_local1.Buildable[23] = [0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0];
_local1.Buildable[24] = [1, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1];
_local1.Buildable[25] = [1, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1];
_local1.Buildable[26] = [0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1];
_local1.Buildable[27] = [0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[28] = [0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[29] = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[30] = [1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[31] = [1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[32] = [1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[33] = [1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[34] = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[35] = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[36] = [1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[37] = [1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[38] = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[39] = [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Paths = new Array(2);
_local1.Paths[0] = new Array(6);
_local1.Paths[0][0] = new SimplePoint(39, 19);
_local1.Paths[0][1] = new SimplePoint(30, 19);
_local1.Paths[0][2] = new SimplePoint(30, 29);
_local1.Paths[0][3] = new SimplePoint(8, 29);
_local1.Paths[0][4] = new SimplePoint(8, 6);
_local1.Paths[0][5] = new SimplePoint(0, 6);
_local1.Paths[1] = new Array(3);
_local1.Paths[1][0] = new SimplePoint(39, 19);
_local1.Paths[1][1] = new SimplePoint(19, 19);
_local1.Paths[1][2] = new SimplePoint(19, 0);
_local1.Rounds = new Array();
_local1.Rounds[0] = Round.Create(Game.Language.RoundDesc1);
_local1.Rounds[0].Waves[0] = Wave.Create(15, MonsterConfig.Eye, 50, 0);
_local1.Rounds[0].Waves[1] = Wave.Create(15, MonsterConfig.Eye, 50, 25);
_local1.Rounds[1] = Round.Create(Game.Language.RoundDesc2);
_local1.Rounds[1].Waves[0] = Wave.Create(15, MonsterConfig.Eye, 50, 0);
_local1.Rounds[1].Waves[1] = Wave.Create(15, MonsterConfig.Eye, 50, 25);
_local1.Rounds[2] = Round.Create(Game.Language.RoundDesc3);
_local1.Rounds[2].Waves[0] = Wave.Create(15, MonsterConfig.Boar, 50, 0);
_local1.Rounds[2].Waves[1] = Wave.Create(15, MonsterConfig.Boar, 50, 25);
_local1.Rounds[3] = Round.Create(Game.Language.RoundDesc4);
_local1.Rounds[3].Waves[0] = Wave.Create(15, MonsterConfig.Boar, 50, 0);
_local1.Rounds[3].Waves[1] = Wave.Create(15, MonsterConfig.Boar, 50, 25);
_local1.Rounds[4] = Round.Create(Game.Language.RoundDesc5);
_local1.Rounds[4].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 48, 0);
_local1.Rounds[4].Waves[1] = Wave.Create(15, MonsterConfig.Peon, 48, 24);
_local1.Rounds[5] = Round.Create(Game.Language.RoundDesc6);
_local1.Rounds[5].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 48, 0);
_local1.Rounds[5].Waves[1] = Wave.Create(15, MonsterConfig.Peon, 48, 24);
_local1.Rounds[6] = Round.Create(Game.Language.RoundDesc7);
_local1.Rounds[6].Waves[0] = Wave.Create(14, MonsterConfig.Troll, 48, 0);
_local1.Rounds[6].Waves[1] = Wave.Create(14, MonsterConfig.Troll, 48, 24);
_local1.Rounds[7] = Round.Create(Game.Language.RoundDesc20);
_local1.Rounds[7].Waves[0] = Wave.Create(12, MonsterConfig.TrollBerserker, 48, 0);
_local1.Rounds[7].Waves[1] = Wave.Create(12, MonsterConfig.TrollBerserker, 48, 24);
_local1.Rounds[8] = Round.Create(Game.Language.RoundDesc9);
_local1.Rounds[8].Waves[0] = Wave.Create(11, MonsterConfig.TrollBerserker, 46, 0);
_local1.Rounds[8].Waves[1] = Wave.Create(11, MonsterConfig.TrollBerserker, 46, 23);
_local1.Rounds[9] = Round.Create(Game.Language.RoundDesc10);
_local1.Rounds[9].Waves[0] = Wave.Create(9, MonsterConfig.Grunt, 46, 0);
_local1.Rounds[9].Waves[1] = Wave.Create(9, MonsterConfig.Grunt, 46, 23);
_local1.Rounds[10] = Round.Create(Game.Language.RoundDesc11);
_local1.Rounds[10].Waves[0] = Wave.Create(8, MonsterConfig.Grunt, 46, 0);
_local1.Rounds[10].Waves[1] = Wave.Create(8, MonsterConfig.Grunt, 46, 23);
_local1.Rounds[11] = Round.Create(Game.Language.RoundDesc21);
_local1.Rounds[11].Waves[0] = Wave.Create(9, MonsterConfig.GruntBerserker, 46, 0);
_local1.Rounds[11].Waves[1] = Wave.Create(9, MonsterConfig.GruntBerserker, 46, 22);
_local1.Rounds[12] = Round.Create(Game.Language.RoundDesc13);
_local1.Rounds[12].Waves[0] = Wave.Create(8, MonsterConfig.GruntBerserker, 44, 0);
_local1.Rounds[12].Waves[1] = Wave.Create(8, MonsterConfig.GruntBerserker, 44, 22);
_local1.Rounds[13] = Round.Create(Game.Language.RoundDesc22);
_local1.Rounds[13].Waves[0] = Wave.Create(8, MonsterConfig.GruntBerserker, 44, 0);
_local1.Rounds[13].Waves[1] = Wave.Create(8, MonsterConfig.GruntBerserker, 44, 22);
_local1.Rounds[14] = Round.Create(Game.Language.RoundDesc15);
_local1.Rounds[14].Waves[0] = Wave.Create(8, MonsterConfig.Mercenary, 46, 0);
_local1.Rounds[14].Waves[1] = Wave.Create(8, MonsterConfig.Mercenary, 46, 23);
_local1.Rounds[15] = Round.Create(Game.Language.RoundDesc16);
_local1.Rounds[15].Waves[0] = Wave.Create(1, MonsterConfig.MercenaryVeteran, 0, 0);
_local1.Rounds[16] = Round.Create(Game.Language.RoundDesc17);
_local1.Rounds[16].Waves[0] = Wave.Create(6, MonsterConfig.Dwarf, 50, 0);
_local1.Rounds[16].Waves[1] = Wave.Create(6, MonsterConfig.Dwarf, 50, 25);
_local1.Rounds[17] = Round.Create(Game.Language.RoundDesc18);
_local1.Rounds[17].Waves[0] = Wave.Create(6, MonsterConfig.Dwarf, 50, 0);
_local1.Rounds[17].Waves[1] = Wave.Create(6, MonsterConfig.Dwarf, 50, 25);
_local1.Rounds[18] = Round.Create(Game.Language.RoundDesc19);
_local1.Rounds[18].Waves[0] = Wave.Create(1, MonsterConfig.DwarfStone, 0, 0);
_local1.Rounds[19] = Round.Create(Game.Language.RoundDesc23);
_local1.Rounds[19].Waves[0] = Wave.Create(7, MonsterConfig.Sapper, 50, 0);
_local1.Rounds[19].Waves[1] = Wave.Create(7, MonsterConfig.Sapper, 50, 25);
_local1.Rounds[20] = Round.Create(Game.Language.RoundDesc24);
_local1.Rounds[20].Waves[0] = Wave.Create(7, MonsterConfig.Sapper, 50, 0);
_local1.Rounds[20].Waves[1] = Wave.Create(7, MonsterConfig.Sapper, 50, 25);
_local1.Rounds[21] = Round.Create(Game.Language.RoundDesc26);
_local1.Rounds[21].Waves[0] = Wave.Create(5, MonsterConfig.OgreInfected, 50, 0);
_local1.Rounds[21].Waves[1] = Wave.Create(5, MonsterConfig.OgreInfected, 50, 25);
_local1.Rounds[22] = Round.Create(Game.Language.RoundDesc27);
_local1.Rounds[22].Waves[0] = Wave.Create(6, MonsterConfig.OgreInfected, 50, 0);
_local1.Rounds[22].Waves[1] = Wave.Create(6, MonsterConfig.OgreInfected, 50, 25);
_local1.Rounds[23] = Round.Create(Game.Language.RoundDesc28);
_local1.Rounds[23].Waves[0] = Wave.Create(10, MonsterConfig.OgreSpirit, 60, 0);
_local1.Rounds[24] = Round.Create(Game.Language.RoundDesc25);
_local1.Rounds[24].Waves[0] = Wave.Create(1, MonsterConfig.Ogre, 0, 0);
_local1.Rounds[25] = Round.Create(Game.Language.RoundDesc29);
_local1.Rounds[25].Waves[0] = Wave.Create(4, MonsterConfig.Knight, 50, 0);
_local1.Rounds[25].Waves[1] = Wave.Create(4, MonsterConfig.Knight, 50, 25);
return (_local1);
}
}
}//package TowerDefence.Levels
Section 216
//Level6 (TowerDefence.Levels.Level6)
package TowerDefence.Levels {
import TowerDefence.*;
import TowerDefence.Monsters.*;
import Assets.Tiles.*;
public class Level6 {
public static function Generate():LevelData{
var _local1:LevelData;
_local1 = LevelData.Create();
_local1.StartingGold = 50;
_local1.Tiles = new Array(16);
_local1.Tiles[0] = new Cliff8(1, 1);
_local1.Tiles[1] = new Cliff17(1, 1);
_local1.Tiles[2] = new Cliff25(1, 1);
_local1.Tiles[3] = new Tree1(1, 1);
_local1.Tiles[4] = new Land3(1, 1);
_local1.Tiles[5] = new Cliff6(1, 1);
_local1.Tiles[6] = new Cliff11(1, 1);
_local1.Tiles[7] = new Cliff23(1, 1);
_local1.Tiles[8] = new Cliff3(1, 1);
_local1.Tiles[9] = new Cliff4(1, 1);
_local1.Tiles[10] = new Land4(1, 1);
_local1.Tiles[11] = new Land7(1, 1);
_local1.Tiles[12] = new Land6(1, 1);
_local1.Tiles[13] = new Land8(1, 1);
_local1.Tiles[14] = new ArrowUp(1, 1);
_local1.Tiles[15] = new ArrowRight(1, 1);
_local1.Layer1 = new Array(16);
_local1.Layer1[0] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 4, undefined];
_local1.Layer1[1] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 14, undefined];
_local1.Layer1[2] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 4, undefined];
_local1.Layer1[3] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 14, undefined];
_local1.Layer1[4] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 4, undefined];
_local1.Layer1[5] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 14, undefined];
_local1.Layer1[6] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 4, undefined];
_local1.Layer1[7] = [10, 15, 10, 15, 10, 15, 10, 11, undefined, undefined, undefined, undefined, undefined, 4, undefined];
_local1.Layer1[8] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 4, undefined, undefined, undefined, undefined, undefined, 4, undefined];
_local1.Layer1[9] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 4, undefined, undefined, undefined, undefined, undefined, 4, undefined];
_local1.Layer1[10] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 4, undefined, undefined, undefined, undefined, undefined, 4, undefined];
_local1.Layer1[11] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 4, undefined, undefined, undefined, undefined, undefined, 4, undefined];
_local1.Layer1[12] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 4, undefined, undefined, undefined, undefined, undefined, 4, undefined];
_local1.Layer1[13] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 12, 10, 10, 10, 10, 10, 13, undefined];
_local1.Layer1[14] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[15] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2 = new Array(16);
_local1.Layer2[0] = [0, undefined, 1, 1, 1, 1, 1, 2, undefined, undefined, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[1] = [undefined, undefined, 5, undefined, 1, 1, 1, 6, undefined, 7, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[2] = [undefined, undefined, undefined, undefined, 1, 1, 1, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[3] = [undefined, undefined, undefined, undefined, 8, 8, 8, 8, 8, 9, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[4] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[5] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[6] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[7] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[8] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[9] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[10] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[11] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[12] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[13] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[14] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[15] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Buildable = new Array();
_local1.Buildable[0] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 1];
_local1.Buildable[1] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[2] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[3] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[4] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[5] = [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[6] = [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[7] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[8] = [1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[9] = [1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[10] = [1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[11] = [1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[12] = [1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[13] = [1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1];
_local1.Buildable[14] = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[15] = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Paths = new Array(1);
_local1.Paths[0] = new Array(5);
_local1.Paths[0][0] = new SimplePoint(-1, 7);
_local1.Paths[0][1] = new SimplePoint(7, 7);
_local1.Paths[0][2] = new SimplePoint(7, 13);
_local1.Paths[0][3] = new SimplePoint(13, 13);
_local1.Paths[0][4] = new SimplePoint(13, -1);
_local1.Rounds = new Array();
_local1.Rounds[0] = Round.Create(Game.Language.RoundDesc1);
_local1.Rounds[0].Waves[0] = Wave.Create(15, MonsterConfig.Eye, 45, 0);
_local1.Rounds[0].Waves[1] = Wave.Create(15, MonsterConfig.Eye, 45, 25);
_local1.Rounds[1] = Round.Create(Game.Language.RoundDesc2);
_local1.Rounds[1].Waves[0] = Wave.Create(15, MonsterConfig.Eye, 45, 0);
_local1.Rounds[1].Waves[1] = Wave.Create(15, MonsterConfig.Eye, 45, 25);
_local1.Rounds[2] = Round.Create(Game.Language.RoundDesc3);
_local1.Rounds[2].Waves[0] = Wave.Create(15, MonsterConfig.Boar, 45, 0);
_local1.Rounds[2].Waves[1] = Wave.Create(15, MonsterConfig.Boar, 45, 25);
_local1.Rounds[3] = Round.Create(Game.Language.RoundDesc4);
_local1.Rounds[3].Waves[0] = Wave.Create(15, MonsterConfig.Boar, 44, 0);
_local1.Rounds[3].Waves[1] = Wave.Create(15, MonsterConfig.Boar, 44, 25);
_local1.Rounds[4] = Round.Create(Game.Language.RoundDesc5);
_local1.Rounds[4].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 44, 0);
_local1.Rounds[4].Waves[1] = Wave.Create(15, MonsterConfig.Peon, 44, 24);
_local1.Rounds[5] = Round.Create(Game.Language.RoundDesc6);
_local1.Rounds[5].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 43, 0);
_local1.Rounds[5].Waves[1] = Wave.Create(15, MonsterConfig.Peon, 43, 24);
_local1.Rounds[6] = Round.Create(Game.Language.RoundDesc7);
_local1.Rounds[6].Waves[0] = Wave.Create(14, MonsterConfig.Troll, 43, 0);
_local1.Rounds[6].Waves[1] = Wave.Create(14, MonsterConfig.Troll, 43, 24);
_local1.Rounds[7] = Round.Create(Game.Language.RoundDesc20);
_local1.Rounds[7].Waves[0] = Wave.Create(12, MonsterConfig.TrollBerserker, 43, 0);
_local1.Rounds[7].Waves[1] = Wave.Create(12, MonsterConfig.TrollBerserker, 43, 24);
_local1.Rounds[8] = Round.Create(Game.Language.RoundDesc9);
_local1.Rounds[8].Waves[0] = Wave.Create(11, MonsterConfig.TrollBerserker, 42, 0);
_local1.Rounds[8].Waves[1] = Wave.Create(11, MonsterConfig.TrollBerserker, 42, 23);
_local1.Rounds[9] = Round.Create(Game.Language.RoundDesc10);
_local1.Rounds[9].Waves[0] = Wave.Create(9, MonsterConfig.Grunt, 42, 0);
_local1.Rounds[9].Waves[1] = Wave.Create(9, MonsterConfig.Grunt, 42, 23);
_local1.Rounds[10] = Round.Create(Game.Language.RoundDesc11);
_local1.Rounds[10].Waves[0] = Wave.Create(8, MonsterConfig.Grunt, 42, 0);
_local1.Rounds[10].Waves[1] = Wave.Create(8, MonsterConfig.Grunt, 42, 23);
_local1.Rounds[11] = Round.Create(Game.Language.RoundDesc21);
_local1.Rounds[11].Waves[0] = Wave.Create(9, MonsterConfig.GruntBerserker, 42, 0);
_local1.Rounds[11].Waves[1] = Wave.Create(9, MonsterConfig.GruntBerserker, 42, 22);
_local1.Rounds[12] = Round.Create(Game.Language.RoundDesc13);
_local1.Rounds[12].Waves[0] = Wave.Create(8, MonsterConfig.GruntBerserker, 41, 0);
_local1.Rounds[12].Waves[1] = Wave.Create(8, MonsterConfig.GruntBerserker, 41, 22);
_local1.Rounds[13] = Round.Create(Game.Language.RoundDesc22);
_local1.Rounds[13].Waves[0] = Wave.Create(8, MonsterConfig.GruntBerserker, 41, 0);
_local1.Rounds[13].Waves[1] = Wave.Create(8, MonsterConfig.GruntBerserker, 41, 20);
_local1.Rounds[14] = Round.Create(Game.Language.RoundDesc15);
_local1.Rounds[14].Waves[0] = Wave.Create(8, MonsterConfig.Mercenary, 41, 0);
_local1.Rounds[14].Waves[1] = Wave.Create(8, MonsterConfig.Mercenary, 41, 23);
_local1.Rounds[15] = Round.Create(Game.Language.RoundDesc16);
_local1.Rounds[15].Waves[0] = Wave.Create(1, MonsterConfig.MercenaryVeteran, 0, 0);
_local1.Rounds[16] = Round.Create(Game.Language.RoundDesc17);
_local1.Rounds[16].Waves[0] = Wave.Create(6, MonsterConfig.Dwarf, 41, 0);
_local1.Rounds[16].Waves[1] = Wave.Create(6, MonsterConfig.Dwarf, 41, 25);
_local1.Rounds[17] = Round.Create(Game.Language.RoundDesc18);
_local1.Rounds[17].Waves[0] = Wave.Create(6, MonsterConfig.Dwarf, 40, 0);
_local1.Rounds[17].Waves[1] = Wave.Create(6, MonsterConfig.Dwarf, 40, 20);
_local1.Rounds[18] = Round.Create(Game.Language.RoundDesc19);
_local1.Rounds[18].Waves[0] = Wave.Create(1, MonsterConfig.DwarfStone, 0, 0);
_local1.Rounds[19] = Round.Create(Game.Language.RoundDesc23);
_local1.Rounds[19].Waves[0] = Wave.Create(7, MonsterConfig.Sapper, 40, 0);
_local1.Rounds[19].Waves[1] = Wave.Create(7, MonsterConfig.Sapper, 40, 25);
_local1.Rounds[20] = Round.Create(Game.Language.RoundDesc24);
_local1.Rounds[20].Waves[0] = Wave.Create(7, MonsterConfig.Sapper, 40, 0);
_local1.Rounds[20].Waves[1] = Wave.Create(7, MonsterConfig.Sapper, 40, 25);
_local1.Rounds[21] = Round.Create(Game.Language.RoundDesc26);
_local1.Rounds[21].Waves[0] = Wave.Create(5, MonsterConfig.OgreInfected, 40, 0);
_local1.Rounds[21].Waves[1] = Wave.Create(5, MonsterConfig.OgreInfected, 40, 25);
_local1.Rounds[22] = Round.Create(Game.Language.RoundDesc27);
_local1.Rounds[22].Waves[0] = Wave.Create(6, MonsterConfig.OgreInfected, 39, 0);
_local1.Rounds[22].Waves[1] = Wave.Create(6, MonsterConfig.OgreInfected, 39, 20);
_local1.Rounds[23] = Round.Create(Game.Language.RoundDesc28);
_local1.Rounds[23].Waves[0] = Wave.Create(10, MonsterConfig.OgreSpirit, 39, 0);
_local1.Rounds[24] = Round.Create(Game.Language.RoundDesc25);
_local1.Rounds[24].Waves[0] = Wave.Create(1, MonsterConfig.Ogre, 0, 0);
_local1.Rounds[25] = Round.Create(Game.Language.RoundDesc29);
_local1.Rounds[25].Waves[0] = Wave.Create(4, MonsterConfig.Knight, 38, 0);
_local1.Rounds[25].Waves[1] = Wave.Create(4, MonsterConfig.Knight, 38, 19);
_local1.Rounds[26] = Round.Create(Game.Language.RoundDesc30);
_local1.Rounds[26].Waves[0] = Wave.Create(5, MonsterConfig.Knight, 38, 0);
_local1.Rounds[26].Waves[1] = Wave.Create(5, MonsterConfig.Knight, 38, 19);
_local1.Rounds[27] = Round.Create(Game.Language.RoundDesc31);
_local1.Rounds[27].Waves[0] = Wave.Create(1, MonsterConfig.Knight2, 0, 0);
return (_local1);
}
}
}//package TowerDefence.Levels
Section 217
//Level7 (TowerDefence.Levels.Level7)
package TowerDefence.Levels {
import TowerDefence.*;
import TowerDefence.Monsters.*;
import Assets.Tiles.*;
public class Level7 {
public static function Generate():LevelData{
var _local1:LevelData;
_local1 = LevelData.Create();
_local1.StartingGold = 70;
_local1.Tiles = new Array(20);
_local1.Tiles[0] = new Cliff17(1, 1);
_local1.Tiles[1] = new Cliff25(1, 1);
_local1.Tiles[2] = new Tree1(1, 1);
_local1.Tiles[3] = new Cliff5(1, 1);
_local1.Tiles[4] = new Cliff10(1, 1);
_local1.Tiles[5] = new Tree3(1, 1);
_local1.Tiles[6] = new Cliff1(1, 1);
_local1.Tiles[7] = new Cliff3(1, 1);
_local1.Tiles[8] = new Cliff4(1, 1);
_local1.Tiles[9] = new Land4(1, 1);
_local1.Tiles[10] = new ArrowLeft(1, 1);
_local1.Tiles[11] = new Land7(1, 1);
_local1.Tiles[12] = new Land3(1, 1);
_local1.Tiles[13] = new Land5(1, 1);
_local1.Tiles[14] = new Land8(1, 1);
_local1.Tiles[15] = new Fence1(1, 1);
_local1.Tiles[16] = new Rock3(1, 1);
_local1.Tiles[17] = new House4(1, 1);
_local1.Tiles[18] = new House5(1, 1);
_local1.Tiles[19] = new Land6(1, 1);
_local1.Layer1 = new Array(30);
_local1.Layer1[0] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[1] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[2] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[3] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[4] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[5] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[6] = [9, 10, 9, 10, 9, 10, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 11, undefined, undefined];
_local1.Layer1[7] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 12, undefined, undefined];
_local1.Layer1[8] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 12, undefined, undefined];
_local1.Layer1[9] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 12, undefined, undefined];
_local1.Layer1[10] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 12, undefined, undefined];
_local1.Layer1[11] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 12, undefined, undefined];
_local1.Layer1[12] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 12, undefined, undefined];
_local1.Layer1[13] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 12, undefined, undefined];
_local1.Layer1[14] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 12, undefined, undefined];
_local1.Layer1[15] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, 12, undefined, undefined];
_local1.Layer1[16] = [undefined, undefined, undefined, 13, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 14, undefined, undefined];
_local1.Layer1[17] = [undefined, undefined, undefined, 12, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[18] = [undefined, undefined, undefined, 12, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[19] = [undefined, undefined, undefined, 12, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[20] = [undefined, undefined, undefined, 12, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[21] = [undefined, undefined, undefined, 12, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[22] = [undefined, undefined, undefined, 12, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[23] = [undefined, undefined, undefined, 12, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[24] = [undefined, undefined, undefined, 12, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[25] = [undefined, undefined, undefined, 12, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[26] = [undefined, undefined, undefined, 19, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 9, 10, 9, 10, 9];
_local1.Layer1[27] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[28] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[29] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2 = new Array(30);
_local1.Layer2[0] = [0, 0, 0, 0, 0, 0, 0, 1, undefined, -1, undefined, -1, -1, -1, -1, -1, -1, -1, undefined, undefined, -1, -1, -1, -1, -1, undefined, undefined, undefined, undefined];
_local1.Layer2[1] = [3, undefined, 4, undefined, 0, 0, 0, 1, undefined, undefined, -1, -1, undefined, -1, undefined, -1, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, -1, -1, -1, -1, -1];
_local1.Layer2[2] = [undefined, undefined, undefined, undefined, 0, 0, 0, 1, undefined, -1, undefined, undefined, -1, -1, -1, -1, -1, undefined, undefined, undefined, -1, -1, undefined, undefined, -1, -1, undefined, undefined, undefined];
_local1.Layer2[3] = [undefined, undefined, 6, undefined, 7, 7, 7, 8, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, -1, -1, -1, undefined, undefined, undefined];
_local1.Layer2[4] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1];
_local1.Layer2[5] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1];
_local1.Layer2[6] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1];
_local1.Layer2[7] = [-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, undefined, undefined, undefined, undefined, -1];
_local1.Layer2[8] = [undefined, -1, -1, -1, -1, -1, -1, undefined, -1, undefined, -1, -1, -1, -1, -1, -1, undefined, undefined, -1, undefined, -1, -1, -1, -1, undefined, undefined, undefined, undefined, -1];
_local1.Layer2[9] = [-1, -1, undefined, -1, -1, -1, undefined, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, -1];
_local1.Layer2[10] = [-1, -1, -1, -1, -1, undefined, undefined, -1, -1, -1, -1, -1, -1, -1, undefined, undefined, -1, -1, -1, -1, undefined, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[11] = [-1, -1, -1, -1, undefined, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, undefined, -1, -1, -1, -1, undefined, -1, -1, undefined, undefined, undefined, -1, undefined];
_local1.Layer2[12] = [-1, -1, undefined, undefined, undefined, -1, -1, -1, undefined, undefined, undefined, undefined, -1, undefined, undefined, -1, -1, -1, -1, -1, -1, undefined, undefined, -1, undefined, undefined, undefined, -1, -1];
_local1.Layer2[13] = [-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, undefined, undefined, undefined, undefined, -1, -1];
_local1.Layer2[14] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined];
_local1.Layer2[15] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[16] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[17] = [-1, undefined, undefined, undefined, 15, 15, 15, 15, 15, 15, 15, 15, 15, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[18] = [-1, undefined, undefined, undefined, 16, 17, undefined, undefined, undefined, 18, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[19] = [-1, undefined, undefined, undefined, 16, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[20] = [-1, undefined, undefined, undefined, 16, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[21] = [-1, undefined, undefined, undefined, 16, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[22] = [-1, undefined, undefined, undefined, 17, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[23] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[24] = [-1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[25] = [-1, undefined, undefined, undefined, 15, 15, 15, 15, 15, 15, 15, 15, 15, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[26] = [undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[27] = [-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1];
_local1.Layer2[28] = [undefined, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[29] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Buildable = new Array();
_local1.Buildable[0] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1];
_local1.Buildable[1] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[2] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[3] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[4] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[5] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[6] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[7] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0];
_local1.Buildable[8] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0];
_local1.Buildable[9] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0];
_local1.Buildable[10] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0];
_local1.Buildable[11] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[12] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[13] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[14] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0];
_local1.Buildable[15] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0];
_local1.Buildable[16] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1];
_local1.Buildable[17] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[18] = [0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[19] = [0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[20] = [0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[21] = [0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[22] = [0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[23] = [0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[24] = [0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[25] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[26] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[27] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[28] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[29] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Paths = new Array(1);
_local1.Paths[0] = new Array(6);
_local1.Paths[0][0] = new SimplePoint(30, 26);
_local1.Paths[0][1] = new SimplePoint(3, 26);
_local1.Paths[0][2] = new SimplePoint(3, 16);
_local1.Paths[0][3] = new SimplePoint(26, 16);
_local1.Paths[0][4] = new SimplePoint(26, 6);
_local1.Paths[0][5] = new SimplePoint(-1, 6);
_local1.Rounds = new Array();
_local1.Rounds[0] = Round.Create(Game.Language.RoundDesc1);
_local1.Rounds[0].Waves[0] = Wave.Create(15, MonsterConfig.Eye, 45, 0);
_local1.Rounds[0].Waves[1] = Wave.Create(15, MonsterConfig.Eye, 45, 25);
_local1.Rounds[1] = Round.Create(Game.Language.RoundDesc2);
_local1.Rounds[1].Waves[0] = Wave.Create(15, MonsterConfig.Eye, 45, 0);
_local1.Rounds[1].Waves[1] = Wave.Create(15, MonsterConfig.Eye, 45, 25);
_local1.Rounds[2] = Round.Create(Game.Language.RoundDesc3);
_local1.Rounds[2].Waves[0] = Wave.Create(15, MonsterConfig.Boar, 45, 0);
_local1.Rounds[2].Waves[1] = Wave.Create(15, MonsterConfig.Boar, 45, 25);
_local1.Rounds[3] = Round.Create(Game.Language.RoundDesc4);
_local1.Rounds[3].Waves[0] = Wave.Create(15, MonsterConfig.Boar, 44, 0);
_local1.Rounds[3].Waves[1] = Wave.Create(15, MonsterConfig.Boar, 44, 25);
_local1.Rounds[4] = Round.Create(Game.Language.RoundDesc5);
_local1.Rounds[4].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 44, 0);
_local1.Rounds[4].Waves[1] = Wave.Create(15, MonsterConfig.Peon, 44, 24);
_local1.Rounds[5] = Round.Create(Game.Language.RoundDesc6);
_local1.Rounds[5].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 43, 0);
_local1.Rounds[5].Waves[1] = Wave.Create(15, MonsterConfig.Peon, 43, 24);
_local1.Rounds[6] = Round.Create(Game.Language.RoundDesc7);
_local1.Rounds[6].Waves[0] = Wave.Create(14, MonsterConfig.Troll, 43, 0);
_local1.Rounds[6].Waves[1] = Wave.Create(14, MonsterConfig.Troll, 43, 24);
_local1.Rounds[7] = Round.Create(Game.Language.RoundDesc20);
_local1.Rounds[7].Waves[0] = Wave.Create(12, MonsterConfig.TrollBerserker, 43, 0);
_local1.Rounds[7].Waves[1] = Wave.Create(12, MonsterConfig.TrollBerserker, 43, 24);
_local1.Rounds[8] = Round.Create(Game.Language.RoundDesc9);
_local1.Rounds[8].Waves[0] = Wave.Create(11, MonsterConfig.TrollBerserker, 42, 0);
_local1.Rounds[8].Waves[1] = Wave.Create(11, MonsterConfig.TrollBerserker, 42, 23);
_local1.Rounds[9] = Round.Create(Game.Language.RoundDesc10);
_local1.Rounds[9].Waves[0] = Wave.Create(9, MonsterConfig.Grunt, 42, 0);
_local1.Rounds[9].Waves[1] = Wave.Create(9, MonsterConfig.Grunt, 42, 23);
_local1.Rounds[10] = Round.Create(Game.Language.RoundDesc11);
_local1.Rounds[10].Waves[0] = Wave.Create(8, MonsterConfig.Grunt, 42, 0);
_local1.Rounds[10].Waves[1] = Wave.Create(8, MonsterConfig.Grunt, 42, 23);
_local1.Rounds[11] = Round.Create(Game.Language.RoundDesc21);
_local1.Rounds[11].Waves[0] = Wave.Create(9, MonsterConfig.GruntBerserker, 42, 0);
_local1.Rounds[11].Waves[1] = Wave.Create(9, MonsterConfig.GruntBerserker, 42, 22);
_local1.Rounds[12] = Round.Create(Game.Language.RoundDesc13);
_local1.Rounds[12].Waves[0] = Wave.Create(8, MonsterConfig.GruntBerserker, 41, 0);
_local1.Rounds[12].Waves[1] = Wave.Create(8, MonsterConfig.GruntBerserker, 41, 22);
_local1.Rounds[13] = Round.Create(Game.Language.RoundDesc22);
_local1.Rounds[13].Waves[0] = Wave.Create(8, MonsterConfig.GruntBerserker, 41, 0);
_local1.Rounds[13].Waves[1] = Wave.Create(8, MonsterConfig.GruntBerserker, 41, 20);
_local1.Rounds[14] = Round.Create(Game.Language.RoundDesc15);
_local1.Rounds[14].Waves[0] = Wave.Create(8, MonsterConfig.Mercenary, 41, 0);
_local1.Rounds[14].Waves[1] = Wave.Create(8, MonsterConfig.Mercenary, 41, 23);
_local1.Rounds[15] = Round.Create(Game.Language.RoundDesc16);
_local1.Rounds[15].Waves[0] = Wave.Create(1, MonsterConfig.MercenaryVeteran, 0, 0);
_local1.Rounds[16] = Round.Create(Game.Language.RoundDesc17);
_local1.Rounds[16].Waves[0] = Wave.Create(6, MonsterConfig.Dwarf, 41, 0);
_local1.Rounds[16].Waves[1] = Wave.Create(6, MonsterConfig.Dwarf, 41, 25);
_local1.Rounds[17] = Round.Create(Game.Language.RoundDesc18);
_local1.Rounds[17].Waves[0] = Wave.Create(6, MonsterConfig.Dwarf, 40, 0);
_local1.Rounds[17].Waves[1] = Wave.Create(6, MonsterConfig.Dwarf, 40, 20);
_local1.Rounds[18] = Round.Create(Game.Language.RoundDesc19);
_local1.Rounds[18].Waves[0] = Wave.Create(1, MonsterConfig.DwarfStone, 0, 0);
_local1.Rounds[19] = Round.Create(Game.Language.RoundDesc23);
_local1.Rounds[19].Waves[0] = Wave.Create(7, MonsterConfig.Sapper, 40, 0);
_local1.Rounds[19].Waves[1] = Wave.Create(7, MonsterConfig.Sapper, 40, 25);
_local1.Rounds[20] = Round.Create(Game.Language.RoundDesc24);
_local1.Rounds[20].Waves[0] = Wave.Create(7, MonsterConfig.Sapper, 40, 0);
_local1.Rounds[20].Waves[1] = Wave.Create(7, MonsterConfig.Sapper, 40, 25);
_local1.Rounds[21] = Round.Create(Game.Language.RoundDesc26);
_local1.Rounds[21].Waves[0] = Wave.Create(5, MonsterConfig.OgreInfected, 40, 0);
_local1.Rounds[21].Waves[1] = Wave.Create(5, MonsterConfig.OgreInfected, 40, 25);
_local1.Rounds[22] = Round.Create(Game.Language.RoundDesc27);
_local1.Rounds[22].Waves[0] = Wave.Create(6, MonsterConfig.OgreInfected, 39, 0);
_local1.Rounds[22].Waves[1] = Wave.Create(6, MonsterConfig.OgreInfected, 39, 20);
_local1.Rounds[23] = Round.Create(Game.Language.RoundDesc32);
_local1.Rounds[23].Waves[0] = Wave.Create(10, MonsterConfig.OgreSpirit, 39, 0);
_local1.Rounds[24] = Round.Create(Game.Language.RoundDesc25);
_local1.Rounds[24].Waves[0] = Wave.Create(1, MonsterConfig.Ogre, 0, 0);
_local1.Rounds[25] = Round.Create(Game.Language.RoundDesc29);
_local1.Rounds[25].Waves[0] = Wave.Create(4, MonsterConfig.Knight, 38, 0);
_local1.Rounds[25].Waves[1] = Wave.Create(4, MonsterConfig.Knight, 38, 19);
_local1.Rounds[26] = Round.Create(Game.Language.RoundDesc30);
_local1.Rounds[26].Waves[0] = Wave.Create(5, MonsterConfig.Knight, 38, 0);
_local1.Rounds[26].Waves[1] = Wave.Create(5, MonsterConfig.Knight, 38, 19);
_local1.Rounds[27] = Round.Create(Game.Language.RoundDesc33);
_local1.Rounds[27].Waves[0] = Wave.Create(5, MonsterConfig.DeathKnight, 38, 0);
_local1.Rounds[27].Waves[1] = Wave.Create(5, MonsterConfig.DeathKnight, 38, 19);
_local1.Rounds[28] = Round.Create(Game.Language.RoundDesc31);
_local1.Rounds[28].Waves[0] = Wave.Create(1, MonsterConfig.Knight2, 0, 0);
return (_local1);
}
}
}//package TowerDefence.Levels
Section 218
//Level8 (TowerDefence.Levels.Level8)
package TowerDefence.Levels {
import TowerDefence.*;
import TowerDefence.Monsters.*;
import Assets.Tiles.*;
public class Level8 {
public static function Generate():LevelData{
var _local1:LevelData;
_local1 = LevelData.Create();
_local1.StartingGold = 200;
_local1.Tiles = new Array(8);
_local1.Tiles[0] = new Tree1(1, 1);
_local1.Tiles[1] = new Land3(1, 1);
_local1.Tiles[2] = new ArrowDown(1, 1);
_local1.Tiles[3] = new Land4(1, 1);
_local1.Tiles[4] = new ArrowRight(1, 1);
_local1.Tiles[5] = new Land2(1, 1);
_local1.Tiles[6] = new ArrowLeft(1, 1);
_local1.Tiles[7] = new ArrowUp(1, 1);
_local1.Layer1 = new Array(17);
_local1.Layer1[0] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[1] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 2, 2, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[2] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[3] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 2, 2, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[4] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[5] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 2, 2, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[6] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[7] = [3, 4, 3, 4, 3, 4, 3, 5, 5, 3, 3, 6, 3, 6, 3, 6, 3];
_local1.Layer1[8] = [3, 4, 3, 4, 3, 4, 3, 5, 5, 3, 3, 6, 3, 6, 3, 6, 3];
_local1.Layer1[9] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[10] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[11] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 7, 7, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[12] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[13] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 7, 7, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[14] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[15] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 7, 7, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer1[16] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, 1, 1, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2 = new Array(17);
_local1.Layer2[0] = [-1, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, -1, -1];
_local1.Layer2[1] = [-1, undefined, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, -1];
_local1.Layer2[2] = [-1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, -1];
_local1.Layer2[3] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1];
_local1.Layer2[4] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[5] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[6] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[7] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[8] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[9] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Layer2[10] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, -1, undefined];
_local1.Layer2[11] = [-1, -1, undefined, -1, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, undefined, -1, undefined];
_local1.Layer2[12] = [-1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, -1, undefined];
_local1.Layer2[13] = [-1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, undefined, -1, -1, -1, -1, -1];
_local1.Layer2[14] = [-1, -1, -1, -1, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, -1, undefined, undefined, undefined];
_local1.Layer2[15] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, -1, -1, undefined, undefined, undefined];
_local1.Layer2[16] = [undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined];
_local1.Buildable = new Array();
_local1.Buildable[0] = [0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0];
_local1.Buildable[1] = [0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0];
_local1.Buildable[2] = [0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0];
_local1.Buildable[3] = [0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0];
_local1.Buildable[4] = [0, 0, 0, 1, 1, 1, 1, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0];
_local1.Buildable[5] = [1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0];
_local1.Buildable[6] = [1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[7] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[8] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[9] = [1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1];
_local1.Buildable[10] = [1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1];
_local1.Buildable[11] = [0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1];
_local1.Buildable[12] = [0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1];
_local1.Buildable[13] = [0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[14] = [0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[15] = [0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0];
_local1.Buildable[16] = [0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 1];
_local1.Paths = new Array(8);
_local1.Paths[0] = new Array(2);
_local1.Paths[0][0] = new SimplePoint(-1, 7);
_local1.Paths[0][1] = new SimplePoint(17, 7);
_local1.Paths[1] = new Array(2);
_local1.Paths[1][0] = new SimplePoint(-1, 8);
_local1.Paths[1][1] = new SimplePoint(17, 8);
_local1.Paths[2] = new Array(2);
_local1.Paths[2][0] = new SimplePoint(16, 7);
_local1.Paths[2][1] = new SimplePoint(-1, 7);
_local1.Paths[3] = new Array(2);
_local1.Paths[3][0] = new SimplePoint(16, 8);
_local1.Paths[3][1] = new SimplePoint(-1, 8);
_local1.Paths[4] = new Array(2);
_local1.Paths[4][0] = new SimplePoint(7, -1);
_local1.Paths[4][1] = new SimplePoint(7, 17);
_local1.Paths[5] = new Array(2);
_local1.Paths[5][0] = new SimplePoint(8, -1);
_local1.Paths[5][1] = new SimplePoint(8, 16);
_local1.Paths[6] = new Array(2);
_local1.Paths[6][0] = new SimplePoint(7, 17);
_local1.Paths[6][1] = new SimplePoint(7, -1);
_local1.Paths[7] = new Array(2);
_local1.Paths[7][0] = new SimplePoint(8, 16);
_local1.Paths[7][1] = new SimplePoint(8, 0);
_local1.Rounds = new Array();
_local1.Rounds[0] = Round.Create(Game.Language.RoundDesc1);
_local1.Rounds[0].Waves[0] = Wave.Create(15, MonsterConfig.Eye, 45, 0);
_local1.Rounds[0].Waves[1] = Wave.Create(15, MonsterConfig.Eye, 45, 25);
_local1.Rounds[1] = Round.Create(Game.Language.RoundDesc2);
_local1.Rounds[1].Waves[0] = Wave.Create(15, MonsterConfig.Eye, 45, 0);
_local1.Rounds[1].Waves[1] = Wave.Create(15, MonsterConfig.Eye, 45, 25);
_local1.Rounds[2] = Round.Create(Game.Language.RoundDesc3);
_local1.Rounds[2].Waves[0] = Wave.Create(15, MonsterConfig.Boar, 45, 0);
_local1.Rounds[2].Waves[1] = Wave.Create(15, MonsterConfig.Boar, 45, 25);
_local1.Rounds[3] = Round.Create(Game.Language.RoundDesc4);
_local1.Rounds[3].Waves[0] = Wave.Create(15, MonsterConfig.Boar, 44, 0);
_local1.Rounds[3].Waves[1] = Wave.Create(15, MonsterConfig.Boar, 44, 25);
_local1.Rounds[4] = Round.Create(Game.Language.RoundDesc5);
_local1.Rounds[4].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 44, 0);
_local1.Rounds[4].Waves[1] = Wave.Create(15, MonsterConfig.Peon, 44, 24);
_local1.Rounds[5] = Round.Create(Game.Language.RoundDesc6);
_local1.Rounds[5].Waves[0] = Wave.Create(15, MonsterConfig.Peon, 43, 0);
_local1.Rounds[5].Waves[1] = Wave.Create(15, MonsterConfig.Peon, 43, 24);
_local1.Rounds[6] = Round.Create(Game.Language.RoundDesc7);
_local1.Rounds[6].Waves[0] = Wave.Create(14, MonsterConfig.Troll, 43, 0);
_local1.Rounds[6].Waves[1] = Wave.Create(14, MonsterConfig.Troll, 43, 24);
_local1.Rounds[7] = Round.Create(Game.Language.RoundDesc20);
_local1.Rounds[7].Waves[0] = Wave.Create(12, MonsterConfig.TrollBerserker, 43, 0);
_local1.Rounds[7].Waves[1] = Wave.Create(12, MonsterConfig.TrollBerserker, 43, 24);
_local1.Rounds[8] = Round.Create(Game.Language.RoundDesc9);
_local1.Rounds[8].Waves[0] = Wave.Create(11, MonsterConfig.TrollBerserker, 42, 0);
_local1.Rounds[8].Waves[1] = Wave.Create(11, MonsterConfig.TrollBerserker, 42, 23);
_local1.Rounds[9] = Round.Create(Game.Language.RoundDesc10);
_local1.Rounds[9].Waves[0] = Wave.Create(9, MonsterConfig.Grunt, 42, 0);
_local1.Rounds[9].Waves[1] = Wave.Create(9, MonsterConfig.Grunt, 42, 23);
_local1.Rounds[10] = Round.Create(Game.Language.RoundDesc11);
_local1.Rounds[10].Waves[0] = Wave.Create(8, MonsterConfig.Grunt, 42, 0);
_local1.Rounds[10].Waves[1] = Wave.Create(8, MonsterConfig.Grunt, 42, 23);
_local1.Rounds[11] = Round.Create(Game.Language.RoundDesc21);
_local1.Rounds[11].Waves[0] = Wave.Create(9, MonsterConfig.GruntBerserker, 42, 0);
_local1.Rounds[11].Waves[1] = Wave.Create(9, MonsterConfig.GruntBerserker, 42, 22);
_local1.Rounds[12] = Round.Create(Game.Language.RoundDesc13);
_local1.Rounds[12].Waves[0] = Wave.Create(8, MonsterConfig.GruntBerserker, 41, 0);
_local1.Rounds[12].Waves[1] = Wave.Create(8, MonsterConfig.GruntBerserker, 41, 22);
_local1.Rounds[13] = Round.Create(Game.Language.RoundDesc22);
_local1.Rounds[13].Waves[0] = Wave.Create(8, MonsterConfig.GruntBerserker, 41, 0);
_local1.Rounds[13].Waves[1] = Wave.Create(8, MonsterConfig.GruntBerserker, 41, 20);
_local1.Rounds[14] = Round.Create(Game.Language.RoundDesc15);
_local1.Rounds[14].Waves[0] = Wave.Create(8, MonsterConfig.Mercenary, 41, 0);
_local1.Rounds[14].Waves[1] = Wave.Create(8, MonsterConfig.Mercenary, 41, 23);
_local1.Rounds[15] = Round.Create(Game.Language.RoundDesc16);
_local1.Rounds[15].Waves[0] = Wave.Create(1, MonsterConfig.MercenaryVeteran, 0, 0);
_local1.Rounds[16] = Round.Create(Game.Language.RoundDesc17);
_local1.Rounds[16].Waves[0] = Wave.Create(6, MonsterConfig.Dwarf, 41, 0);
_local1.Rounds[16].Waves[1] = Wave.Create(6, MonsterConfig.Dwarf, 41, 25);
_local1.Rounds[17] = Round.Create(Game.Language.RoundDesc18);
_local1.Rounds[17].Waves[0] = Wave.Create(6, MonsterConfig.Dwarf, 40, 0);
_local1.Rounds[17].Waves[1] = Wave.Create(6, MonsterConfig.Dwarf, 40, 20);
_local1.Rounds[18] = Round.Create(Game.Language.RoundDesc19);
_local1.Rounds[18].Waves[0] = Wave.Create(1, MonsterConfig.DwarfStone, 0, 0);
_local1.Rounds[19] = Round.Create(Game.Language.RoundDesc23);
_local1.Rounds[19].Waves[0] = Wave.Create(7, MonsterConfig.Sapper, 40, 0);
_local1.Rounds[19].Waves[1] = Wave.Create(7, MonsterConfig.Sapper, 40, 25);
_local1.Rounds[20] = Round.Create(Game.Language.RoundDesc24);
_local1.Rounds[20].Waves[0] = Wave.Create(7, MonsterConfig.Sapper, 40, 0);
_local1.Rounds[20].Waves[1] = Wave.Create(7, MonsterConfig.Sapper, 40, 25);
_local1.Rounds[21] = Round.Create(Game.Language.RoundDesc26);
_local1.Rounds[21].Waves[0] = Wave.Create(5, MonsterConfig.OgreInfected, 40, 0);
_local1.Rounds[21].Waves[1] = Wave.Create(5, MonsterConfig.OgreInfected, 40, 25);
_local1.Rounds[22] = Round.Create(Game.Language.RoundDesc27);
_local1.Rounds[22].Waves[0] = Wave.Create(6, MonsterConfig.OgreInfected, 39, 0);
_local1.Rounds[22].Waves[1] = Wave.Create(6, MonsterConfig.OgreInfected, 39, 20);
_local1.Rounds[23] = Round.Create(Game.Language.RoundDesc32);
_local1.Rounds[23].Waves[0] = Wave.Create(10, MonsterConfig.OgreSpirit, 39, 0);
_local1.Rounds[24] = Round.Create(Game.Language.RoundDesc25);
_local1.Rounds[24].Waves[0] = Wave.Create(1, MonsterConfig.Ogre, 0, 0);
_local1.Rounds[25] = Round.Create(Game.Language.RoundDesc29);
_local1.Rounds[25].Waves[0] = Wave.Create(5, MonsterConfig.Knight, 38, 0);
_local1.Rounds[25].Waves[1] = Wave.Create(5, MonsterConfig.Knight, 38, 19);
_local1.Rounds[26] = Round.Create(Game.Language.RoundDesc30);
_local1.Rounds[26].Waves[0] = Wave.Create(6, MonsterConfig.Knight, 38, 0);
_local1.Rounds[26].Waves[1] = Wave.Create(6, MonsterConfig.Knight, 38, 19);
_local1.Rounds[27] = Round.Create(Game.Language.RoundDesc33);
_local1.Rounds[27].Waves[0] = Wave.Create(6, MonsterConfig.DeathKnight, 38, 0);
_local1.Rounds[27].Waves[1] = Wave.Create(6, MonsterConfig.DeathKnight, 38, 19);
_local1.Rounds[28] = Round.Create(Game.Language.RoundDesc31);
_local1.Rounds[28].Waves[0] = Wave.Create(1, MonsterConfig.Knight2, 0, 0);
_local1.Rounds[29] = Round.Create(Game.Language.RoundDesc34);
_local1.Rounds[29].Waves[0] = Wave.Create(8, MonsterConfig.Demon, 38, 0);
_local1.Rounds[29].Waves[1] = Wave.Create(8, MonsterConfig.Demon, 38, 19);
return (_local1);
}
}
}//package TowerDefence.Levels
Section 219
//LevelData (TowerDefence.Levels.LevelData)
package TowerDefence.Levels {
public class LevelData {
public var StartingGold;
public var Tiles:Array;
public var Layer1:Array;
public var Layer2:Array;
public var Rounds:Array;
public var Paths:Array;
public var Buildable:Array;
private static var Level:LevelData = new (LevelData);
;
public static var LastPath:int;
public function RandomPath():Array{
LastPath++;
if (LastPath == this.Paths.length){
LastPath = 0;
};
return (this.Paths[LastPath]);
}
public function Dispose():void{
var _local1:int;
var _local2:int;
var _local3:Round;
var _local4:Array;
_local1 = 0;
while (_local1 < this.Rounds.length) {
_local3 = this.Rounds[_local1];
_local4 = _local3.Waves;
_local2 = 0;
while (_local2 < _local4.length) {
Wave.Dispose(_local4[_local2]);
_local2++;
};
Round.Dispose(_local3);
_local1++;
};
}
public static function Create():LevelData{
return (Level);
}
}
}//package TowerDefence.Levels
Section 220
//Map (TowerDefence.Levels.Map)
package TowerDefence.Levels {
import TowerDefence.*;
import flash.display.*;
import flash.geom.*;
import Assets.Tiles.*;
public class Map {
private static const Trees:Array = new Array(8);
private static const Grass:Array = new Array(9);
private static const PlainGrass:Array = new Array(9);
public static function Init():void{
Grass[0] = new Grass1(40, 40);
Grass[1] = new Grass3(40, 40);
Grass[2] = new Grass5(40, 40);
Grass[3] = new Grass6(40, 40);
Grass[4] = new Grass7(40, 40);
Grass[5] = new Grass9(40, 40);
Grass[6] = new Grass10(40, 40);
Grass[7] = new Grass11(40, 40);
Grass[8] = new Grass17(40, 40);
PlainGrass[0] = new Grass2(40, 40);
PlainGrass[1] = new Grass8(40, 40);
PlainGrass[2] = new Grass4(40, 40);
PlainGrass[3] = new Grass15(40, 40);
PlainGrass[4] = new Grass12(40, 40);
PlainGrass[5] = new Grass13(40, 40);
PlainGrass[6] = new Grass14(40, 40);
PlainGrass[7] = new Grass16(40, 40);
PlainGrass[8] = new Grass18(40, 40);
Trees[0] = new Tree1(120, 40);
Trees[1] = new Tree2(120, 40);
Trees[2] = new Tree3(120, 40);
Trees[3] = new Tree4(120, 40);
Trees[4] = new Tree5(120, 40);
Trees[5] = new Tree6(120, 40);
Trees[6] = new Tree7(120, 40);
Trees[7] = new Tree8(120, 40);
}
public static function Draw(_arg1:LevelData):BitmapData{
var _local2:int;
var _local3:int;
var _local4:BitmapData;
var _local5:Point;
var _local6:int;
var _local7:int;
var _local8:int;
_local2 = (_arg1.Layer1[0].length * 40);
_local3 = (_arg1.Layer1.length * 40);
_local4 = new BitmapData(_local2, _local3, false);
_local5 = new Point();
LayeredElement.SetLayers(_arg1.Layer1.length, _arg1.Layer2);
_local6 = 0;
while (_local6 < _arg1.Layer1.length) {
_local7 = 0;
while (_local7 < _arg1.Layer1[0].length) {
_local5.x = (_local7 * 40);
_local5.y = (_local6 * 40);
if (_arg1.Layer1[_local6][_local7] == null){
_local4.copyPixels(GrassTile(), GrassTile().rect, _local5);
} else {
_local4.copyPixels(_arg1.Tiles[_arg1.Layer1[_local6][_local7]], _arg1.Tiles[_arg1.Layer1[_local6][_local7]].rect, _local5);
};
if (_arg1.Layer2[_local6][_local7] == -1){
_local8 = _arg1.Tiles.length;
_arg1.Tiles[_local8] = TreeTile();
_arg1.Layer2[_local6][_local7] = _local8;
};
_local7++;
};
_local6++;
};
return (_local4);
}
private static function GrassTile():BitmapData{
var _local1:int;
Maths.GenerateRandom();
_local1 = Maths.Random(0, 100);
Maths.GenerateRandom();
if (_local1 <= 5){
_local1 = Maths.Random(0, 8);
return (Grass[_local1]);
};
_local1 = Maths.Random(0, 8);
return (PlainGrass[_local1]);
}
private static function TreeTile():BitmapData{
var _local1:int;
Maths.GenerateRandom();
_local1 = Maths.Random(0, 7);
return (Trees[_local1]);
}
}
}//package TowerDefence.Levels
Section 221
//Round (TowerDefence.Levels.Round)
package TowerDefence.Levels {
public class Round {
public var Waves:Array;
public var Description:String;// = ""
private static var Container:Array = new Array();
private static var Pool:Array = new Array();
public function Round(){
Description = "";
super();
}
private static function GetInstance():Round{
if (Pool.length > 0){
return (Pool.pop());
};
return (new (Round));
}
public static function Create(_arg1:String):Round{
var _local2:Round;
_local2 = GetInstance();
_local2.Description = _arg1;
_local2.Waves = new Array();
return (_local2);
}
public static function Dispose(_arg1:Round):void{
Pool.push(_arg1);
}
}
}//package TowerDefence.Levels
Section 222
//Wave (TowerDefence.Levels.Wave)
package TowerDefence.Levels {
import TowerDefence.Monsters.*;
public class Wave {
public var Interval:int;
public var Quantity:int;
public var StartAt:int;
public var Monster:MonsterConfig;
public var Ticks:int;
private static var Container:Array = new Array();
private static var Pool:Array = new Array();
private static function GetInstance():Wave{
if (Pool.length > 0){
return (Pool.pop());
};
return (new (Wave));
}
public static function Create(_arg1:int, _arg2:MonsterConfig, _arg3:int, _arg4:int):Wave{
var _local5:Wave;
_local5 = GetInstance();
_local5.Quantity = _arg1;
_local5.Monster = _arg2;
_local5.StartAt = _arg4;
_local5.Interval = _arg3;
_local5.Ticks = 0;
return (_local5);
}
public static function Dispose(_arg1:Wave):void{
Pool.push(_arg1);
}
}
}//package TowerDefence.Levels
Section 223
//DamageTypes (TowerDefence.Monsters.DamageTypes)
package TowerDefence.Monsters {
public class DamageTypes {
public static const Piercing:int = 0;
public static const Impact:int = 1;
public static const Poison:int = 3;
public static const Ice:int = 4;
public static const Nothing:int = -1;
public static const Fire:int = 2;
}
}//package TowerDefence.Monsters
Section 224
//Directions (TowerDefence.Monsters.Directions)
package TowerDefence.Monsters {
public class Directions {
public static const East:int = 2;
public static const North:int = 0;
public static const Dead:int = 4;
public static const South:int = 1;
public static const West:int = 3;
}
}//package TowerDefence.Monsters
Section 225
//DumbMonster (TowerDefence.Monsters.DumbMonster)
package TowerDefence.Monsters {
import TowerDefence.*;
import flash.display.*;
import flash.events.*;
public class DumbMonster extends MovieClip {
private var FrameTicks:int;
private var Config:MonsterConfig;
private var Container:Bitmap;
private var FrameIndex:int;
private var Frames:Array;
public function DumbMonster(_arg1:MonsterConfig){
this.Container = new Bitmap();
this.Container.x = -20;
this.Container.y = Maths.Random(10, 460);
this.addChild(this.Container);
this.Config = _arg1;
this.Frames = _arg1.Images[2];
this.FrameIndex = 0;
this.FrameTicks = 6;
this.addEventListener(Event.ENTER_FRAME, Tick);
}
public static function Tick(_arg1:Event):void{
var _local2:DumbMonster;
_local2 = (_arg1.target as DumbMonster);
_local2.x = (_local2.x + 6);
if (_local2.FrameTicks == 0){
_local2.FrameTicks = 6;
_local2.FrameIndex++;
if (_local2.FrameIndex == _local2.Frames.length){
_local2.FrameIndex = 0;
};
} else {
_local2.FrameTicks--;
};
_local2.Container.bitmapData = _local2.Frames[_local2.FrameIndex];
if (_local2.x > 670){
_local2.removeEventListener(Event.ENTER_FRAME, Tick);
_local2.parent.removeChild(_local2);
};
}
}
}//package TowerDefence.Monsters
Section 226
//ImbueEffect (TowerDefence.Monsters.ImbueEffect)
package TowerDefence.Monsters {
import TowerDefence.*;
import TowerDefence.Towers.*;
public class ImbueEffect {
public var OpacityIncrement:Number;
public var Timer:int;
public var Opacity:Number;
public var Colour:uint;
public var Type:int;
private static const FireColour:uint = 0xFF0000;
private static const PoisonColour:uint = 0xFF00;
private static const IceColour:uint = 6737151;
private static var CurrentImbueEffect:ImbueEffect;
public function ImbueEffect(_arg1:int, _arg2:int){
this.Type = _arg2;
this.Timer = _arg1;
this.Opacity = 1;
this.OpacityIncrement = (1 / _arg1);
switch (this.Type){
case ImbueTypes.Fire:
this.Colour = FireColour;
this.Timer = (this.Timer + Game.FireBonus);
break;
case ImbueTypes.Ice:
this.Colour = IceColour;
this.Timer = (this.Timer + Game.IceBonus);
break;
case ImbueTypes.Poison:
this.Colour = PoisonColour;
this.Timer = (this.Timer + Game.PoisonBonus);
break;
};
}
public static function Tick(_arg1:Array):void{
var _local2:int;
_local2 = (_arg1.length - 1);
while (_local2 > -1) {
CurrentImbueEffect = _arg1[_local2];
CurrentImbueEffect.Timer--;
CurrentImbueEffect.Opacity = (CurrentImbueEffect.Opacity - CurrentImbueEffect.OpacityIncrement);
if (CurrentImbueEffect.Timer == 0){
_arg1.splice(_local2, 1);
};
_local2--;
};
}
}
}//package TowerDefence.Monsters
Section 227
//ImmuneTypes (TowerDefence.Monsters.ImmuneTypes)
package TowerDefence.Monsters {
public class ImmuneTypes {
public static const Fire:int = 1;
public static const Poison:int = 3;
public static const Ice:int = 2;
public static const Nothing:int = 0;
}
}//package TowerDefence.Monsters
Section 228
//Monster (TowerDefence.Monsters.Monster)
package TowerDefence.Monsters {
import TowerDefence.*;
import TowerDefence.Towers.*;
import flash.display.*;
import flash.geom.*;
import flash.filters.*;
public class Monster {
public var FrameIndex:int;
public var Dying:Boolean;// = false
public var Armour:int;
public var RealLocation:SimplePoint;
public var Invisible:Boolean;
private var ClickArea:SimpleRectangle;
public var YIncrement:int;
private var PathIndex:int;
private var Moved:Number;
private var FrameTicks:int;
private var ClickZone:ClickZone;
public var HitPoints:int;
public var StartHitPoints:int;
private var GridLocation:SimplePoint;
private var Path:Array;
public var Frames:Array;
private var DisplayCorpse:int;
public var Location:SimplePoint;
public var RevealEffects:Array;
public var Direction:int;
public var Config:MonsterConfig;
public var Ignore:Boolean;// = false
public var ImbueEffects:Array;
public var Center:SimplePoint;
public var XIncrement:int;
private static const RelativeLocation:Point = new Point(0, 0);
private static const HealthRectangle:Rectangle = new Rectangle(1, 1, 0, 2);
private static const HealthRectangleBorder:Rectangle = new Rectangle(0, 0, 38, 4);
private static const ZeroPoint:Point = new Point(0, 0);
private static var CurrentMonster:Monster;
private static var FilteredBitmap:BitmapData;
private static var TempImage:BitmapData;
private static var Hovering:Boolean = false;
private static var MoveSpeed:int;
private static var Filter:GlowFilter = new GlowFilter();
public static var GoldAdjuster:Number;
public static var Container:Array = new Array();
private static var CurrentMonsterConfig:MonsterConfig;
public static var HealthAdjuster:Number;
private static var MoveAmount:Number;
private static var TempGridLocation:SimplePoint = new SimplePoint();
private static var LowGraphicsMode:Boolean;
public static var ArmourAdjuster:Number;
private static var Pool:Array = new Array();
public function Monster(){
Ignore = false;
Dying = false;
GridLocation = new SimplePoint();
Location = new SimplePoint();
RealLocation = new SimplePoint();
Center = new SimplePoint();
ImbueEffects = new Array();
RevealEffects = new Array();
ClickArea = new SimpleRectangle(0, 0, 40, 40);
Path = new Array();
super();
}
private static function GetInstance():Monster{
if (Pool.length > 0){
return (Pool.pop());
};
return (new (Monster));
}
public static function HasRevealEffect(_arg1:Monster, _arg2:Tower):Boolean{
var _local3:int;
if (_arg1.RevealEffects.length == 0){
return (false);
};
_local3 = 0;
while (_local3 < _arg1.RevealEffects.length) {
if (_arg1.RevealEffects[_local3].Tower == _arg2){
return (true);
};
_local3++;
};
return (false);
}
public static function Hit(_arg1:Monster, _arg2:Tower):void{
var _local3:int;
if (_arg1.Ignore){
return;
};
_local3 = Maths.Random(_arg2.CurrentLevel.DamageMin, _arg2.CurrentLevel.DamageMax);
_local3 = (_local3 - _arg1.Armour);
if (_arg2.Config.DamageType == _arg1.Config.WeakAgainst){
_local3 = int((_local3 * 1.5));
} else {
if (_arg2.Config.DamageType == _arg1.Config.StrongAgainst){
_local3 = int((_local3 / 2.5));
};
};
if (_local3 <= 0){
_local3 = 1;
};
_local3 = (_local3 + ((_arg2.Bonus / 10) * _local3));
_local3 = (_local3 + Game.DamageBonus);
if ((((((_arg2.Imbue == ImbueTypes.Ice)) && (!(HasEffect(_arg1, ImbueTypes.Ice))))) && (!((_arg1.Config.ImmuneAgainst == ImmuneTypes.Ice))))){
_arg1.ImbueEffects.push(new ImbueEffect((_arg2.CurrentLevel.DamageDuration + Game.IceBonus), ImbueTypes.Ice));
} else {
if ((((((_arg2.Imbue == ImbueTypes.Poison)) && (!(HasEffect(_arg1, ImbueTypes.Poison))))) && (!((_arg1.Config.ImmuneAgainst == ImmuneTypes.Poison))))){
_arg1.ImbueEffects.push(new ImbueEffect((_arg2.CurrentLevel.DamageDuration + Game.PoisonBonus), ImbueTypes.Poison));
} else {
if ((((((_arg2.Imbue == ImbueTypes.Fire)) && (!(HasEffect(_arg1, ImbueTypes.Fire))))) && (!((_arg1.Config.ImmuneAgainst == ImmuneTypes.Fire))))){
_arg1.ImbueEffects.push(new ImbueEffect((_arg2.CurrentLevel.DamageDuration + Game.FireBonus), ImbueTypes.Fire));
};
};
};
ApplyDamage(_local3, _arg1, _arg2);
}
public static function ApplyDamage(_arg1:int, _arg2:Monster, _arg3:Tower, _arg4:Boolean=true):void{
var _local5:int;
var _local6:int;
_arg2.HitPoints = (_arg2.HitPoints - _arg1);
if (Game.ViewingMonster == _arg2){
Game.MainBar.MonsterInfo.Refresh();
};
if (_arg2.HitPoints < 1){
if (((_arg4) && (Maths.WithinVisibleArea(_arg2.RealLocation.X, _arg2.RealLocation.Y, _arg2.Frames[_arg2.FrameIndex].width, _arg2.Frames[_arg2.FrameIndex].height)))){
SoundManager.PlayMonsterSound(_arg2.Config.DeathSound);
};
_arg2.Ignore = true;
_arg2.Dying = true;
_arg2.Frames = _arg2.Config.Images[Directions.Dead];
_arg2.FrameIndex = 0;
_arg2.FrameTicks = 4;
if (_arg2.Frames.length == 0){
Remove(_arg2);
};
if (Game.ViewingMonster == _arg2){
Game.MainBar.ShowRoundInfo();
Game.ViewingMonster = null;
};
_local5 = (_arg2.Config.GoldMax - _arg2.Config.GoldMin);
_local6 = (GoldAdjuster * Maths.Random(_arg2.Config.GoldMin, _arg2.Config.GoldMax));
if (_local6 <= 0){
_local6 = 1;
};
FadingText.Create(("+" + _local6), _arg2.Center.X, _arg2.Center.Y);
Statistics.Kills = (Statistics.Kills + 1);
Statistics.MonsterKills.Monster2 = String((int(Statistics.MonsterKills.Monster2) + 1));
Statistics.TowerKills.Tower1 = Number((int(Statistics.TowerKills.Tower1) + 1));
Statistics.MissilesFired.Missile1 = uint((int(Statistics.MissilesFired.Missile1) + 1));
Statistics.Gold = (Statistics.Gold + _local6);
Statistics.MonsterKills.Monster4 = String((int(Statistics.MonsterKills.Monster4) + _local6));
Statistics.TowerKills.Tower3 = Number((int(Statistics.TowerKills.Tower3) + _local6));
Statistics.MissilesFired.Missile2 = uint((int(Statistics.MissilesFired.Missile2) + _local6));
};
}
private static function Remove(_arg1:Monster, _arg2:int=-1):void{
ClickZone.Remove(_arg1.ClickZone);
Pool.push(_arg1);
if (_arg2 == -1){
Container.splice(Container.indexOf(_arg1), 1);
} else {
Container.splice(_arg2, 1);
};
}
public static function Tick(_arg1:BitmapData):void{
var _local2:int;
var _local3:int;
var _local4:int;
if (Container.length == 0){
return;
};
Hovering = false;
LowGraphicsMode = Game.LowGraphicsMode;
_local2 = (Container.length - 1);
for (;_local2 > -1;_local2--) {
CurrentMonster = Container[_local2];
CurrentMonsterConfig = CurrentMonster.Config;
if (CurrentMonster.Dying){
if (CurrentMonster.FrameTicks == 0){
if (CurrentMonster.FrameIndex == (CurrentMonster.Frames.length - 1)){
if (CurrentMonster.DisplayCorpse <= 0){
Remove(CurrentMonster);
continue;
} else {
CurrentMonster.DisplayCorpse--;
};
} else {
CurrentMonster.FrameTicks = 4;
CurrentMonster.FrameIndex++;
};
} else {
CurrentMonster.FrameTicks--;
};
if (Maths.WithinVisibleArea(CurrentMonster.RealLocation.X, CurrentMonster.RealLocation.Y, CurrentMonster.Frames[CurrentMonster.FrameIndex].width, CurrentMonster.Frames[CurrentMonster.FrameIndex].height)){
RelativeLocation.x = (CurrentMonster.RealLocation.X - Game.MapRectangle.x);
RelativeLocation.y = (CurrentMonster.RealLocation.Y - Game.MapRectangle.y);
LayeredElement.CreateAtBack(CurrentMonster.Frames[CurrentMonster.FrameIndex], RelativeLocation, CurrentMonster.GridLocation.Y);
};
} else {
if (((!(Hovering)) && (SimpleRectangle.ContainsPoint(CurrentMonster.ClickArea, Game.MouseLocation)))){
Game.HandCursor = true;
Hovering = true;
};
if (CurrentMonster.Moved <= 0){
CurrentMonster.Moved = 40;
CurrentMonster.GridLocation.X = (CurrentMonster.Location.X / 40);
CurrentMonster.GridLocation.Y = (CurrentMonster.Location.Y / 40);
if (SimplePoint.Equal(CurrentMonster.GridLocation, CurrentMonster.Path[CurrentMonster.PathIndex])){
CurrentMonster.PathIndex++;
if (CurrentMonster.PathIndex < CurrentMonster.Path.length){
if (CurrentMonster.GridLocation.X < CurrentMonster.Path[CurrentMonster.PathIndex].X){
CurrentMonster.Direction = Directions.East;
CurrentMonster.XIncrement = 2;
CurrentMonster.YIncrement = 0;
} else {
if (CurrentMonster.GridLocation.X > CurrentMonster.Path[CurrentMonster.PathIndex].X){
CurrentMonster.Direction = Directions.West;
CurrentMonster.XIncrement = -2;
CurrentMonster.YIncrement = 0;
} else {
if (CurrentMonster.GridLocation.Y < CurrentMonster.Path[CurrentMonster.PathIndex].Y){
CurrentMonster.Direction = Directions.South;
CurrentMonster.XIncrement = 0;
CurrentMonster.YIncrement = 2;
} else {
if (CurrentMonster.GridLocation.Y > CurrentMonster.Path[CurrentMonster.PathIndex].Y){
CurrentMonster.Direction = Directions.North;
CurrentMonster.XIncrement = 0;
CurrentMonster.YIncrement = -2;
};
};
};
};
CurrentMonster.Frames = CurrentMonster.Config.Images[CurrentMonster.Direction];
CurrentMonster.FrameIndex = 0;
};
};
//unresolved if
Statistics.Lives--;
Statistics.MonsterKills.Monster6 = String((int(Statistics.MonsterKills.Monster6) - 1));
Statistics.TowerKills.Tower5 = Number((int(Statistics.TowerKills.Tower5) - 1));
Statistics.MissilesFired.Missile4 = uint((int(Statistics.MissilesFired.Missile4) - 1));
if (Statistics.Lives <= 0){
_local3 = (Statistics.Gold + Statistics.Kills);
Statistics.Points = (Statistics.Points + _local3);
Statistics.MonsterKills.Monster7 = String((int(Statistics.MonsterKills.Monster7) + _local3));
Statistics.TowerKills.Tower6 = Number((int(Statistics.TowerKills.Tower6) + _local3));
Statistics.MissilesFired.Missile6 = uint((int(Statistics.MissilesFired.Missile6) + _local3));
Game.Lose();
return;
};
Remove(CurrentMonster, _local2);
} else {
MoveSpeed = (HasEffect(CurrentMonster, ImbueTypes.Ice)) ? (CurrentMonsterConfig.Speed * 3) : CurrentMonsterConfig.Speed;
if (CurrentMonster.XIncrement != 0){
MoveAmount = (CurrentMonster.XIncrement / MoveSpeed);
CurrentMonster.Location.X = (CurrentMonster.Location.X + MoveAmount);
CurrentMonster.Center.X = (CurrentMonster.Center.X + MoveAmount);
CurrentMonster.ClickArea.X = (CurrentMonster.ClickArea.X + MoveAmount);
CurrentMonster.RealLocation.X = (CurrentMonster.RealLocation.X + MoveAmount);
CurrentMonster.Moved = (CurrentMonster.Moved - Math.abs(MoveAmount));
if (CurrentMonster.Moved < 0.01){
CurrentMonster.Moved = 0;
CurrentMonster.Location.X = ((CurrentMonster.GridLocation.X + ((CurrentMonster.XIncrement > 0)) ? 1 : -1) * 40);
CurrentMonster.RealLocation.X = (CurrentMonster.Location.X + CurrentMonsterConfig.ImageOffset.x);
CurrentMonster.Center.X = (CurrentMonster.RealLocation.X + (20 - CurrentMonsterConfig.ImageOffset.x));
CurrentMonster.ClickArea.X = (CurrentMonster.Center.X - (0.5 * CurrentMonster.ClickArea.Width));
};
} else {
MoveAmount = (CurrentMonster.YIncrement / MoveSpeed);
CurrentMonster.Location.Y = (CurrentMonster.Location.Y + MoveAmount);
CurrentMonster.Center.Y = (CurrentMonster.Center.Y + MoveAmount);
CurrentMonster.ClickArea.Y = (CurrentMonster.ClickArea.Y + MoveAmount);
CurrentMonster.RealLocation.Y = (CurrentMonster.RealLocation.Y + MoveAmount);
CurrentMonster.Moved = (CurrentMonster.Moved - Math.abs(MoveAmount));
if (CurrentMonster.Moved < 0.01){
CurrentMonster.Moved = 0;
CurrentMonster.Location.Y = ((CurrentMonster.GridLocation.Y + ((CurrentMonster.YIncrement > 0)) ? 1 : -1) * 40);
CurrentMonster.RealLocation.Y = (CurrentMonster.Location.Y + CurrentMonsterConfig.ImageOffset.y);
CurrentMonster.Center.Y = (CurrentMonster.RealLocation.Y + (20 - CurrentMonsterConfig.ImageOffset.y));
CurrentMonster.ClickArea.Y = (CurrentMonster.Center.Y - (0.5 * CurrentMonster.ClickArea.Height));
};
};
if (CurrentMonster.FrameTicks == 0){
CurrentMonster.FrameTicks = (HasEffect(CurrentMonster, ImbueTypes.Ice)) ? (CurrentMonsterConfig.Speed * 8) : (CurrentMonsterConfig.Speed * 3);
CurrentMonster.FrameIndex++;
if (CurrentMonster.FrameIndex == CurrentMonster.Frames.length){
CurrentMonster.FrameIndex = 0;
};
} else {
CurrentMonster.FrameTicks--;
};
if (CurrentMonster.ImbueEffects.length > 0){
ImbueEffect.Tick(CurrentMonster.ImbueEffects);
};
if (CurrentMonster.RevealEffects.length > 0){
RevealEffect.Tick(CurrentMonster.RevealEffects, CurrentMonster);
CurrentMonster.Invisible = (CurrentMonster.RevealEffects.length == 0);
};
if (CurrentMonster.Invisible){
} else {
if (!Maths.WithinVisibleArea(CurrentMonster.RealLocation.X, CurrentMonster.RealLocation.Y, CurrentMonster.Frames[CurrentMonster.FrameIndex].width, CurrentMonster.Frames[CurrentMonster.FrameIndex].height)){
} else {
TempImage = CurrentMonster.Frames[CurrentMonster.FrameIndex].clone();
if (((CurrentMonsterConfig.Invisible) && (!(LowGraphicsMode)))){
Filter.color = 0xFFFFFF;
Filter.alpha = 0.8;
TempImage.applyFilter(TempImage, TempImage.rect, ZeroPoint, Filter);
};
if (CurrentMonster.ImbueEffects.length > 0){
_local4 = (CurrentMonster.ImbueEffects.length - 1);
while (_local4 > -1) {
if (!LowGraphicsMode){
Filter.color = CurrentMonster.ImbueEffects[_local4].Colour;
Filter.alpha = CurrentMonster.ImbueEffects[_local4].Opacity;
TempImage.applyFilter(TempImage, TempImage.rect, ZeroPoint, Filter);
};
if (CurrentMonster.ImbueEffects[_local4].Type != ImbueTypes.Ice){
ApplyDamage(1, CurrentMonster, null);
};
_local4--;
};
};
if (!LowGraphicsMode){
HealthRectangle.width = Math.round((36 * (CurrentMonster.HitPoints / CurrentMonster.StartHitPoints)));
TempImage.fillRect(HealthRectangleBorder, 1879048192);
TempImage.fillRect(HealthRectangle, 2154220595);
};
RelativeLocation.x = (CurrentMonster.RealLocation.X - Game.MapRectangle.x);
RelativeLocation.y = (CurrentMonster.RealLocation.Y - Game.MapRectangle.y);
LayeredElement.Create(TempImage, RelativeLocation, CurrentMonster.GridLocation.Y);
};
};
};
};
};
}
public static function Create(_arg1:MonsterConfig):void{
var monster:Monster;
var config = _arg1;
monster = GetInstance();
monster.Config = config;
monster.HitPoints = (HealthAdjuster * (config.BaseHitPoints + (Game.RoundNumber * config.IncreaseHitPoints)));
monster.StartHitPoints = monster.HitPoints;
monster.Armour = (ArmourAdjuster * (config.BaseArmour + (Game.RoundNumber * config.IncreaseArmour)));
monster.Ignore = false;
monster.Dying = false;
monster.DisplayCorpse = 50;
monster.Path = Game.Level.RandomPath();
monster.PathIndex = 0;
monster.GridLocation.X = monster.Path[monster.PathIndex].X;
monster.GridLocation.Y = monster.Path[monster.PathIndex].Y;
monster.Location.X = (monster.GridLocation.X * 40);
monster.Location.Y = (monster.GridLocation.Y * 40);
monster.RealLocation.X = ((monster.GridLocation.X * 40) + config.ImageOffset.x);
monster.RealLocation.Y = ((monster.GridLocation.Y * 40) + config.ImageOffset.y);
monster.Center.X = (monster.RealLocation.X + (20 - config.ImageOffset.x));
monster.Center.Y = (monster.RealLocation.Y + (20 - config.ImageOffset.y));
monster.ImbueEffects = new Array();
monster.RevealEffects = new Array();
monster.Frames = config.Images[0];
monster.FrameIndex = 0;
monster.FrameTicks = 6;
monster.ClickArea.Width = monster.Frames[0].width;
monster.ClickArea.Height = monster.Frames[0].height;
monster.ClickArea.X = (monster.Center.X - (0.5 * monster.ClickArea.Width));
monster.ClickArea.Y = ((monster.Center.Y - (0.5 * monster.ClickArea.Height)) + 20);
monster.ClickZone = ClickZone.Create(monster.ClickArea, function (){
ShowMonster(monster);
});
monster.Moved = 0;
monster.Invisible = config.Invisible;
if (monster.Path[0].X == -1){
monster.Direction = Directions.East;
monster.XIncrement = 2;
monster.YIncrement = 0;
monster.Frames = config.Images[Directions.East];
} else {
if (monster.Path[0].X == Game.MapWidthCells){
monster.Direction = Directions.West;
monster.XIncrement = -2;
monster.YIncrement = 0;
monster.Frames = config.Images[Directions.West];
} else {
if (monster.Path[0].Y == -1){
monster.Direction = Directions.South;
monster.XIncrement = 0;
monster.YIncrement = 2;
monster.Frames = config.Images[Directions.South];
} else {
if (monster.Path[0].Y == Game.MapHeightCells){
monster.Direction = Directions.North;
monster.XIncrement = 0;
monster.YIncrement = -2;
monster.Frames = config.Images[Directions.North];
};
};
};
};
Container.push(monster);
}
public static function HasEffect(_arg1:Monster, _arg2:int):Boolean{
var _local3:int;
if (_arg1.ImbueEffects.length == 0){
return (false);
};
_local3 = 0;
while (_local3 < _arg1.ImbueEffects.length) {
if (_arg1.ImbueEffects[_local3].Type == _arg2){
return (true);
};
_local3++;
};
return (false);
}
public static function RemoveAll():void{
var _local1:int;
_local1 = (Container.length - 1);
while (_local1 > -1) {
Remove(Container[_local1], _local1);
_local1--;
};
}
private static function ShowMonster(_arg1:Monster):void{
Game.MainBar.MonsterInfo.Show(_arg1);
}
}
}//package TowerDefence.Monsters
Section 229
//MonsterConfig (TowerDefence.Monsters.MonsterConfig)
package TowerDefence.Monsters {
import flash.display.*;
import flash.media.*;
import flash.geom.*;
import Assets.Monsters.*;
public class MonsterConfig {
public var BaseArmour:int;
public var GoldMax:int;
public var WeakAgainst:int;
public var Thumbnail:BitmapData;
public var Invisible:Boolean;// = false
public var StrongAgainst:int;
public var IncreaseHitPoints:Number;
public var ImmuneAgainst:int;
public var Images:Array;
public var DeathSound:Sound;
public var BaseHitPoints:int;
public var Speed:Number;
public var Name:String;
public var ImageOffset:Point;
public var IncreaseArmour:Number;
public var GoldMin:int;
public static const DeathKnight:MonsterConfig = new (MonsterConfig);
;
public static const MercenaryVeteran:MonsterConfig = new (MonsterConfig);
;
public static const Grunt:MonsterConfig = new (MonsterConfig);
;
public static const Eye:MonsterConfig = new (MonsterConfig);
;
public static const GruntBerserker:MonsterConfig = new (MonsterConfig);
;
public static const Sapper:MonsterConfig = new (MonsterConfig);
;
private static const SliceRectangle:Rectangle = new Rectangle();
public static const Knight2:MonsterConfig = new (MonsterConfig);
;
private static const ZeroPoint:Point = new Point();
public static const Ogre:MonsterConfig = new (MonsterConfig);
;
public static const Knight:MonsterConfig = new (MonsterConfig);
;
public static const TrollScout:MonsterConfig = new (MonsterConfig);
;
public static const Peon:MonsterConfig = new (MonsterConfig);
;
public static const OgreInfected:MonsterConfig = new (MonsterConfig);
;
public static const Dwarf:MonsterConfig = new (MonsterConfig);
;
public static const DwarfStone:MonsterConfig = new (MonsterConfig);
;
public static const PeonSpirit:MonsterConfig = new (MonsterConfig);
;
public static const Demon:MonsterConfig = new (MonsterConfig);
;
public static const GruntScout:MonsterConfig = new (MonsterConfig);
;
public static const Troll:MonsterConfig = new (MonsterConfig);
;
public static const KnightBlack:MonsterConfig = new (MonsterConfig);
;
public static const Mercenary:MonsterConfig = new (MonsterConfig);
;
public static const Boar:MonsterConfig = new (MonsterConfig);
;
public static const TrollBerserker:MonsterConfig = new (MonsterConfig);
;
public static const OgreSpirit:MonsterConfig = new (MonsterConfig);
;
private static var Num:int;
private static var Slice:BitmapData;
public function MonsterConfig(){
StrongAgainst = DamageTypes.Nothing;
WeakAgainst = DamageTypes.Nothing;
ImmuneAgainst = ImmuneTypes.Nothing;
Invisible = false;
Images = new Array(4);
super();
}
private static function SliceImages(_arg1:BitmapData, _arg2:int, _arg3:int):Array{
var _local4:BitmapData;
var _local5:int;
var _local6:int;
var _local7:BitmapData;
var _local8:*;
SliceRectangle.width = _arg2;
SliceRectangle.height = _arg3;
_local4 = new BitmapData(_arg2, _arg3, true, 0xFFFFFF);
Num = (_arg1.width / _arg2);
_local8 = new Array(5);
_local8[0] = new Array();
_local8[1] = new Array();
_local8[2] = new Array();
_local8[3] = new Array();
_local8[4] = new Array();
_local5 = 0;
while (_local5 < Num) {
SliceRectangle.x = (_local5 * _arg2);
_local6 = 0;
while (_local6 < 5) {
SliceRectangle.y = (_local6 * _arg3);
_local7 = new BitmapData(_arg2, _arg3, true, 0xFFFFFF);
_local7.copyPixels(_arg1, SliceRectangle, ZeroPoint);
if (_local7.compare(_local4) != 0){
_local8[_local6].push(_local7);
};
_local6++;
};
_local5++;
};
return (_local8);
}
private static function SliceThumbnail(_arg1:BitmapData, _arg2:int, _arg3:int):BitmapData{
SliceRectangle.x = _arg2;
SliceRectangle.y = _arg3;
SliceRectangle.width = 72;
SliceRectangle.height = 72;
Slice = new BitmapData(72, 72);
Slice.copyPixels(_arg1, SliceRectangle, ZeroPoint);
return (Slice);
}
public static function Init():void{
var _local1:BitmapData;
Eye.DeathSound = new EyeDeath();
Eye.Images = SliceImages(new Eye(32, 160), 32, 32);
Boar.DeathSound = new BoarDeath();
Boar.Images = SliceImages(new Boar(32, 160), 32, 32);
Peon.DeathSound = new PeonDeath();
Peon.Images = SliceImages(new Peon(140, 140), 28, 28);
PeonSpirit.DeathSound = new PeonDeath();
PeonSpirit.Images = SliceImages(new PeonSpirit(140, 140), 28, 28);
Troll.DeathSound = new TrollDeath();
Troll.Images = SliceImages(new Troll(240, 240), 48, 48);
TrollBerserker.DeathSound = new TrollDeath();
TrollBerserker.Images = SliceImages(new TrollBerserker(240, 240), 48, 48);
TrollScout.DeathSound = new TrollDeath();
TrollScout.Images = SliceImages(new TrollScout(240, 240), 48, 48);
Grunt.DeathSound = new GruntDeath();
Grunt.Images = SliceImages(new Grunt(235, 275), 47, 55);
GruntBerserker.DeathSound = new GruntDeath();
GruntBerserker.Images = SliceImages(new GruntBerserker(235, 275), 47, 55);
GruntScout.DeathSound = new GruntDeath();
GruntScout.Images = SliceImages(new GruntScout(235, 275), 47, 55);
Mercenary.DeathSound = new MercenaryDeath();
Mercenary.Images = SliceImages(new Mercenary(200, 260), 40, 52);
Dwarf.DeathSound = new DwarfDeath();
Dwarf.Images = SliceImages(new Dwarf(330, 0xFF), 55, 51);
Sapper.DeathSound = new SapperDeath();
Sapper.Images = SliceImages(new Sapper(504, 230), 56, 46);
OgreInfected.DeathSound = new OgreDeath();
OgreInfected.Images = SliceImages(new OgreInfected(265, 285), 53, 57);
OgreSpirit.DeathSound = new OgreDeath();
OgreSpirit.Images = SliceImages(new OgreSpirit(265, 285), 53, 57);
Knight.DeathSound = new KnightDeath();
Knight.Images = SliceImages(new Knight(315, 320), 63, 64);
KnightBlack.DeathSound = new KnightDeath();
KnightBlack.Images = SliceImages(new KnightBlack(315, 320), 63, 64);
DeathKnight.DeathSound = new DeathKnightDeath();
DeathKnight.Images = SliceImages(new DeathKnight(248, 310), 62, 62);
Demon.DeathSound = new DemonDeath();
Demon.Images = SliceImages(new Demon(295, 280), 59, 56);
MercenaryVeteran.DeathSound = new MercenaryVeteranDeath();
MercenaryVeteran.Images = SliceImages(new MercenaryVeteran(200, 260), 40, 52);
DwarfStone.DeathSound = new DwarfDeath();
DwarfStone.Images = SliceImages(new DwarfStone(330, 0xFF), 55, 51);
Ogre.DeathSound = new OgreDeath();
Ogre.Images = SliceImages(new Ogre(265, 285), 53, 57);
Knight2.DeathSound = new KnightDeath();
Knight2.Images = SliceImages(new Knight(315, 320), 63, 64);
_local1 = new Thumbnails(432, 288);
Eye.Thumbnail = SliceThumbnail(_local1, 144, 216);
Boar.Thumbnail = SliceThumbnail(_local1, 216, 216);
Peon.Thumbnail = SliceThumbnail(_local1, 288, 0);
PeonSpirit.Thumbnail = SliceThumbnail(_local1, 288, 72);
Troll.Thumbnail = SliceThumbnail(_local1, 216, 0);
TrollBerserker.Thumbnail = SliceThumbnail(_local1, 216, 72);
TrollScout.Thumbnail = SliceThumbnail(_local1, 216, 144);
Mercenary.Thumbnail = SliceThumbnail(_local1, 0, 144);
MercenaryVeteran.Thumbnail = SliceThumbnail(_local1, 0, 216);
Grunt.Thumbnail = SliceThumbnail(_local1, 72, 0);
GruntBerserker.Thumbnail = SliceThumbnail(_local1, 72, 72);
GruntScout.Thumbnail = SliceThumbnail(_local1, 72, 144);
Dwarf.Thumbnail = SliceThumbnail(_local1, 360, 0);
DwarfStone.Thumbnail = SliceThumbnail(_local1, 360, 72);
Sapper.Thumbnail = SliceThumbnail(_local1, 0, 72);
Ogre.Thumbnail = SliceThumbnail(_local1, 144, 0);
OgreInfected.Thumbnail = SliceThumbnail(_local1, 144, 72);
OgreSpirit.Thumbnail = SliceThumbnail(_local1, 144, 144);
Knight.Thumbnail = SliceThumbnail(_local1, 288, 144);
Knight2.Thumbnail = SliceThumbnail(_local1, 288, 144);
KnightBlack.Thumbnail = SliceThumbnail(_local1, 288, 216);
DeathKnight.Thumbnail = SliceThumbnail(_local1, 72, 216);
Demon.Thumbnail = SliceThumbnail(_local1, 0, 0);
_local1 = null;
}
Eye.ImageOffset = new Point(6, 6);
Eye.Name = "Scouting Eye";
Eye.BaseHitPoints = 10;
Eye.BaseArmour = 0;
Eye.IncreaseHitPoints = 4;
Eye.IncreaseArmour = 0;
Eye.Speed = 1;
Eye.GoldMin = 0;
Eye.GoldMax = 1;
Boar.ImageOffset = new Point(4, 4);
Boar.Name = "Posessed Boar";
Boar.BaseHitPoints = 15;
Boar.BaseArmour = 0;
Boar.IncreaseHitPoints = 6;
Boar.IncreaseArmour = 0.05;
Boar.Speed = 1.1;
Boar.GoldMin = 0;
Boar.GoldMax = 1;
Peon.ImageOffset = new Point(6, 6);
Peon.Name = "Peon";
Peon.BaseHitPoints = 20;
Peon.BaseArmour = 0;
Peon.IncreaseHitPoints = 8;
Peon.IncreaseArmour = 0.1;
Peon.Speed = 1.2;
Peon.GoldMin = 1;
Peon.GoldMax = 1;
PeonSpirit.ImageOffset = new Point(6, 6);
PeonSpirit.Name = "Peon Spirit";
PeonSpirit.BaseHitPoints = 25;
PeonSpirit.BaseArmour = 0;
PeonSpirit.IncreaseHitPoints = 10;
PeonSpirit.IncreaseArmour = 0.15;
PeonSpirit.Speed = 1.2;
PeonSpirit.GoldMin = 1;
PeonSpirit.GoldMax = 1;
PeonSpirit.Invisible = true;
Troll.ImageOffset = new Point(-4, -4);
Troll.Name = "Troll";
Troll.BaseHitPoints = 30;
Troll.BaseArmour = 0;
Troll.IncreaseHitPoints = 11;
Troll.IncreaseArmour = 0.2;
Troll.Speed = 1.5;
Troll.GoldMin = 1;
Troll.GoldMax = 2;
TrollBerserker.ImageOffset = new Point(-4, -4);
TrollBerserker.Name = "Beserker Troll";
TrollBerserker.BaseHitPoints = 35;
TrollBerserker.BaseArmour = 0;
TrollBerserker.IncreaseHitPoints = 12;
TrollBerserker.IncreaseArmour = 0.25;
TrollBerserker.Speed = 1.5;
TrollBerserker.GoldMin = 1;
TrollBerserker.GoldMax = 2;
TrollScout.ImageOffset = new Point(-4, -4);
TrollScout.Name = "Troll Scout";
TrollScout.BaseHitPoints = 40;
TrollScout.BaseArmour = 0;
TrollScout.IncreaseHitPoints = 13;
TrollScout.IncreaseArmour = 0.3;
TrollScout.Speed = 1.4;
TrollScout.GoldMin = 1;
TrollScout.GoldMax = 2;
TrollScout.Invisible = true;
Grunt.ImageOffset = new Point(-3, -8);
Grunt.Name = "Grunt";
Grunt.BaseHitPoints = 55;
Grunt.BaseArmour = 0;
Grunt.IncreaseHitPoints = 14;
Grunt.IncreaseArmour = 0.35;
Grunt.Speed = 1.8;
Grunt.GoldMin = 1;
Grunt.GoldMax = 3;
GruntBerserker.ImageOffset = new Point(-3, -8);
GruntBerserker.Name = "Beserker Grunt";
GruntBerserker.BaseHitPoints = 60;
GruntBerserker.BaseArmour = 0;
GruntBerserker.IncreaseHitPoints = 15;
GruntBerserker.IncreaseArmour = 0.5;
GruntBerserker.Speed = 1.5;
GruntBerserker.GoldMin = 1;
GruntBerserker.GoldMax = 3;
GruntScout.ImageOffset = new Point(-3, -8);
GruntScout.Name = "Grunt Scout";
GruntScout.BaseHitPoints = 65;
GruntScout.BaseArmour = 0;
GruntScout.IncreaseHitPoints = 16;
GruntScout.IncreaseArmour = 0.55;
GruntScout.Speed = 1.6;
GruntScout.GoldMin = 2;
GruntScout.GoldMax = 3;
GruntScout.Invisible = true;
Mercenary.ImageOffset = new Point(0, -6);
Mercenary.Name = "Mercanery";
Mercenary.BaseHitPoints = 45;
Mercenary.BaseArmour = 0;
Mercenary.IncreaseHitPoints = 17;
Mercenary.IncreaseArmour = 0.5;
Mercenary.Speed = 1.4;
Mercenary.GoldMin = 1;
Mercenary.GoldMax = 2;
Dwarf.ImageOffset = new Point(-8, -5);
Dwarf.Name = "Dwarf";
Dwarf.BaseHitPoints = 70;
Dwarf.BaseArmour = 0;
Dwarf.IncreaseHitPoints = 19;
Dwarf.IncreaseArmour = 0.51;
Dwarf.Speed = 2;
Dwarf.GoldMin = 1;
Dwarf.GoldMax = 4;
Sapper.ImageOffset = new Point(-8, -3);
Sapper.Name = "Goblin Sapper";
Sapper.BaseHitPoints = 80;
Sapper.BaseArmour = 0;
Sapper.IncreaseHitPoints = 20;
Sapper.IncreaseArmour = 0.52;
Sapper.Speed = 1.5;
Sapper.GoldMin = 1;
Sapper.GoldMax = 4;
OgreInfected.ImageOffset = new Point(-7, -9);
OgreInfected.Name = "Infected Ogre";
OgreInfected.BaseHitPoints = 90;
OgreInfected.BaseArmour = 0;
OgreInfected.IncreaseHitPoints = 20;
OgreInfected.IncreaseArmour = 0.53;
OgreInfected.Speed = 1.9;
OgreInfected.GoldMin = 2;
OgreInfected.GoldMax = 5;
OgreSpirit.ImageOffset = new Point(-7, -9);
OgreSpirit.Name = "Ogre Spirit";
OgreSpirit.BaseHitPoints = 95;
OgreSpirit.BaseArmour = 0;
OgreSpirit.IncreaseHitPoints = 20.5;
OgreSpirit.IncreaseArmour = 0.54;
OgreSpirit.Speed = 1.7;
OgreSpirit.GoldMin = 2;
OgreSpirit.GoldMax = 5;
OgreSpirit.Invisible = true;
Knight.ImageOffset = new Point(-12, -12);
Knight.Name = "Knight";
Knight.BaseHitPoints = 100;
Knight.BaseArmour = 0;
Knight.IncreaseHitPoints = 21;
Knight.IncreaseArmour = 0.55;
Knight.Speed = 1.4;
Knight.GoldMin = 2;
Knight.GoldMax = 5;
KnightBlack.ImageOffset = new Point(-12, -12);
KnightBlack.Name = "Black Knight";
KnightBlack.BaseHitPoints = 105;
KnightBlack.BaseArmour = 0;
KnightBlack.IncreaseHitPoints = 22;
KnightBlack.IncreaseArmour = 0.56;
KnightBlack.Speed = 1.3;
KnightBlack.GoldMin = 2;
KnightBlack.GoldMax = 6;
DeathKnight.ImageOffset = new Point(-12, -12);
DeathKnight.Name = "Death Knight";
DeathKnight.BaseHitPoints = 110;
DeathKnight.BaseArmour = 0;
DeathKnight.IncreaseHitPoints = 30.2;
DeathKnight.IncreaseArmour = 0.57;
DeathKnight.Speed = 1.2;
DeathKnight.GoldMin = 2;
DeathKnight.GoldMax = 6;
DeathKnight.ImmuneAgainst = ImmuneTypes.Ice;
Demon.ImageOffset = new Point(-10, -8);
Demon.Name = "Demon";
Demon.BaseHitPoints = 115;
Demon.BaseArmour = 0;
Demon.IncreaseHitPoints = 30.3;
Demon.IncreaseArmour = 1.05;
Demon.Speed = 1.1;
Demon.GoldMin = 3;
Demon.GoldMax = 6;
Demon.ImmuneAgainst = ImmuneTypes.Fire;
MercenaryVeteran.ImageOffset = new Point(0, -6);
MercenaryVeteran.Name = "Mercenary Boss";
MercenaryVeteran.BaseHitPoints = 1800;
MercenaryVeteran.BaseArmour = 4;
MercenaryVeteran.IncreaseHitPoints = 0;
MercenaryVeteran.IncreaseArmour = 0;
MercenaryVeteran.Speed = 1.6;
MercenaryVeteran.GoldMin = 10;
MercenaryVeteran.GoldMax = 20;
DwarfStone.ImageOffset = new Point(-8, -5);
DwarfStone.Name = "Dwarf Boss";
DwarfStone.BaseHitPoints = 2000;
DwarfStone.BaseArmour = 5;
DwarfStone.IncreaseHitPoints = 0;
DwarfStone.IncreaseArmour = 0;
DwarfStone.Speed = 1.8;
DwarfStone.GoldMin = 15;
DwarfStone.GoldMax = 25;
Ogre.ImageOffset = new Point(-7, -9);
Ogre.Name = "Ogre";
Ogre.BaseHitPoints = 2200;
Ogre.BaseArmour = 6;
Ogre.IncreaseHitPoints = 0;
Ogre.IncreaseArmour = 0;
Ogre.Speed = 1.9;
Ogre.GoldMin = 20;
Ogre.GoldMax = 25;
Knight2.ImageOffset = new Point(-12, -12);
Knight2.Name = "Knight";
Knight2.BaseHitPoints = 2400;
Knight2.BaseArmour = 7;
Knight2.IncreaseHitPoints = 0;
Knight2.IncreaseArmour = 0;
Knight2.Speed = 1.4;
Knight2.GoldMin = 25;
Knight2.GoldMax = 30;
}
}//package TowerDefence.Monsters
Section 230
//RevealEffect (TowerDefence.Monsters.RevealEffect)
package TowerDefence.Monsters {
import TowerDefence.*;
import TowerDefence.Towers.*;
public class RevealEffect {
public var Tower:Tower;
private static var CurrentEffect:RevealEffect;
private static var Pool:Array = new Array();
private static var TowerDistance:Number;
private static function GetInstance():RevealEffect{
if (Pool.length > 0){
return (Pool.pop());
};
return (new (RevealEffect));
}
public static function Create(_arg1:Tower):RevealEffect{
var _local2:RevealEffect;
_local2 = GetInstance();
_local2.Tower = _arg1;
return (_local2);
}
public static function Tick(_arg1:Array, _arg2:Monster):void{
var _local3:int;
_local3 = (_arg1.length - 1);
while (_local3 > -1) {
CurrentEffect = _arg1[_local3];
TowerDistance = SimplePoint.Distance(CurrentEffect.Tower.Center, _arg2.Center);
if (TowerDistance > (CurrentEffect.Tower.CurrentLevel.Range + Game.RangeBonus)){
_arg1.splice(_local3, 1);
Pool.push(CurrentEffect);
};
_local3--;
};
}
}
}//package TowerDefence.Monsters
Section 231
//Credits (TowerDefence.Screens.Credits)
package TowerDefence.Screens {
import TowerDefence.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.net.*;
public class Credits extends MovieClip {
private var CloseButton:MenuButton;
public var TextBlock:TextField;
public var MaxGamesButton:SimpleButton;
public function Credits(){
this.TextBlock.htmlText = Game.Language.CreditsText;
this.CloseButton = new MenuButton(Game.Language.Close, 231, 442);
this.CloseButton.addEventListener(MouseEvent.CLICK, this.Close);
this.addChild(this.CloseButton);
this.MaxGamesButton.addEventListener(MouseEvent.CLICK, MaxGames);
Game.STAGE.addChild(this);
}
private function Close(_arg1:Object){
Game.STAGE.removeChild(this);
}
private static function MaxGames(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.maxgames.com/"), "_blank");
}
}
}//package TowerDefence.Screens
Section 232
//GameLose (TowerDefence.Screens.GameLose)
package TowerDefence.Screens {
import TowerDefence.*;
import flash.display.*;
import flash.media.*;
import flash.events.*;
import flash.text.*;
import Assets.*;
import flash.net.*;
public class GameLose extends MovieClip {
public var Background:MovieClip;
public var TextBlockBack:TextField;
public var DefeatLabel:TextField;
public var MaxGamesButton:SimpleButton;
public var TextBlockFront:TextField;
private static var Defeat:Sound;
public function GameLose(){
this.Background.buttonMode = true;
this.Background.mouseChildren = false;
this.Background.useHandCursor = true;
this.Background.addEventListener(MouseEvent.CLICK, this.Start);
this.DefeatLabel.text = Game.Language.Defeat;
this.TextBlockFront.htmlText = Game.Language.DefeatText;
this.TextBlockBack.htmlText = Game.Language.DefeatText;
this.MaxGamesButton.addEventListener(MouseEvent.CLICK, MaxGames);
Game.STAGE.addChild(this);
SoundManager.PlaySound(Defeat);
}
public function Start(_arg1:MouseEvent):void{
Game.STAGE.removeChild(this);
new GameStart();
new HighScores();
}
public static function Init():void{
Defeat = new Defeat();
}
private static function MaxGames(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.maxgames.com/"), "_blank");
}
}
}//package TowerDefence.Screens
Section 233
//GameMenu (TowerDefence.Screens.GameMenu)
package TowerDefence.Screens {
import TowerDefence.*;
import flash.display.*;
import flash.events.*;
import TowerDefence.Interface.*;
import flash.text.*;
import flash.net.*;
public class GameMenu extends MovieClip {
private var RestartButton:MenuButton;
public var PB1Hard:TextField;
public var PB5Hard:TextField;
public var PB3Easy:TextField;
public var PB7Easy:TextField;
private var SpeedButton:MenuButton;
public var MediumLabel:TextField;
public var PB1:TextField;
public var PB2:TextField;
public var PB5:TextField;
public var PB6:TextField;
public var PB8:TextField;
public var PB7:TextField;
public var PB3:TextField;
public var PB4:TextField;
public var PB4Hard:TextField;
public var PB8Hard:TextField;
public var PB6Easy:TextField;
public var HardLabel:TextField;
public var PB2Easy:TextField;
private var SoundButton:MenuButton;
public var PB7Hard:TextField;
public var PB3Hard:TextField;
public var PB5Easy:TextField;
public var PB1Easy:TextField;
private var ResetButton:MenuButton;
public var MaxGamesButton:SimpleButton;
public var PB2Hard:TextField;
public var PB6Hard:TextField;
private var MusicButton:MenuButton;
public var PB4Easy:TextField;
public var MyPersonalBestsFront:TextField;
public var PB8Easy:TextField;
private var PlayButton:MenuButton;
public var MyPersonalBestsBack:TextField;
public var LevelLabel:TextField;
public var EasyLabel:TextField;
private var HelpButton:MenuButton;
public function GameMenu(){
var _local1:Array;
var _local2:int;
super();
Game.Pause = true;
Game.Locked = true;
Game.STAGE.addChild(this);
this.EasyLabel.text = Game.Language.Easy;
this.MediumLabel.text = Game.Language.Medium;
this.HardLabel.text = Game.Language.Hard;
this.LevelLabel.text = Game.Language.Level;
this.MyPersonalBestsFront.text = Game.Language.MyPersonalBests;
this.MyPersonalBestsBack.text = Game.Language.MyPersonalBests;
this.SoundButton = new MenuButton((Game.SoundOn) ? Game.Language.TurnSoundOff : Game.Language.TurnSoundOn, 70, 110);
this.SoundButton.addEventListener(MouseEvent.CLICK, ToggleSound);
this.addChild(this.SoundButton);
this.MusicButton = new MenuButton((Game.MusicOn) ? Game.Language.TurnMusicOff : Game.Language.TurnMusicOn, 70, 140);
this.MusicButton.addEventListener(MouseEvent.CLICK, ToggleMusic);
this.addChild(this.MusicButton);
this.SpeedButton = new MenuButton((Game.LowGraphicsMode) ? Game.Language.FastSpeed : Game.Language.NormalSpeed, 70, 170);
this.SpeedButton.addEventListener(MouseEvent.CLICK, ToggleSpeed);
this.addChild(this.SpeedButton);
this.HelpButton = new MenuButton(Game.Language.Help, 70, 200);
this.HelpButton.addEventListener(MouseEvent.CLICK, Help);
this.addChild(this.HelpButton);
this.PlayButton = new MenuButton(Game.Language.ReturnToGame, 70, 230);
this.PlayButton.addEventListener(MouseEvent.CLICK, this.Close);
this.addChild(this.PlayButton);
this.ResetButton = new MenuButton(Game.Language.ResetPersonalBests, 70, 300);
this.ResetButton.addEventListener(MouseEvent.CLICK, this.ResetPersonalBests);
this.addChild(this.ResetButton);
this.RestartButton = new MenuButton(Game.Language.Quit, 70, 330);
this.RestartButton.addEventListener(MouseEvent.CLICK, this.Restart);
this.addChild(this.RestartButton);
this.MaxGamesButton.addEventListener(MouseEvent.CLICK, MaxGames);
_local1 = new Array(3);
_local2 = 1;
while (_local2 < 9) {
_local1 = Cookie.GetPersonalBest(_local2);
this[(("PB" + _local2) + "Easy")].text = _local1[0];
this[("PB" + _local2)].text = _local1[1];
this[(("PB" + _local2) + "Hard")].text = _local1[2];
_local2++;
};
}
private function ResetPersonalBests(_arg1:MouseEvent):void{
var _local2:int;
_local2 = 1;
while (_local2 < 9) {
Cookie.DeletePersonalBest(_local2);
this[(("PB" + _local2) + "Easy")].text = "--";
this[("PB" + _local2)].text = "--";
this[(("PB" + _local2) + "Hard")].text = "--";
_local2++;
};
}
private function Close(_arg1:MouseEvent):void{
Game.Pause = false;
Game.Locked = false;
Game.STAGE.removeChild(this);
}
private function Restart(_arg1:MouseEvent):void{
Game.STAGE.removeChild(this);
new GameStart();
}
private static function Help(_arg1:MouseEvent):void{
new Help();
}
private static function ToggleMusic(_arg1:MouseEvent){
var _local2:MenuButton;
Game.MusicOn = !(Game.MusicOn);
_local2 = (_arg1.target as MenuButton);
_local2.Text.text = (Game.MusicOn) ? Game.Language.TurnMusicOff : Game.Language.TurnMusicOn;
if (Game.MusicOn){
SoundManager.StartMusic();
} else {
SoundManager.StopMusic();
};
}
private static function ToggleSpeed(_arg1:MouseEvent):void{
var _local2:MenuButton;
Game.LowGraphicsMode = !(Game.LowGraphicsMode);
if (Game.LowGraphicsMode){
Game.STAGE.frameRate = (Game.BaseFrameRate * 2);
MiniMap.BaseRefreshCounter = 30;
} else {
Game.STAGE.frameRate = Game.BaseFrameRate;
MiniMap.BaseRefreshCounter = 15;
};
_local2 = (_arg1.target as MenuButton);
_local2.Text.text = (Game.LowGraphicsMode) ? Game.Language.FastSpeed : Game.Language.NormalSpeed;
}
private static function MaxGames(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.maxgames.com/"), "_blank");
}
private static function ToggleSound(_arg1:MouseEvent){
var _local2:MenuButton;
Game.SoundOn = !(Game.SoundOn);
_local2 = (_arg1.target as MenuButton);
_local2.Text.text = (Game.SoundOn) ? Game.Language.TurnSoundOff : Game.Language.TurnSoundOn;
}
}
}//package TowerDefence.Screens
Section 234
//GameStart (TowerDefence.Screens.GameStart)
package TowerDefence.Screens {
import TowerDefence.*;
import flash.display.*;
import TowerDefence.Monsters.*;
import flash.events.*;
import TowerDefence.Languages.*;
import SWFStats.*;
import flash.text.*;
import flash.net.*;
public class GameStart extends MovieClip {
private var HelpButton:MenuButton;
public var PlayerName:TextField;
private var MediumButton:MenuButton;
private var HardButton:MenuButton;
private var EasyButton:MenuButton;
private var CreditsButton:MenuButton;
public var TextBlockBack:TextField;
private var MaxGamesButton:MenuButton2;
private var HighScoreButton:MenuButton;
public var MaxGamesLogoButton:SimpleButton;
public var TextBlockFront:TextField;
private var LanguageButton:MenuButton;
public function GameStart(){
this.TextBlockFront.htmlText = Game.Language.GameStartText;
this.TextBlockBack.htmlText = Game.Language.GameStartText;
this.EasyButton = new MenuButton(Game.Language.Easy, 70, 110);
this.EasyButton.addEventListener(MouseEvent.CLICK, this.SetEasyMode);
this.addChild(this.EasyButton);
this.MediumButton = new MenuButton(Game.Language.Medium, 70, 140);
this.MediumButton.addEventListener(MouseEvent.CLICK, this.SetNormalMode);
this.addChild(this.MediumButton);
this.HardButton = new MenuButton(Game.Language.Hard, 70, 170);
this.HardButton.addEventListener(MouseEvent.CLICK, this.SetHardMode);
this.addChild(this.HardButton);
this.HighScoreButton = new MenuButton(Game.Language.HighScores, 70, 240);
this.HighScoreButton.addEventListener(MouseEvent.CLICK, HighScores);
this.addChild(this.HighScoreButton);
this.HelpButton = new MenuButton(Game.Language.Help, 70, 270);
this.HelpButton.addEventListener(MouseEvent.CLICK, Help);
this.addChild(this.HelpButton);
this.CreditsButton = new MenuButton(Game.Language.Credits, 70, 300);
this.CreditsButton.addEventListener(MouseEvent.CLICK, Credits);
this.addChild(this.CreditsButton);
if (Game.Language == Language.English){
this.LanguageButton = new MenuButton("Espanol", 70, 330);
} else {
this.LanguageButton = new MenuButton("English", 70, 330);
};
this.LanguageButton.addEventListener(MouseEvent.CLICK, SetLanguage);
this.addChild(this.LanguageButton);
this.MaxGamesButton = new MenuButton2(Game.Language.PlayMoreGames, 70, 380);
this.MaxGamesButton.addEventListener(MouseEvent.CLICK, MaxGames);
this.addChild(this.MaxGamesButton);
this.MaxGamesLogoButton.addEventListener(MouseEvent.CLICK, MaxGames);
PlayerName.text = Game.PlayerName;
Game.STAGE.addChild(this);
SoundManager.StartMusic();
}
private function SetNormalMode(_arg1:MouseEvent):void{
CustomMetrics.Log(CustomMetrics.MEDIUM);
Game.Difficulty = 1;
Monster.HealthAdjuster = 1;
Monster.ArmourAdjuster = 1;
Monster.GoldAdjuster = 1;
this.Start();
}
private function SetEasyMode(_arg1:MouseEvent):void{
CustomMetrics.Log(CustomMetrics.EASY);
Game.Difficulty = 0;
Monster.HealthAdjuster = 0.7;
Monster.ArmourAdjuster = 0.6;
Monster.GoldAdjuster = 1.5;
this.Start();
}
private function SetHardMode(_arg1:MouseEvent):void{
CustomMetrics.Log(CustomMetrics.HARD);
Game.Difficulty = 2;
Monster.HealthAdjuster = 1.2;
Monster.ArmourAdjuster = 1.2;
Monster.GoldAdjuster = 0.8;
this.Start();
}
private function Start():void{
Game.PlayerName = PlayerName.text;
if (Game.Language == Language.English){
CustomMetrics.Log(CustomMetrics.ENGLISH);
} else {
CustomMetrics.Log(CustomMetrics.SPANISH);
};
Tracker.LogPlay();
Statistics.Reset();
Game.STAGE.removeChild(this);
new Intermission();
}
private function SetLanguage(_arg1:MouseEvent):void{
if (Game.Language == Language.English){
Game.Language = Language.Spanish;
} else {
Game.Language = Language.English;
};
Game.STAGE.removeChild(this);
new GameStart();
}
private static function Help(_arg1:MouseEvent):void{
new Help();
}
private static function HighScores(_arg1:MouseEvent):void{
new HighScores();
}
private static function Credits(_arg1:MouseEvent):void{
new Credits();
}
private static function MaxGames(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.maxgames.com/"), "_blank");
}
}
}//package TowerDefence.Screens
Section 235
//GameWin (TowerDefence.Screens.GameWin)
package TowerDefence.Screens {
import TowerDefence.*;
import flash.display.*;
import flash.media.*;
import flash.events.*;
import flash.text.*;
import Assets.*;
import flash.net.*;
public class GameWin extends MovieClip {
public var VictoryLabel:TextField;
public var Background:MovieClip;
public var TextBlockBack:TextField;
public var MaxGamesButton:SimpleButton;
public var TextBlockFront:TextField;
private static var Victory:Sound;
public function GameWin(){
this.Background.buttonMode = true;
this.Background.mouseChildren = false;
this.Background.useHandCursor = true;
this.Background.addEventListener(MouseEvent.CLICK, this.Start);
this.VictoryLabel.text = Game.Language.Victory;
this.TextBlockFront.htmlText = Game.Language.VictoryText;
this.TextBlockBack.htmlText = Game.Language.VictoryText;
this.MaxGamesButton.addEventListener(MouseEvent.CLICK, MaxGames);
Game.STAGE.addChild(this);
SoundManager.PlaySound(Victory);
}
public function Start(_arg1:MouseEvent):void{
Game.STAGE.removeChild(this);
new GameStart();
new HighScores();
}
public static function Init():void{
Victory = new Victory();
}
private static function MaxGames(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.maxgames.com/"), "_blank");
}
}
}//package TowerDefence.Screens
Section 236
//Help (TowerDefence.Screens.Help)
package TowerDefence.Screens {
import TowerDefence.*;
import flash.display.*;
import flash.events.*;
import flash.text.*;
import flash.net.*;
public class Help extends MovieClip {
private var CloseButton:MenuButton;
public var TextBlock:TextField;
public var MaxGamesButton:SimpleButton;
public function Help(){
this.TextBlock.htmlText = Game.Language.HelpText;
this.CloseButton = new MenuButton(Game.Language.Close, 231, 442);
this.CloseButton.addEventListener(MouseEvent.CLICK, this.Close);
this.addChild(this.CloseButton);
this.MaxGamesButton.addEventListener(MouseEvent.CLICK, MaxGames);
Game.STAGE.addChild(this);
}
private function Close(_arg1:Object){
Game.STAGE.removeChild(this);
}
private static function MaxGames(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.maxgames.com/"), "_blank");
}
}
}//package TowerDefence.Screens
Section 237
//HighScores (TowerDefence.Screens.HighScores)
package TowerDefence.Screens {
import TowerDefence.*;
import flash.display.*;
import flash.events.*;
import SWFStats.*;
import mochi.as3.*;
import flash.text.*;
import flash.utils.*;
import flash.net.*;
import flash.system.*;
public class HighScores extends MovieClip {
public var Score2:TextField;
public var Score3:TextField;
public var Username0:TextField;
public var Username2:TextField;
public var Username4:TextField;
public var Username5:TextField;
public var Score5:TextField;
public var Score1:TextField;
public var HighScoresLabel:TextField;
public var Score4:TextField;
public var KillsLabel:TextField;
public var Score0:TextField;
private var CloseButton:MenuButton;
public var MaxGamesButton:SimpleButton;
public var Username1:TextField;
private var DataLoader:URLLoader;
public var UsernameLabel:TextField;
public var Username3:TextField;
public function HighScores(){
this.HighScoresLabel.text = Game.Language.HighScores;
this.UsernameLabel.text = Game.Language.Username;
this.KillsLabel.text = Game.Language.Kills;
this.CloseButton = new MenuButton(Game.Language.Close, 231, 442);
this.CloseButton.addEventListener(MouseEvent.CLICK, this.Close);
this.addChild(this.CloseButton);
this.MaxGamesButton.addEventListener(MouseEvent.CLICK, MaxGames);
Game.STAGE.addChild(this);
this.LoadSWFStatsScores();
}
private function Close(_arg1:Event=null){
Game.STAGE.removeChild(this);
}
private function LoadKongregateScores():void{
if (Game.Kongregate != null){
try {
Game.Kongregate.scores.requestList(this.DisplayScores);
} catch(s:Error) {
setTimeout(this.LoadScores, 1000);
};
};
}
private function DisplayScores(_arg1:Object):void{
var i:int;
var result = _arg1;
i = 0;
while (i < result.list.length) {
if (i > 5){
return;
};
try {
this[("Username" + i)].text = result.list[i].username;
this[("Score" + i)].text = result.list[i].score;
} catch(s:Error) {
};
i = (i + 1);
};
}
private function LoadSWFStatsScores():void{
Security.loadPolicyFile("http://ping.swfstats.com/crossdomain.xml");
HighScores.List(true, 2, this.ShowScores);
}
private function LoadMochiScores():void{
var o:Object;
var boardID:String;
o = {n:[0, 14, 4, 14, 7, 2, 6, 8, 5, 6, 13, 5, 12, 8, 5, 9], f:function (_arg1:Number, _arg2:String):String{
if (_arg2.length == 16){
return (_arg2);
};
return (this.f((_arg1 + 1), (_arg2 + this.n[_arg1].toString(16))));
}};
boardID = o.f(0, "");
if (Statistics.Points == 0){
MochiScores.showLeaderboard({boardID:"0e4e726856d5c859", clip:this, onClose:this.Close});
} else {
MochiScores.showLeaderboard({boardID:"0e4e726856d5c859", score:Statistics.Points, clip:this, onClose:this.Close});
Statistics.Reset();
};
}
private function ShowScores(_arg1:Array):void{
var _local2:int;
var _local3:int;
_local2 = 0;
_local3 = 0;
while (_local3 < _arg1.length) {
if (_local3 > 5){
return;
};
this[("Username" + _local3)].text = _arg1[_local3].Name;
this[("Score" + _local3)].text = _arg1[_local3].Points;
if (_local2 > 5){
return;
};
_local3++;
};
}
private static function ErrorHandler(_arg1:IOErrorEvent):void{
}
private static function MaxGames(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.maxgames.com/"), "_blank");
}
}
}//package TowerDefence.Screens
Section 238
//Intermission (TowerDefence.Screens.Intermission)
package TowerDefence.Screens {
import TowerDefence.*;
import flash.display.*;
import flash.events.*;
import flash.net.*;
public class Intermission extends MovieClip {
private var Level0:LevelButton;
private var Level4:LevelButton;
private var Level8:LevelButton;
private var Level2:LevelButton;
private var Level5:LevelButton;
private var Level6:LevelButton;
private var Level7:LevelButton;
private var Level3:LevelButton;
public var MaxGamesButton:SimpleButton;
private var Level1:LevelButton;
public function Intermission(){
var _local1:int;
super();
Game.Locked = true;
_local1 = Cookie.GetSavedLevelNumber();
this.Level0 = new LevelButton(0, 0, 418, 337);
this.addChild(this.Level0);
this.Level1 = new LevelButton(_local1, 1, 516, 249);
this.addChild(this.Level1);
this.Level2 = new LevelButton(_local1, 2, 335, 203);
this.addChild(this.Level2);
this.Level3 = new LevelButton(_local1, 3, 395, 74);
this.addChild(this.Level3);
this.Level4 = new LevelButton(_local1, 4, 172, 187);
this.addChild(this.Level4);
this.Level5 = new LevelButton(_local1, 5, 128, 277);
this.addChild(this.Level5);
this.Level6 = new LevelButton(_local1, 6, 46, 260);
this.addChild(this.Level6);
this.Level7 = new LevelButton(_local1, 7, 220, 117);
this.addChild(this.Level7);
this.Level8 = new LevelButton(_local1, 8, 100, 78);
this.addChild(this.Level8);
Game.STAGE.addChild(this);
this.MaxGamesButton.addEventListener(MouseEvent.CLICK, MaxGames);
}
private static function MaxGames(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.maxgames.com/"), "_blank");
}
}
}//package TowerDefence.Screens
Section 239
//LanguageSelection (TowerDefence.Screens.LanguageSelection)
package TowerDefence.Screens {
import flash.display.*;
public dynamic class LanguageSelection extends MovieClip {
}
}//package TowerDefence.Screens
Section 240
//LevelButton (TowerDefence.Screens.LevelButton)
package TowerDefence.Screens {
import TowerDefence.*;
import flash.display.*;
import TowerDefence.Levels.*;
import flash.geom.*;
import flash.events.*;
import Assets.WorldMap.*;
public class LevelButton extends MovieClip {
public var Image:Bitmap;
private var Level:int;
private static const Available:Rectangle = new Rectangle(0, 0, 30, 39);
private static const Disabled:Rectangle = new Rectangle(60, 0, 30, 39);
private static const Beaten:Rectangle = new Rectangle(30, 0, 30, 39);
private static var Shields:BitmapData;
public function LevelButton(_arg1:int=0, _arg2:int=0, _arg3:int=0, _arg4:int=0){
this.x = _arg3;
this.y = _arg4;
this.Level = _arg2;
this.Image = new Bitmap(Shields);
this.Image.scrollRect = GetRectangle(_arg1, _arg2);
this.addChild(this.Image);
if ((((this.Level > 0)) && ((this.Image.scrollRect.x < 60)))){
this.buttonMode = true;
this.mouseChildren = false;
this.useHandCursor = true;
this.addEventListener(MouseEvent.CLICK, Start);
};
}
public static function Init():void{
Shields = new Shields(90, 39);
}
private static function GetRectangle(_arg1:int, _arg2:int):Rectangle{
if (_arg1 == 0){
return (Beaten);
};
if (_arg1 > _arg2){
return (Beaten);
};
if (_arg1 == _arg2){
return (Available);
};
return (Disabled);
}
private static function Start(_arg1:MouseEvent):void{
var _local2:LevelButton;
_local2 = (_arg1.target as LevelButton);
Game.Levels[0] = Level1.Generate;
Game.Levels[1] = Level2.Generate;
Game.Levels[2] = Level3.Generate;
Game.Levels[3] = Level4.Generate;
Game.Levels[4] = Level5.Generate;
Game.Levels[5] = Level6.Generate;
Game.Levels[6] = Level7.Generate;
Game.Levels[7] = Level8.Generate;
Game.STAGE.removeChild(_local2.parent);
Game.LevelNumber = _local2.Level;
Game.Locked = false;
Game.StartLevel();
}
}
}//package TowerDefence.Screens
Section 241
//MaxGames (TowerDefence.Screens.MaxGames)
package TowerDefence.Screens {
import TowerDefence.*;
import flash.display.*;
import TowerDefence.Monsters.*;
import flash.events.*;
import InFlashStudios.*;
import flash.net.*;
public class MaxGames extends MovieClip {
public var Animation:MovieClip;
private var Container:MovieClip;
private static const Monsters:Array = new Array(9);
public function MaxGames(){
this.buttonMode = true;
this.mouseChildren = false;
this.useHandCursor = true;
this.addEventListener(Event.ENTER_FRAME, this.Tick);
this.addEventListener(MouseEvent.CLICK, GoToMaxGames);
this.Animation.gotoAndPlay(1);
this.Container = new MovieClip();
this.addChild(this.Container);
Game.STAGE.addChild(this);
}
private function Tick(_arg1:Event):void{
var e = _arg1;
if ((((((this.Animation.currentFrame >= 60)) && ((this.alpha == 1)))) && (((this.Animation.currentFrame % 10) == 0)))){
Maths.GenerateRandom();
this.Container.addChild(new DumbMonster(Monsters[Maths.Random(0, 8)]));
};
if (this.Animation.currentFrame == 240){
if (this.alpha == 1){
this.Animation.stop();
new GameStart();
new Splash(Game.STAGE, function (){
});
Game.STAGE.setChildIndex(this, (Game.STAGE.numChildren - 1));
};
if (this.alpha > 0){
this.alpha = (this.alpha - 0.01);
return;
};
this.removeEventListener(Event.ENTER_FRAME, this.Tick);
Game.STAGE.removeChild(this);
};
}
private static function GoToMaxGames(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.maxgames.com/"), "_blank");
}
Monsters[0] = MonsterConfig.Peon;
Monsters[1] = MonsterConfig.Troll;
Monsters[2] = MonsterConfig.Mercenary;
Monsters[3] = MonsterConfig.Grunt;
Monsters[4] = MonsterConfig.Dwarf;
Monsters[5] = MonsterConfig.Sapper;
Monsters[6] = MonsterConfig.Ogre;
Monsters[7] = MonsterConfig.Knight;
Monsters[8] = MonsterConfig.DeathKnight;
}
}//package TowerDefence.Screens
Section 242
//MenuButton (TowerDefence.Screens.MenuButton)
package TowerDefence.Screens {
import flash.display.*;
import flash.geom.*;
import flash.events.*;
import flash.text.*;
import Assets.Interface.*;
public class MenuButton extends MovieClip {
private var Image:Bitmap;
public var Text:TextField;
private static const LabelFormat:TextFormat = new TextFormat();
private static const DisabledFormat:TextFormat = new TextFormat();
private static const UpRectangle:Rectangle = new Rectangle(0, 0, 142, 28);
private static const DisabledRectangle:Rectangle = new Rectangle(0, 56, 142, 28);
private static const OverRectangle:Rectangle = new Rectangle(0, 28, 142, 28);
private static var Background:BitmapData;
public function MenuButton(_arg1:String="", _arg2:int=0, _arg3:int=0){
this.Image = new Bitmap(Background);
this.Image.scrollRect = UpRectangle;
this.addChild(this.Image);
this.Text = new TextField();
this.Text.defaultTextFormat = LabelFormat;
this.Text.text = _arg1;
this.Text.width = 134;
this.Text.selectable = false;
this.Text.multiline = false;
this.Text.x = 4;
this.Text.y = 4;
this.addChild(this.Text);
this.scrollRect = UpRectangle;
this.x = _arg2;
this.y = _arg3;
this.buttonMode = true;
this.mouseChildren = false;
this.useHandCursor = true;
this.addEventListener(MouseEvent.MOUSE_OVER, Over);
this.addEventListener(MouseEvent.MOUSE_OUT, Out);
}
private static function Over(_arg1:MouseEvent):void{
var _local2:MenuButton;
_local2 = (_arg1.target as MenuButton);
_local2.Image.scrollRect = OverRectangle;
}
public static function Init():void{
Background = new MenuButton(142, 56);
}
private static function Out(_arg1:MouseEvent):void{
var _local2:MenuButton;
_local2 = (_arg1.target as MenuButton);
_local2.Image.scrollRect = UpRectangle;
}
LabelFormat.font = "Arial";
LabelFormat.size = 11;
LabelFormat.bold = true;
LabelFormat.color = 0xFFFFFF;
LabelFormat.align = TextFormatAlign.CENTER;
DisabledFormat.font = "Arial";
DisabledFormat.size = 11;
DisabledFormat.bold = true;
DisabledFormat.color = 0x999999;
DisabledFormat.align = TextFormatAlign.CENTER;
}
}//package TowerDefence.Screens
Section 243
//MenuButton2 (TowerDefence.Screens.MenuButton2)
package TowerDefence.Screens {
import flash.display.*;
import flash.geom.*;
import flash.events.*;
import flash.text.*;
import Assets.Interface.*;
public class MenuButton2 extends MovieClip {
private var Image:Bitmap;
public var Text:TextField;
private static const LabelFormat:TextFormat = new TextFormat();
private static const DisabledFormat:TextFormat = new TextFormat();
private static const UpRectangle:Rectangle = new Rectangle(0, 0, 142, 39);
private static const DisabledRectangle:Rectangle = new Rectangle(0, 39, 142, 39);
private static const OverRectangle:Rectangle = new Rectangle(0, 39, 142, 39);
private static var Background:BitmapData;
public function MenuButton2(_arg1:String="", _arg2:int=0, _arg3:int=0){
this.Image = new Bitmap(Background);
this.Image.scrollRect = UpRectangle;
this.addChild(this.Image);
this.Text = new TextField();
this.Text.defaultTextFormat = LabelFormat;
this.Text.text = _arg1;
this.Text.width = 130;
this.Text.selectable = false;
this.Text.multiline = true;
this.Text.x = 4;
this.Text.y = 2;
this.Text.wordWrap = true;
this.addChild(this.Text);
this.scrollRect = UpRectangle;
this.x = _arg2;
this.y = _arg3;
this.buttonMode = true;
this.mouseChildren = false;
this.useHandCursor = true;
this.addEventListener(MouseEvent.MOUSE_OVER, Over);
this.addEventListener(MouseEvent.MOUSE_OUT, Out);
}
private static function Over(_arg1:MouseEvent):void{
var _local2:MenuButton2;
_local2 = (_arg1.target as MenuButton2);
_local2.Image.scrollRect = OverRectangle;
}
public static function Init():void{
Background = new MenuButtonBig(142, 78);
}
private static function Out(_arg1:MouseEvent):void{
var _local2:MenuButton2;
_local2 = (_arg1.target as MenuButton2);
_local2.Image.scrollRect = UpRectangle;
}
LabelFormat.font = "Arial";
LabelFormat.size = 11;
LabelFormat.bold = true;
LabelFormat.color = 0xFFFFFF;
LabelFormat.align = TextFormatAlign.CENTER;
DisabledFormat.font = "Arial";
DisabledFormat.size = 11;
DisabledFormat.bold = true;
DisabledFormat.color = 0x999999;
DisabledFormat.align = TextFormatAlign.CENTER;
}
}//package TowerDefence.Screens
Section 244
//DamageTypes (TowerDefence.Towers.DamageTypes)
package TowerDefence.Towers {
public class DamageTypes {
public static const Piercing:int = 0;
public static const Fire:int = 2;
public static const Poison:int = 3;
public static const Ice:int = 4;
public static const Impact:int = 1;
}
}//package TowerDefence.Towers
Section 245
//Directions (TowerDefence.Towers.Directions)
package TowerDefence.Towers {
public class Directions {
public static const North:int = 0;
public static const NorthEast:int = 4;
public static const South:int = 1;
public static const West:int = 3;
public static const SouthEast:int = 6;
public static const NorthWest:int = 5;
public static const SouthWest:int = 7;
public static const East:int = 2;
}
}//package TowerDefence.Towers
Section 246
//ImbueTypes (TowerDefence.Towers.ImbueTypes)
package TowerDefence.Towers {
public class ImbueTypes {
public static const Poison:int = 3;
public static const Price:int = 40;
public static const Ice:int = 2;
public static const Nothing:int = 0;
public static const ImbueTime:int = 300;
public static const Fire:int = 1;
}
}//package TowerDefence.Towers
Section 247
//Level (TowerDefence.Towers.Level)
package TowerDefence.Towers {
public class Level {
public var DamageMin:int;
public var Price:int;
public var UpgradeTime:int;
public var DamageMax:int;
public var FireRate:int;
public var DamageDuration:int;
public var Range:int;
public function Level(_arg1:int, _arg2:int, _arg3:int, _arg4:int, _arg5:int, _arg6:int, _arg7:int){
this.Price = _arg1;
this.DamageMin = _arg2;
this.DamageMax = _arg3;
this.DamageDuration = _arg5;
this.Range = _arg4;
this.FireRate = _arg6;
this.UpgradeTime = _arg7;
}
}
}//package TowerDefence.Towers
Section 248
//Missile (TowerDefence.Towers.Missile)
package TowerDefence.Towers {
import TowerDefence.*;
import flash.display.*;
import TowerDefence.Monsters.*;
import flash.geom.*;
public class Missile {
private var MaxSteps:int;
private var XStep:Number;
private var YStep:Number;
private var FrameIndex:int;// = 0
private var Steps:int;
private var Location:SimplePoint;
private var ExplosionLocation:SimplePoint;
private var Tower:Tower;
private var FrameTicks:int;// = 0
private var Ignore:Boolean;
private var Monster:Monster;
private var Image:BitmapData;
private var Exploding:Boolean;
private static const BulletSpeed:int = 5;
private static const RelativeLocation:Point = new Point();
private static const ExtractArea:Rectangle = new Rectangle();
private static const MissileDestination:Point = new Point();
private static const MonsterCenter:SimplePoint = new SimplePoint();
private static const ZeroPoint:Point = new Point(0, 0);
private static var MonsterImage:BitmapData;
private static var ExtractedMissile:BitmapData;
private static var CurrentMissile:Missile;
private static var MonsterBounds:SimpleRectangle = new SimpleRectangle();
private static var GridLocation:int;
private static var Distance:Number;
private static var MoveSpeed:Number;
private static var Ticks:int;
private static var Container:Array = new Array();
private static var i:int;
private static var Monster:Monster;
private static var CombinedBitmap:BitmapData;
private static var Pool:Array = new Array();
public function Missile(){
Location = new SimplePoint();
FrameTicks = 0;
FrameIndex = 0;
ExplosionLocation = new SimplePoint();
super();
}
private static function HitTestFirstPass():Boolean{
Monster = CurrentMissile.Monster;
MonsterImage = Monster.Frames[Monster.FrameIndex];
MonsterBounds.X = Monster.Location.X;
MonsterBounds.Y = Monster.Location.Y;
MonsterBounds.Width = MonsterImage.width;
MonsterBounds.Height = MonsterImage.height;
if (!SimpleRectangle.ContainsPoint(MonsterBounds, CurrentMissile.Location)){
return (false);
};
MissileDestination.x = (Monster.Location.X - CurrentMissile.Location.X);
MissileDestination.y = (Monster.Location.Y - CurrentMissile.Location.Y);
CombinedBitmap = MonsterImage.clone();
CombinedBitmap.copyPixels(CurrentMissile.Image, CurrentMissile.Image.rect, MissileDestination);
ExtractArea.width = CurrentMissile.Image.width;
ExtractArea.height = CurrentMissile.Image.height;
ExtractedMissile = new BitmapData(ExtractArea.width, ExtractArea.height);
ExtractedMissile.copyPixels(CombinedBitmap, ExtractArea, MissileDestination);
return (!((ExtractedMissile.compare(CurrentMissile.Image) == 0)));
}
public static function Create(_arg1:Monster, _arg2:Tower, _arg3:SimplePoint, _arg4:int):void{
var _local5:Missile;
_local5 = GetInstance();
_local5.Image = ((_arg2.Config.Missiles)!=null) ? _arg2.Config.Missiles[_arg4] : _arg2.Config.Missile;
_local5.Monster = _arg1;
_local5.Tower = _arg2;
_local5.Location.X = (_arg3.X - (0.5 * _local5.Image.width));
_local5.Location.Y = (_arg3.Y - (0.5 * _local5.Image.height));
_local5.XStep = 1;
_local5.YStep = 1;
_local5.Ignore = false;
_local5.Exploding = false;
_local5.FrameTicks = 0;
_local5.FrameIndex = 0;
MonsterCenter.X = _arg1.Center.X;
MonsterCenter.Y = _arg1.Center.Y;
MoveSpeed = (Monster.HasEffect(_arg1, ImbueTypes.Ice)) ? (_arg1.Config.Speed / 3) : _arg1.Config.Speed;
Distance = SimplePoint.Distance(MonsterCenter, _local5.Location);
Ticks = Math.ceil((Distance / BulletSpeed));
MissileDestination.x = MonsterCenter.X;
MissileDestination.y = MonsterCenter.Y;
switch (_arg1.Direction){
case Directions.East:
MissileDestination.x = ((MonsterCenter.X + (Ticks * MoveSpeed)) + (0.5 * _local5.Image.width));
break;
case Directions.West:
MissileDestination.x = ((MonsterCenter.X - (Ticks * MoveSpeed)) - (0.5 * _local5.Image.width));
break;
case Directions.North:
MissileDestination.y = ((MonsterCenter.Y - (Ticks * MoveSpeed)) - (0.5 * _local5.Image.height));
break;
case Directions.South:
MissileDestination.y = ((MonsterCenter.Y + (Ticks * MoveSpeed)) + (0.5 * _local5.Image.height));
break;
};
_local5.XStep = ((MissileDestination.x - _local5.Location.X) / Ticks);
_local5.YStep = ((MissileDestination.y - _local5.Location.Y) / Ticks);
_local5.Steps = 0;
_local5.MaxSteps = (Ticks + 5);
Container.push(_local5);
if (Maths.WithinVisibleArea(_local5.Location.X, _local5.Location.Y, _local5.Image.width, _local5.Image.height)){
SoundManager.PlayTowerSound(_arg2.Config.FireSound);
};
}
private static function Remove(_arg1:Missile, _arg2:int=-1):void{
_arg1.Ignore = true;
Pool.push(_arg1);
if (_arg2 == -1){
Container.splice(Container.indexOf(_arg1), 1);
} else {
Container.splice(_arg2, 1);
};
}
private static function GetInstance():Missile{
if (Pool.length > 0){
return (Pool.pop());
};
return (new (Missile));
}
private static function HitTestSecondPass():Boolean{
if (!SimpleRectangle.ContainsPoint(MonsterBounds, CurrentMissile.Location)){
return (false);
};
MissileDestination.x = (Monster.Location.X - CurrentMissile.Location.X);
MissileDestination.y = (Monster.Location.Y - CurrentMissile.Location.Y);
CombinedBitmap = MonsterImage.clone();
CombinedBitmap.copyPixels(CurrentMissile.Image, CurrentMissile.Image.rect, MissileDestination);
ExtractArea.width = CurrentMissile.Image.width;
ExtractArea.height = CurrentMissile.Image.height;
ExtractedMissile = new BitmapData(ExtractArea.width, ExtractArea.height);
ExtractedMissile.copyPixels(CombinedBitmap, ExtractArea, MissileDestination);
return (!((ExtractedMissile.compare(CurrentMissile.Image) == 0)));
}
public static function RemoveAll():void{
var _local1:int;
_local1 = (Container.length - 1);
while (_local1 > -1) {
Remove(Container[_local1], _local1);
_local1--;
};
}
public static function Tick(_arg1:BitmapData):void{
var _local2:Array;
var _local3:Array;
var _local4:Monster;
var _local5:Number;
var _local6:int;
var _local7:int;
if (Container.length == 0){
return;
};
_local3 = Monster.Container;
i = (Container.length - 1);
for (;i > -1;i--) {
CurrentMissile = Container[i];
if (CurrentMissile.Ignore){
} else {
if (CurrentMissile.Exploding){
_local2 = CurrentMissile.Tower.Config.ExplosionImages;
if (CurrentMissile.FrameTicks == 0){
if (CurrentMissile.FrameIndex == (_local2.length - 1)){
CurrentMissile.Ignore = true;
Remove(CurrentMissile, i);
continue;
} else {
CurrentMissile.FrameTicks = 2;
CurrentMissile.FrameIndex++;
};
} else {
CurrentMissile.FrameTicks--;
};
if (CurrentMissile.FrameIndex < 2){
_local7 = (_local3.length - 1);
while (_local7 > -1) {
_local4 = _local3[_local7];
if (((_local4.Dying) || (_local4.Ignore))){
} else {
_local5 = Math.abs(SimplePoint.Distance(CurrentMissile.Location, _local4.Center));
if (_local5 < 80){
_local6 = (Math.abs((80 - _local5)) / 2);
Monster.ApplyDamage(_local6, _local4, CurrentMissile.Tower, false);
};
};
_local7--;
};
};
if (Maths.WithinVisibleArea(CurrentMissile.ExplosionLocation.X, CurrentMissile.ExplosionLocation.Y, _local2[CurrentMissile.FrameIndex].width, _local2[CurrentMissile.FrameIndex].height)){
RelativeLocation.x = (CurrentMissile.ExplosionLocation.X - Game.MapRectangle.x);
RelativeLocation.y = (CurrentMissile.ExplosionLocation.Y - Game.MapRectangle.y);
GridLocation = Math.floor((CurrentMissile.Location.Y / 40));
LayeredElement.Create(_local2[CurrentMissile.FrameIndex], RelativeLocation, GridLocation);
};
continue;
} else {
if ((((((((CurrentMissile.Monster == null)) || (CurrentMissile.Monster.Ignore))) || (CurrentMissile.Monster.Dying))) || ((CurrentMissile.Steps > CurrentMissile.MaxSteps)))){
Missile.Remove(CurrentMissile, i);
continue;
} else {
if (((CurrentMissile.Monster.Ignore) || (!(Maths.WithinMap(CurrentMissile.Location.X, CurrentMissile.Location.Y, CurrentMissile.Image.width, CurrentMissile.Image.height))))){
if (CurrentMissile.Tower.Config.MissileExplodes){
CurrentMissile.Exploding = true;
CurrentMissile.FrameTicks = 2;
CurrentMissile.FrameIndex = 0;
CurrentMissile.ExplosionLocation.X = ((CurrentMissile.Location.X + (CurrentMissile.Image.width / 2)) - 64);
CurrentMissile.ExplosionLocation.Y = ((CurrentMissile.Location.Y + (CurrentMissile.Image.height / 2)) - 64);
} else {
Missile.Remove(CurrentMissile, i);
};
continue;
};
};
};
if (HitTestFirstPass()){
Monster.Hit(CurrentMissile.Monster, CurrentMissile.Tower);
if (CurrentMissile.Tower.Config.MissileExplodes){
CurrentMissile.Exploding = true;
CurrentMissile.FrameTicks = 2;
CurrentMissile.FrameIndex = 0;
CurrentMissile.ExplosionLocation.X = ((CurrentMissile.Location.X + (CurrentMissile.Image.width / 2)) - 64);
CurrentMissile.ExplosionLocation.Y = ((CurrentMissile.Location.Y + (CurrentMissile.Image.height / 2)) - 64);
} else {
Missile.Remove(CurrentMissile, i);
};
} else {
CurrentMissile.Location.X = (CurrentMissile.Location.X + CurrentMissile.XStep);
CurrentMissile.Location.Y = (CurrentMissile.Location.Y + CurrentMissile.YStep);
CurrentMissile.Steps++;
if (HitTestSecondPass()){
Monster.Hit(CurrentMissile.Monster, CurrentMissile.Tower);
if (CurrentMissile.Tower.Config.MissileExplodes){
CurrentMissile.Exploding = true;
CurrentMissile.FrameTicks = 2;
CurrentMissile.FrameIndex = 0;
CurrentMissile.ExplosionLocation.X = ((CurrentMissile.Location.X + (CurrentMissile.Image.width / 2)) - 64);
CurrentMissile.ExplosionLocation.Y = ((CurrentMissile.Location.Y + (CurrentMissile.Image.height / 2)) - 64);
} else {
Missile.Remove(CurrentMissile, i);
};
} else {
RelativeLocation.x = (CurrentMissile.Location.X - Game.MapRectangle.x);
RelativeLocation.y = (CurrentMissile.Location.Y - Game.MapRectangle.y);
if (!Maths.WithinVisibleArea(CurrentMissile.Location.X, CurrentMissile.Location.Y, CurrentMissile.Image.width, CurrentMissile.Image.height)){
} else {
LayeredElement.Create(CurrentMissile.Image, RelativeLocation, (RelativeLocation.y / 40));
};
};
};
};
};
}
}
}//package TowerDefence.Towers
Section 249
//RadiusImage (TowerDefence.Towers.RadiusImage)
package TowerDefence.Towers {
import flash.display.*;
import flash.geom.*;
import Assets.Towers.*;
import flash.filters.*;
public class RadiusImage {
public var Width:int;
public var Image:BitmapData;
private static const Cache:Array = new Array();
private static const ZeroPoint:Point = new Point(0, 0);
private static const Opacity:ColorMatrixFilter = new ColorMatrixFilter([1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0.25, 0]);
public static function Create(_arg1:int):BitmapData{
var _local2:int;
var _local3:Shape;
var _local4:BitmapData;
var _local5:*;
var _local6:RadiusImage;
_local2 = 0;
while (_local2 < Cache.length) {
if (Cache[_local2].Width == _arg1){
return (Cache[_local2].Image);
};
_local2++;
};
_local3 = new Shape();
_local3.graphics.lineStyle(0.1, 0xFFFFFF);
_local3.graphics.moveTo(0, 0);
_local3.graphics.drawCircle(_arg1, _arg1, _arg1);
_local3.graphics.endFill();
_local4 = new BitmapData(((2 * _arg1) + 1), ((2 * _arg1) + 1), true, 0xFFFFFF);
_local4.draw(_local3);
_local4.applyFilter(_local4, _local4.rect, ZeroPoint, Opacity);
_local6 = new (RadiusImage);
_local6.Width = _arg1;
_local6.Image = _local4;
Cache.push(_local6);
return (_local4);
}
}
}//package TowerDefence.Towers
Section 250
//SpecialEffects (TowerDefence.Towers.SpecialEffects)
package TowerDefence.Towers {
public class SpecialEffects {
public static const Death:int = 2;
public static const Nothing:int = 0;
public static const Reveal:int = 1;
}
}//package TowerDefence.Towers
Section 251
//TargetModes (TowerDefence.Towers.TargetModes)
package TowerDefence.Towers {
public class TargetModes {
public static const Weakest:int = 3;
public static const Strongest:int = 4;
public static const Closest:int = 1;
public static const Automatic:int = 0;
public static const Furthest:int = 2;
}
}//package TowerDefence.Towers
Section 252
//Tower (TowerDefence.Towers.Tower)
package TowerDefence.Towers {
import TowerDefence.*;
import flash.display.*;
import TowerDefence.Monsters.*;
import flash.media.*;
import flash.geom.*;
import TowerDefence.Interface.*;
import Assets.Towers.*;
import flash.filters.*;
public class Tower {
public var TargetMode:int;
private var FrameIndex:int;
public var Imbueable:Boolean;
private var Highlight:Boolean;
private var ClickArea:SimpleRectangle;
private var ImbueingTo:int;
private var FrameTicks:int;
public var CurrentLevel:Level;
private var ClickZone:ClickZone;
public var Imbue:int;
public var NextLevel:Level;
public var Upgrading:Boolean;
private var Image:BitmapData;
private var GridLocation:SimplePoint;
public var TotalSpent:int;
public var Location:SimplePoint;
private var HighlightOpacity:Number;
private var LastFired:int;
public var Config:TowerConfig;
private var UpgradingClock:int;
public var CurrentLevelIndex:int;
public var Imbueing:Boolean;
public var Center:SimplePoint;
private var ImbueingClock:int;
public var Bonus:int;
private static const MissileStart:SimplePoint = new SimplePoint();
private static const TowerPoint:SimplePoint = new SimplePoint();
private static const LevelRectangle:Rectangle = new Rectangle(3, 0, 4, 4);
private static const FireFilter:GlowFilter = new GlowFilter(0xFF0000, 0.75);
private static const LevelRectangleBorder:Rectangle = new Rectangle(2, 0, 6, 6);
private static const ZeroPoint:Point = new Point(0, 0);
private static const PoisonFilter:GlowFilter = new GlowFilter(0xFF00, 0.75);
private static const RelativeLocation:Point = new Point();
private static const IceFilter:GlowFilter = new GlowFilter(6737151, 0.75);
private static const RadiusPoint:Point = new Point();
private static var CurrentTower2:Tower;
private static var CurrentTowerLocation:SimplePoint;
private static var TempDistance:Number;
private static var ViewingTower:Tower;
private static var UpgradingImage:BitmapData;
private static var CurrentTargetHitPoints:int;
private static var CurrentTower:Tower;
private static var LowGraphicsMode:Boolean;
private static var CurrentTowerLevel:Level;
private static var CurrentTowerDamageStrong:int;
private static var GridLocation:SimplePoint;
private static var Pool:Array = new Array();
private static var Hovering:Boolean = false;
private static var CurrentTarget:Monster;
private static var FilteredBitmap:BitmapData = new BitmapData(20, 40, true, 0xFFFFFF);
private static var UpgradeComplete:Sound;
private static var MouseLocation:SimplePoint;
private static var TempRadiusImage:BitmapData;
private static var Direction:int;
public static var Container:Array = new Array();
private static var BuildingPlacement:Sound;
private static var ComparisonData:Number;
private static var CurrentTowerConfig:TowerConfig;
private static var Filter:GlowFilter = new GlowFilter();
private static var MapRectangle:Rectangle;
private static var CurrentTargetHits:int;
private static var Monster:Monster;
private static var Selected:Tower;
private static var CurrentTowerDamage:int;
private static var HoveringOn:Tower;
private static var CurrentTowerDamageWeak:int;
private static var MonstersInRange:Array;
private static var CurrentTowerRange:int;
private static var OnClickArea:Boolean;
private static var Monsters:Array;
public function Tower(){
Location = new SimplePoint();
GridLocation = new SimplePoint();
Center = new SimplePoint();
Image = new BitmapData(20, 40);
ClickArea = new SimpleRectangle(0, 0, 40, 40);
super();
}
public static function Upgrade():void{
if (((((((Game.ViewingTower.Imbueing) || (Game.ViewingTower.Upgrading))) || ((Game.ViewingTower.NextLevel == null)))) || ((Game.ViewingTower.NextLevel.Price > Statistics.Gold)))){
return;
};
Game.ViewingTower.TotalSpent = (Game.ViewingTower.TotalSpent + Game.ViewingTower.NextLevel.Price);
Game.ViewingTower.Upgrading = true;
Game.ViewingTower.UpgradingClock = 0;
Statistics.Gold = (Statistics.Gold - Game.ViewingTower.NextLevel.Price);
Statistics.MonsterKills.Monster4 = String((int(Statistics.MonsterKills.Monster4) - Game.ViewingTower.NextLevel.Price));
Statistics.TowerKills.Tower3 = Number((int(Statistics.TowerKills.Tower3) - Game.ViewingTower.NextLevel.Price));
Statistics.MissilesFired.Missile2 = uint((int(Statistics.MissilesFired.Missile2) - Game.ViewingTower.NextLevel.Price));
FadingText.Create(("-" + Game.ViewingTower.NextLevel.Price), Game.ViewingTower.Location.X, Game.ViewingTower.Location.Y);
}
public static function Create(_arg1:TowerConfig):void{
var tower:Tower;
var config = _arg1;
GridLocation = Game.GridLocation;
tower = GetInstance();
tower.Config = config;
tower.Location.X = (GridLocation.X * 40);
tower.Location.Y = ((GridLocation.Y * 40) - 26);
tower.GridLocation.X = GridLocation.X;
tower.GridLocation.Y = GridLocation.Y;
tower.Center.X = ((GridLocation.X * 40) + 20);
tower.Center.Y = ((GridLocation.Y * 40) + 20);
tower.TotalSpent = config.Levels[0].Price;
tower.Image = ((config.Images)!=null) ? config.Images[0] : ((config.AnimationImages)!=null) ? tower.Image = config.AnimationImages[0] : config.Image;
tower.CurrentLevel = config.Levels[0];
tower.CurrentLevelIndex = 0;
tower.NextLevel = ((config.Levels.length > 0)) ? config.Levels[1] : null;
tower.LastFired = 0;
tower.TargetMode = TargetModes.Automatic;
tower.Upgrading = false;
tower.Imbueing = false;
tower.Imbue = config.Imbue;
tower.Imbueable = config.Imbueable;
tower.Highlight = false;
tower.FrameIndex = 0;
tower.FrameTicks = 6;
tower.ClickArea.X = tower.Location.X;
tower.ClickArea.Y = (tower.Location.Y + 40);
tower.ClickZone = ClickZone.Create(tower.ClickArea, function (){
ShowTower(tower);
});
tower.Bonus = 0;
Container.push(tower);
Game.Level.Buildable[GridLocation.Y][GridLocation.X] = false;
SoundManager.PlaySound(BuildingPlacement);
FadingText.Create(("-" + tower.TotalSpent), (tower.Location.X + 10), (tower.Location.Y + 10));
CalculateGeneratorBonuses();
}
private static function CalculateGeneratorBonuses():void{
var _local1:Array;
var _local2:Array;
var _local3:Tower;
var _local4:int;
var _local5:int;
_local1 = new Array();
_local2 = new Array();
_local4 = 0;
while (_local4 < Container.length) {
CurrentTower2 = Container[_local4];
if (CurrentTower2.Config.Title == "Generator"){
_local1.push(CurrentTower2);
} else {
CurrentTower2.Bonus = 0;
_local2.push(CurrentTower2);
};
_local4++;
};
_local4 = 0;
while (_local4 < _local1.length) {
_local3 = _local1[_local4];
_local5 = 0;
while (_local5 < _local2.length) {
CurrentTower2 = _local2[_local5];
TempDistance = Math.abs(SimplePoint.Distance(_local3.Center, CurrentTower2.Center));
if (TempDistance <= _local3.CurrentLevel.Range){
CurrentTower2.Bonus++;
};
_local5++;
};
_local4++;
};
}
public static function Init():void{
UpgradingImage = new Upgrading(40, 60);
UpgradeComplete = new UpgradeComplete();
BuildingPlacement = new BuildingPlacement();
}
private static function FindFiringPoint():void{
var _local1:int;
Direction = Directions.North;
ComparisonData = -1;
_local1 = 0;
while (_local1 < 8) {
TowerPoint.X = (CurrentTowerLocation.X + CurrentTowerConfig.FiringPoints[_local1].X);
TowerPoint.Y = (CurrentTowerLocation.Y + CurrentTowerConfig.FiringPoints[_local1].Y);
TempDistance = SimplePoint.Distance(Monster.Center, TowerPoint);
if ((((ComparisonData == -1)) || ((TempDistance < ComparisonData)))){
ComparisonData = TempDistance;
Direction = _local1;
};
_local1++;
};
}
public static function RemoveAll():void{
var _local1:int;
_local1 = (Container.length - 1);
while (_local1 > -1) {
Remove(Container[_local1]);
_local1--;
};
}
private static function ImbueTick():void{
CurrentTower.ImbueingClock++;
if (CurrentTower.ImbueingClock < ImbueTypes.ImbueTime){
if (Game.ViewingTower == CurrentTower){
Game.MainBar.TowerImbueing.Bar.width = int(((CurrentTower.ImbueingClock / ImbueTypes.ImbueTime) * 228));
};
return;
};
CurrentTower.Imbueing = false;
CurrentTower.Imbue = CurrentTower.ImbueingTo;
CurrentTower.Highlight = true;
CurrentTower.HighlightOpacity = 1;
SoundManager.PlayTowerSound(UpgradeComplete);
Message.SetMessage(Game.Language.ImbueComplete);
if (Game.ViewingTower == CurrentTower){
Game.MainBar.ShowTowerInfo();
Game.MainBar.TowerInfo.Refresh();
};
}
public static function Sell():void{
var _local1:int;
_local1 = Math.round((Game.ViewingTower.TotalSpent * 0.5));
Statistics.Gold = (Statistics.Gold + _local1);
Statistics.MonsterKills.Monster4 = String((int(Statistics.MonsterKills.Monster4) + _local1));
Statistics.TowerKills.Tower3 = Number((int(Statistics.TowerKills.Tower3) + _local1));
Statistics.MissilesFired.Missile2 = uint((int(Statistics.MissilesFired.Missile2) + _local1));
FadingText.Create(("+" + _local1), Game.ViewingTower.Location.X, Game.ViewingTower.Location.Y);
Remove(Game.ViewingTower);
}
private static function FindAutomaticTarget():void{
var _local1:int;
CurrentTowerDamage = Math.round(((CurrentTowerLevel.DamageMin + CurrentTowerLevel.DamageMax) / 2));
CurrentTowerDamageStrong = int((CurrentTowerDamage / 3));
CurrentTowerDamageWeak = int((CurrentTowerDamage * 1.5));
ComparisonData = -1;
_local1 = 0;
while (_local1 < Monsters.length) {
CurrentTarget = Monsters[_local1];
if (((CurrentTarget.Ignore) || (CurrentTarget.Invisible))){
} else {
TempDistance = SimplePoint.Distance(CurrentTower.Center, CurrentTarget.Center);
if (TempDistance > CurrentTowerRange){
} else {
CurrentTargetHitPoints = CurrentTarget.HitPoints;
switch (CurrentTower.Imbue){
case ImbueTypes.Fire:
if ((((!(CurrentTarget.Config.ImmuneAgainst) == ImmuneTypes.Fire)) && (!(Monster.HasEffect(CurrentTarget, ImbueTypes.Fire))))){
CurrentTargetHitPoints = (CurrentTargetHitPoints - CurrentTowerLevel.DamageDuration);
};
break;
case ImbueTypes.Poison:
if ((((!(CurrentTarget.Config.ImmuneAgainst) == ImmuneTypes.Poison)) && (!(Monster.HasEffect(CurrentTarget, ImbueTypes.Poison))))){
CurrentTargetHitPoints = (CurrentTargetHitPoints - CurrentTowerLevel.DamageDuration);
};
break;
};
if (CurrentTarget.Config.WeakAgainst == CurrentTowerConfig.DamageType){
CurrentTargetHits = (1 + int((CurrentTargetHitPoints / CurrentTowerDamageWeak)));
} else {
if (CurrentTarget.Config.StrongAgainst == CurrentTowerConfig.DamageType){
CurrentTargetHits = (1 + int((CurrentTargetHitPoints / CurrentTowerDamageStrong)));
} else {
CurrentTargetHits = (1 + int((CurrentTargetHitPoints / CurrentTowerDamage)));
};
};
if ((((ComparisonData == -1)) || ((CurrentTargetHits < ComparisonData)))){
Monster = CurrentTarget;
ComparisonData = CurrentTargetHits;
};
};
};
_local1++;
};
}
private static function FindFurthestTarget():void{
var _local1:int;
if (Monsters.length == 1){
return;
};
ComparisonData = -1;
_local1 = 0;
while (_local1 < Monsters.length) {
CurrentTarget = Monsters[_local1];
if (((CurrentTarget.Ignore) || (CurrentTarget.Invisible))){
} else {
TempDistance = SimplePoint.Distance(CurrentTower.Center, CurrentTarget.Center);
if (TempDistance > CurrentTowerRange){
} else {
if ((((ComparisonData == -1)) || ((TempDistance > ComparisonData)))){
Monster = CurrentTarget;
ComparisonData = TempDistance;
};
};
};
_local1++;
};
}
private static function Remove(_arg1:Tower):void{
var _local2:int;
Container.splice(Container.indexOf(_arg1), 1);
Game.Level.Buildable[_arg1.GridLocation.Y][_arg1.GridLocation.X] = true;
ClickZone.Remove(_arg1.ClickZone);
Pool.push(_arg1);
if (Game.ViewingTower == _arg1){
Game.ViewingTower = null;
};
if (_arg1.Config.Title == "Generator"){
_local2 = 0;
while (_local2 < Container.length) {
CurrentTower = Container[_local2];
TempDistance = SimplePoint.Distance(_arg1.Center, CurrentTower.Center);
if (TempDistance <= _arg1.CurrentLevel.Range){
CurrentTower.Bonus = (CurrentTower.Bonus - 0.1);
};
_local2++;
};
};
}
public static function Imbue(_arg1:int):void{
if (((((Game.ViewingTower.Imbueing) || (Game.ViewingTower.Upgrading))) || ((ImbueTypes.Price > Statistics.Gold)))){
return;
};
Game.ViewingTower.TotalSpent = (Game.ViewingTower.TotalSpent + ImbueTypes.Price);
Game.ViewingTower.Imbueing = true;
Game.ViewingTower.ImbueingClock = 0;
Game.ViewingTower.ImbueingTo = _arg1;
Statistics.Gold = (Statistics.Gold - ImbueTypes.Price);
Statistics.MonsterKills.Monster4 = String((int(Statistics.MonsterKills.Monster4) - ImbueTypes.Price));
Statistics.TowerKills.Tower3 = Number((int(Statistics.TowerKills.Tower3) - ImbueTypes.Price));
Statistics.MissilesFired.Missile2 = uint((int(Statistics.MissilesFired.Missile2) - ImbueTypes.Price));
FadingText.Create(("-" + ImbueTypes.Price), Game.ViewingTower.Location.X, Game.ViewingTower.Location.Y);
}
public static function Tick(_arg1:BitmapData):void{
var _local2:int;
var _local3:int;
var _local4:int;
if (Container.length == 0){
return;
};
Monsters = Monster.Container;
Hovering = false;
MapRectangle = Game.MapRectangle;
MouseLocation = Game.MouseLocation;
ViewingTower = Game.ViewingTower;
LowGraphicsMode = Game.LowGraphicsMode;
_local2 = (Container.length - 1);
for (;_local2 > -1;_local2--) {
CurrentTower = Container[_local2];
CurrentTowerConfig = CurrentTower.Config;
CurrentTowerLocation = CurrentTower.Location;
CurrentTowerLevel = CurrentTower.CurrentLevel;
CurrentTowerRange = (CurrentTowerLevel.Range + Game.RangeBonus);
CurrentTarget = null;
Monster = null;
RelativeLocation.x = (CurrentTowerLocation.X - MapRectangle.x);
RelativeLocation.y = (CurrentTowerLocation.Y - MapRectangle.y);
if (Maths.WithinVisibleArea(CurrentTowerLocation.X, CurrentTowerLocation.Y, 40, 60)){
FilteredBitmap = CurrentTower.Image.clone();
if (((CurrentTower.Upgrading) || (CurrentTower.Imbueing))){
FilteredBitmap.copyPixels(UpgradingImage, UpgradingImage.rect, ZeroPoint, null, null, true);
};
if (!Hovering){
OnClickArea = SimpleRectangle.ContainsPoint(CurrentTower.ClickZone.Zone, MouseLocation);
if (((OnClickArea) || ((CurrentTower == ViewingTower)))){
Game.HandCursor = OnClickArea;
Hovering = true;
RadiusPoint.x = ((RelativeLocation.x + 20) - CurrentTowerRange);
RadiusPoint.y = ((RelativeLocation.y + 40) - CurrentTowerRange);
TempRadiusImage = RadiusImage.Create(CurrentTowerRange);
_arg1.copyPixels(TempRadiusImage, TempRadiusImage.rect, RadiusPoint);
};
} else {
if (((((!(LowGraphicsMode)) && (CurrentTower.Highlight))) && ((CurrentTower.HighlightOpacity > 0)))){
Filter.color = 0xFFCC00;
Filter.alpha = CurrentTower.HighlightOpacity;
FilteredBitmap.applyFilter(FilteredBitmap, FilteredBitmap.rect, ZeroPoint, Filter);
};
};
if (((((!(LowGraphicsMode)) && (CurrentTower.Imbueable))) && (!((CurrentTower.Imbue == ImbueTypes.Nothing))))){
if (CurrentTower.Imbue == ImbueTypes.Fire){
FilteredBitmap.applyFilter(FilteredBitmap, FilteredBitmap.rect, ZeroPoint, FireFilter);
} else {
if (CurrentTower.Imbue == ImbueTypes.Ice){
FilteredBitmap.applyFilter(FilteredBitmap, FilteredBitmap.rect, ZeroPoint, IceFilter);
} else {
FilteredBitmap.applyFilter(FilteredBitmap, FilteredBitmap.rect, ZeroPoint, PoisonFilter);
};
};
};
if (((!(LowGraphicsMode)) && ((CurrentTower.CurrentLevelIndex > 0)))){
LevelRectangleBorder.height = (((CurrentTower.CurrentLevelIndex + 1) * 5) + 1);
LevelRectangleBorder.y = (60 - LevelRectangleBorder.height);
FilteredBitmap.fillRect(LevelRectangleBorder, 1879048192);
_local3 = 0;
while (_local3 < (CurrentTower.CurrentLevelIndex + 1)) {
LevelRectangle.y = (55 - (_local3 * 5));
FilteredBitmap.fillRect(LevelRectangle, 1895812096);
_local3++;
};
};
LayeredElement.Create(FilteredBitmap, RelativeLocation, CurrentTower.GridLocation.Y);
};
if (CurrentTower.HighlightOpacity > 0){
CurrentTower.HighlightOpacity = (CurrentTower.HighlightOpacity - 0.01);
};
if (CurrentTower.Upgrading){
UpgradeTick();
continue;
} else {
if (CurrentTower.Imbueing){
ImbueTick();
continue;
};
};
if (((!(LowGraphicsMode)) && (!((CurrentTowerConfig.AnimationImages == null))))){
if (CurrentTower.FrameTicks == 0){
CurrentTower.FrameTicks = 7;
CurrentTower.FrameIndex++;
if (CurrentTower.FrameIndex == CurrentTowerConfig.AnimationImages.length){
CurrentTower.FrameIndex = 0;
};
} else {
CurrentTower.FrameTicks--;
};
CurrentTower.Image = CurrentTowerConfig.AnimationImages[CurrentTower.FrameIndex];
};
if ((((Monsters.length == 0)) || ((CurrentTowerConfig.Title == "Generator")))){
} else {
if (CurrentTowerConfig.SpecialEffect != SpecialEffects.Nothing){
FindMonstersInRange();
if (MonstersInRange.length == 0){
continue;
};
if (CurrentTowerConfig.SpecialEffect == SpecialEffects.Reveal){
_local4 = 0;
while (_local4 < MonstersInRange.length) {
Monster = MonstersInRange[_local4];
if (((Monster.Config.Invisible) && (!(Monster.HasRevealEffect(Monster, CurrentTower))))){
Monster.RevealEffects.push(RevealEffect.Create(CurrentTower));
};
_local4++;
};
} else {
if (CurrentTowerConfig.SpecialEffect == SpecialEffects.Death){
_local4 = 0;
while (_local4 < MonstersInRange.length) {
Monster = MonstersInRange[_local4];
if (((!(Monster.Invisible)) && (!(Monster.Dying)))){
Monster.ApplyDamage(1, Monster, null);
};
_local4++;
};
};
};
continue;
} else {
if (CurrentTowerConfig.FiringPoints == null){
continue;
};
};
if (CurrentTower.LastFired > 0){
CurrentTower.LastFired--;
} else {
if (Monsters.length == 0){
} else {
switch (CurrentTower.TargetMode){
case TargetModes.Automatic:
FindAutomaticTarget();
break;
case TargetModes.Closest:
FindClosestTarget();
break;
case TargetModes.Furthest:
FindFurthestTarget();
break;
case TargetModes.Weakest:
FindWeakestTarget();
break;
case TargetModes.Strongest:
FindStrongestTarget();
break;
};
if (Monster == null){
} else {
if (CurrentTowerConfig.Images != null){
CurrentTower.Image = CurrentTowerConfig.Images[Direction];
};
FindFiringPoint();
MissileStart.X = (CurrentTowerLocation.X + CurrentTowerConfig.FiringPoints[Direction].X);
MissileStart.Y = (CurrentTowerLocation.Y + CurrentTowerConfig.FiringPoints[Direction].Y);
CurrentTower.LastFired = CurrentTowerLevel.FireRate;
Missile.Create(Monster, CurrentTower, MissileStart, Direction);
};
};
};
};
};
}
private static function UpgradeTick():void{
CurrentTower.UpgradingClock++;
if (CurrentTower.UpgradingClock < CurrentTower.NextLevel.UpgradeTime){
if (Game.ViewingTower == CurrentTower){
Game.MainBar.TowerUpgrading.Bar.width = int(((CurrentTower.UpgradingClock / CurrentTower.NextLevel.UpgradeTime) * 228));
};
return;
};
CurrentTower.Upgrading = false;
CurrentTower.CurrentLevelIndex++;
CurrentTower.CurrentLevel = CurrentTowerConfig.Levels[CurrentTower.CurrentLevelIndex];
CurrentTower.Highlight = true;
CurrentTower.HighlightOpacity = 1;
if (CurrentTower.CurrentLevelIndex < (CurrentTowerConfig.Levels.length - 1)){
CurrentTower.NextLevel = CurrentTowerConfig.Levels[CurrentTower.CurrentLevelIndex];
} else {
CurrentTower.NextLevel = null;
};
Message.SetMessage(Game.Language.UpgradeComplete);
SoundManager.PlayTowerSound(UpgradeComplete);
if (Game.ViewingTower == CurrentTower){
Game.MainBar.ShowTowerInfo();
Game.MainBar.TowerInfo.Refresh();
};
if (CurrentTowerConfig.Title == "Generator"){
CalculateGeneratorBonuses();
};
}
private static function FindMonstersInRange():void{
var _local1:int;
MonstersInRange = new Array();
_local1 = 0;
while (_local1 < Monsters.length) {
CurrentTarget = Monsters[_local1];
TempDistance = SimplePoint.Distance(CurrentTower.Center, CurrentTarget.Center);
if (TempDistance > CurrentTowerRange){
} else {
MonstersInRange.push(CurrentTarget);
};
_local1++;
};
}
private static function FindStrongestTarget():void{
var _local1:int;
ComparisonData = -1;
_local1 = 1;
while (_local1 < Monsters.length) {
CurrentTarget = Monsters[_local1];
if (((CurrentTarget.Ignore) || (CurrentTarget.Invisible))){
} else {
TempDistance = SimplePoint.Distance(CurrentTower.Center, CurrentTarget.Center);
if (TempDistance > CurrentTowerRange){
} else {
if ((((ComparisonData == -1)) || ((CurrentTarget.HitPoints > ComparisonData)))){
Monster = CurrentTarget;
ComparisonData = CurrentTarget.HitPoints;
};
};
};
_local1++;
};
}
private static function GetInstance():Tower{
if (Pool.length > 0){
return (Pool.pop());
};
return (new (Tower));
}
private static function ShowTower(_arg1:Tower):void{
Game.MainBar.TowerInfo.Show(_arg1);
}
private static function FindWeakestTarget():void{
var _local1:int;
ComparisonData = -1;
_local1 = 0;
while (_local1 < Monsters.length) {
CurrentTarget = Monsters[_local1];
if (((CurrentTarget.Ignore) || (CurrentTarget.Invisible))){
} else {
TempDistance = SimplePoint.Distance(CurrentTower.Center, CurrentTarget.Center);
if (TempDistance > CurrentTowerRange){
} else {
if ((((ComparisonData == -1)) || ((CurrentTarget.HitPoints < ComparisonData)))){
Monster = CurrentTarget;
ComparisonData = CurrentTarget.HitPoints;
};
};
};
_local1++;
};
}
private static function FindClosestTarget():void{
var _local1:int;
ComparisonData = -1;
_local1 = 0;
while (_local1 < Monsters.length) {
CurrentTarget = Monsters[_local1];
if (((CurrentTarget.Ignore) || (CurrentTarget.Invisible))){
} else {
TempDistance = SimplePoint.Distance(CurrentTower.Center, CurrentTarget.Center);
if (TempDistance > CurrentTowerRange){
} else {
if ((((ComparisonData == -1)) || ((TempDistance < ComparisonData)))){
Monster = CurrentTarget;
ComparisonData = TempDistance;
};
};
};
_local1++;
};
}
}
}//package TowerDefence.Towers
Section 253
//TowerConfig (TowerDefence.Towers.TowerConfig)
package TowerDefence.Towers {
import TowerDefence.*;
import flash.display.*;
import flash.media.*;
import flash.geom.*;
import Assets.Towers.*;
public class TowerConfig {
public var AnimationImages:Array;
public var Missile:BitmapData;
public var SpecialEffect:int;
public var Thumbnail:BitmapData;
public var ExplosionImages:Array;
public var Levels:Array;
public var Imbueable:Boolean;// = false
public var MissileExplodes:Boolean;// = false
public var FireSound:Sound;
public var FiringPoints:Array;
public var HasTargeting:Boolean;// = true
public var Images:Array;
public var Price:int;
public var Missiles:Array;
public var Imbue:int;
public var DamageType:int;
public var Title:String;
public var Image:BitmapData;
public var Sight:Boolean;
public static const PoisonTower:TowerConfig = new (TowerConfig);
;
public static const EnergyTower:TowerConfig = new (TowerConfig);
;
public static const ScoutTower:TowerConfig = new (TowerConfig);
;
public static const SniperTower:TowerConfig = new (TowerConfig);
;
public static const FireTower:TowerConfig = new (TowerConfig);
;
public static const DeathTower:TowerConfig = new (TowerConfig);
;
private static const SliceRectangle:Rectangle = new Rectangle(0, 0, 40, 60);
public static const IceTower:TowerConfig = new (TowerConfig);
;
public static const ArrowTower:TowerConfig = new (TowerConfig);
;
private static const ZeroPoint:Point = new Point(0, 0);
public static const CannonTower:TowerConfig = new (TowerConfig);
;
public static const Generator:TowerConfig = new (TowerConfig);
;
private static var NumSlices:int;
private static var Slice:BitmapData;
public function TowerConfig(){
SpecialEffect = SpecialEffects.Nothing;
MissileExplodes = false;
Imbue = ImbueTypes.Nothing;
Imbueable = false;
HasTargeting = true;
super();
}
private static function SliceAnimationImages(_arg1:BitmapData):Array{
var _local2:Array;
var _local3:int;
NumSlices = (_arg1.width / 40);
SliceRectangle.width = 40;
SliceRectangle.height = 60;
_local2 = new Array();
_local3 = 0;
while (_local3 < NumSlices) {
SliceRectangle.x = (_local3 * 40);
SliceRectangle.y = 0;
Slice = new BitmapData(40, 60, true, 0xFFFFFF);
Slice.copyPixels(_arg1, SliceRectangle, ZeroPoint);
_local2.push(Slice);
_local3++;
};
return (_local2);
}
private static function SliceThumbnail(_arg1:BitmapData, _arg2:int, _arg3:int):BitmapData{
SliceRectangle.x = _arg2;
SliceRectangle.y = _arg3;
SliceRectangle.width = 72;
SliceRectangle.height = 72;
Slice = new BitmapData(72, 72);
Slice.copyPixels(_arg1, SliceRectangle, ZeroPoint);
return (Slice);
}
private static function SliceExplosionImages():Array{
var _local1:BitmapData;
var _local2:Array;
var _local3:int;
var _local4:Rectangle;
var _local5:int;
var _local6:int;
_local1 = new FireExplosion(0x0200, 494);
_local2 = new Array(16);
_local3 = 0;
_local4 = new Rectangle(0, 0, 128, 128);
_local5 = 0;
while (_local5 < 4) {
_local6 = 0;
while (_local6 < 4) {
_local4.x = (_local6 * 128);
_local4.y = (_local5 * 128);
_local2[_local3] = new BitmapData(128, 128);
_local2[_local3].copyPixels(_local1, _local4, ZeroPoint);
_local3++;
_local6++;
};
_local5++;
};
return (_local2);
}
private static function SliceDirectionalImage(_arg1:BitmapData, _arg2:int, _arg3:int):BitmapData{
SliceRectangle.x = _arg2;
SliceRectangle.y = _arg3;
SliceRectangle.width = 40;
SliceRectangle.height = 60;
Slice = new BitmapData(40, 60, true, 0xFFFFFF);
Slice.copyPixels(_arg1, SliceRectangle, ZeroPoint);
return (Slice);
}
public static function Init():void{
var _local1:BitmapData;
var _local2:BitmapData;
_local1 = new ArrowMissile(53, 38);
ArrowTower.FireSound = new ArrowFireSound();
ArrowTower.AnimationImages = SliceAnimationImages(new ArrowTower(160, 60));
ArrowTower.Missiles = new Array(8);
ArrowTower.Missiles[Directions.North] = new BitmapData(6, 20);
ArrowTower.Missiles[Directions.North].copyPixels(_local1, new Rectangle(0, 0, 6, 20), ZeroPoint);
ArrowTower.Missiles[Directions.South] = new BitmapData(6, 20);
ArrowTower.Missiles[Directions.South].copyPixels(_local1, new Rectangle(20, 0, 6, 20), ZeroPoint);
ArrowTower.Missiles[Directions.East] = new BitmapData(20, 6);
ArrowTower.Missiles[Directions.East].copyPixels(_local1, new Rectangle(40, 0, 20, 6), ZeroPoint);
ArrowTower.Missiles[Directions.West] = new BitmapData(20, 6);
ArrowTower.Missiles[Directions.West].copyPixels(_local1, new Rectangle(60, 0, 20, 6), ZeroPoint);
ArrowTower.Missiles[Directions.NorthEast] = new BitmapData(16, 16);
ArrowTower.Missiles[Directions.NorthEast].copyPixels(_local1, new Rectangle(0, 20, 16, 16), ZeroPoint);
ArrowTower.Missiles[Directions.NorthWest] = new BitmapData(15, 15);
ArrowTower.Missiles[Directions.NorthWest].copyPixels(_local1, new Rectangle(20, 20, 15, 15), ZeroPoint);
ArrowTower.Missiles[Directions.SouthEast] = new BitmapData(16, 16);
ArrowTower.Missiles[Directions.SouthEast].copyPixels(_local1, new Rectangle(40, 20, 16, 16), ZeroPoint);
ArrowTower.Missiles[Directions.SouthWest] = new BitmapData(14, 18);
ArrowTower.Missiles[Directions.SouthWest].copyPixels(_local1, new Rectangle(60, 20, 14, 18), ZeroPoint);
CannonTower.Missile = new CannonMissile(12, 12);
CannonTower.FireSound = new CannonFireSound();
CannonTower.Images = SliceDirectionalImages(new CannonTower(160, 120));
IceTower.Missile = new IceMissile(32, 30);
IceTower.FireSound = new IceFireSound();
IceTower.Images = SliceDirectionalImages(new IceTower(160, 120));
PoisonTower.Missile = new PoisonMissile(26, 25);
PoisonTower.FireSound = new PoisonFireSound();
PoisonTower.AnimationImages = SliceAnimationImages(new PoisonTower(120, 60));
FireTower.Missile = new FireMissile(28, 30);
FireTower.FireSound = new FireFireSound();
FireTower.Images = SliceDirectionalImages(new FireTower(160, 120));
FireTower.ExplosionImages = SliceExplosionImages();
EnergyTower.Missile = new EnergyMissile(25, 25);
EnergyTower.FireSound = new CannonFireSound();
EnergyTower.AnimationImages = SliceAnimationImages(new EnergyTower(160, 60));
ScoutTower.AnimationImages = SliceAnimationImages(new ScoutTower(160, 60));
SniperTower.Image = new SniperTower(160, 60);
SniperTower.FireSound = new ArrowFireSound();
SniperTower.Missiles = new Array(8);
SniperTower.Missiles[Directions.North] = new BitmapData(6, 20);
SniperTower.Missiles[Directions.North].copyPixels(_local1, new Rectangle(0, 0, 6, 20), ZeroPoint);
SniperTower.Missiles[Directions.South] = new BitmapData(6, 20);
SniperTower.Missiles[Directions.South].copyPixels(_local1, new Rectangle(20, 0, 6, 20), ZeroPoint);
SniperTower.Missiles[Directions.East] = new BitmapData(20, 6);
SniperTower.Missiles[Directions.East].copyPixels(_local1, new Rectangle(40, 0, 20, 6), ZeroPoint);
SniperTower.Missiles[Directions.West] = new BitmapData(20, 6);
SniperTower.Missiles[Directions.West].copyPixels(_local1, new Rectangle(60, 0, 20, 6), ZeroPoint);
SniperTower.Missiles[Directions.NorthEast] = new BitmapData(16, 16);
SniperTower.Missiles[Directions.NorthEast].copyPixels(_local1, new Rectangle(0, 20, 16, 16), ZeroPoint);
SniperTower.Missiles[Directions.NorthWest] = new BitmapData(15, 15);
SniperTower.Missiles[Directions.NorthWest].copyPixels(_local1, new Rectangle(20, 20, 15, 15), ZeroPoint);
SniperTower.Missiles[Directions.SouthEast] = new BitmapData(16, 16);
SniperTower.Missiles[Directions.SouthEast].copyPixels(_local1, new Rectangle(40, 20, 16, 16), ZeroPoint);
SniperTower.Missiles[Directions.SouthWest] = new BitmapData(14, 18);
SniperTower.Missiles[Directions.SouthWest].copyPixels(_local1, new Rectangle(60, 20, 14, 18), ZeroPoint);
Generator.AnimationImages = SliceAnimationImages(new Generator(160, 60));
DeathTower.AnimationImages = SliceAnimationImages(new DeathTower(160, 60));
_local2 = new Thumbnails(360, 144);
ArrowTower.Thumbnail = SliceThumbnail(_local2, 0, 0);
CannonTower.Thumbnail = SliceThumbnail(_local2, 144, 0);
IceTower.Thumbnail = SliceThumbnail(_local2, 216, 0);
PoisonTower.Thumbnail = SliceThumbnail(_local2, 72, 0);
FireTower.Thumbnail = SliceThumbnail(_local2, 288, 0);
EnergyTower.Thumbnail = SliceThumbnail(_local2, 360, 0);
ScoutTower.Thumbnail = SliceThumbnail(_local2, 0, 72);
SniperTower.Thumbnail = SliceThumbnail(_local2, 288, 72);
Generator.Thumbnail = SliceThumbnail(_local2, 360, 72);
DeathTower.Thumbnail = SliceThumbnail(_local2, 216, 72);
_local2 = null;
}
private static function SliceDirectionalImages(_arg1:BitmapData):Array{
var _local2:Array;
_local2 = new Array(8);
_local2[Directions.North] = SliceDirectionalImage(_arg1, 40, 0);
_local2[Directions.South] = SliceDirectionalImage(_arg1, 80, 60);
_local2[Directions.East] = SliceDirectionalImage(_arg1, 0, 60);
_local2[Directions.West] = SliceDirectionalImage(_arg1, 120, 0);
_local2[Directions.NorthEast] = SliceDirectionalImage(_arg1, 80, 0);
_local2[Directions.NorthWest] = SliceDirectionalImage(_arg1, 0, 0);
_local2[Directions.SouthEast] = SliceDirectionalImage(_arg1, 120, 60);
_local2[Directions.SouthWest] = SliceDirectionalImage(_arg1, 40, 60);
return (_local2);
}
ArrowTower.Title = "Arrow Tower";
ArrowTower.DamageType = DamageTypes.Piercing;
ArrowTower.Price = 10;
ArrowTower.Imbueable = true;
ArrowTower.FiringPoints = new Array(8);
ArrowTower.FiringPoints[Directions.North] = new SimplePoint(12, 6);
ArrowTower.FiringPoints[Directions.South] = new SimplePoint(12, 20);
ArrowTower.FiringPoints[Directions.East] = new SimplePoint(19, 13);
ArrowTower.FiringPoints[Directions.West] = new SimplePoint(4, 13);
ArrowTower.FiringPoints[Directions.NorthEast] = new SimplePoint(17, 9);
ArrowTower.FiringPoints[Directions.NorthWest] = new SimplePoint(6, 8);
ArrowTower.FiringPoints[Directions.SouthEast] = new SimplePoint(17, 18);
ArrowTower.FiringPoints[Directions.SouthWest] = new SimplePoint(7, 18);
ArrowTower.Levels = [new Level(10, 1, 10, 100, 25, 26, 200), new Level(5, 5, 15, 110, 30, 25, 200), new Level(7, 10, 20, 120, 35, 24, 200), new Level(10, 15, 25, 130, 40, 23, 200), new Level(12, 20, 30, 140, 45, 22, 200), new Level(15, 25, 35, 150, 50, 21, 200)];
CannonTower.Title = "Cannon Tower";
CannonTower.DamageType = DamageTypes.Impact;
CannonTower.Price = 20;
CannonTower.Imbueable = true;
CannonTower.FiringPoints = new Array(8);
CannonTower.FiringPoints[Directions.North] = new SimplePoint(10, 0);
CannonTower.FiringPoints[Directions.South] = new SimplePoint(12, 16);
CannonTower.FiringPoints[Directions.East] = new SimplePoint(19, 7);
CannonTower.FiringPoints[Directions.West] = new SimplePoint(1, 6);
CannonTower.FiringPoints[Directions.NorthEast] = new SimplePoint(17, 4);
CannonTower.FiringPoints[Directions.NorthWest] = new SimplePoint(4, 5);
CannonTower.FiringPoints[Directions.SouthEast] = new SimplePoint(17, 15);
CannonTower.FiringPoints[Directions.SouthWest] = new SimplePoint(2, 11);
CannonTower.Levels = [new Level(20, 5, 20, 90, 25, 34, 220), new Level(10, 15, 30, 95, 30, 33, 220), new Level(12, 25, 40, 100, 35, 32, 220), new Level(15, 35, 50, 105, 40, 31, 220), new Level(17, 45, 60, 110, 45, 30, 220), new Level(20, 55, 70, 115, 50, 29, 220)];
IceTower.Title = "Ice Tower";
IceTower.DamageType = DamageTypes.Ice;
IceTower.Price = 50;
IceTower.Imbue = ImbueTypes.Ice;
IceTower.FiringPoints = new Array(8);
IceTower.FiringPoints[Directions.North] = new SimplePoint(10, 0);
IceTower.FiringPoints[Directions.South] = new SimplePoint(12, 16);
IceTower.FiringPoints[Directions.East] = new SimplePoint(19, 7);
IceTower.FiringPoints[Directions.West] = new SimplePoint(1, 6);
IceTower.FiringPoints[Directions.NorthEast] = new SimplePoint(17, 4);
IceTower.FiringPoints[Directions.NorthWest] = new SimplePoint(4, 5);
IceTower.FiringPoints[Directions.SouthEast] = new SimplePoint(17, 15);
IceTower.FiringPoints[Directions.SouthWest] = new SimplePoint(2, 11);
IceTower.Levels = [new Level(50, 10, 20, 80, 300, 44, 300), new Level(20, 15, 25, 90, 360, 43, 300), new Level(25, 20, 30, 100, 420, 42, 300), new Level(30, 25, 35, 110, 480, 41, 300), new Level(35, 30, 40, 120, 540, 40, 300), new Level(40, 35, 45, 130, 600, 39, 300)];
PoisonTower.Title = "Poison Tower";
PoisonTower.DamageType = DamageTypes.Poison;
PoisonTower.Price = 50;
PoisonTower.Imbue = ImbueTypes.Poison;
PoisonTower.FiringPoints = new Array(8);
PoisonTower.FiringPoints[Directions.North] = new SimplePoint(12, 3);
PoisonTower.FiringPoints[Directions.South] = new SimplePoint(12, 18);
PoisonTower.FiringPoints[Directions.East] = new SimplePoint(19, 10);
PoisonTower.FiringPoints[Directions.West] = new SimplePoint(4, 10);
PoisonTower.FiringPoints[Directions.NorthEast] = new SimplePoint(17, 6);
PoisonTower.FiringPoints[Directions.NorthWest] = new SimplePoint(6, 5);
PoisonTower.FiringPoints[Directions.SouthEast] = new SimplePoint(17, 15);
PoisonTower.FiringPoints[Directions.SouthWest] = new SimplePoint(7, 15);
PoisonTower.Levels = [new Level(50, 10, 20, 80, 150, 40, 300), new Level(25, 15, 30, 85, 180, 39, 300), new Level(30, 20, 40, 90, 210, 38, 300), new Level(35, 25, 50, 95, 240, 37, 300), new Level(40, 30, 60, 100, 270, 36, 300), new Level(45, 35, 70, 105, 300, 35, 300)];
FireTower.Title = "Fire Tower";
FireTower.DamageType = DamageTypes.Fire;
FireTower.Price = 75;
FireTower.MissileExplodes = true;
FireTower.FiringPoints = new Array(8);
FireTower.FiringPoints[Directions.North] = new SimplePoint(10, 0);
FireTower.FiringPoints[Directions.South] = new SimplePoint(12, 16);
FireTower.FiringPoints[Directions.East] = new SimplePoint(19, 7);
FireTower.FiringPoints[Directions.West] = new SimplePoint(1, 6);
FireTower.FiringPoints[Directions.NorthEast] = new SimplePoint(17, 4);
FireTower.FiringPoints[Directions.NorthWest] = new SimplePoint(4, 5);
FireTower.FiringPoints[Directions.SouthEast] = new SimplePoint(17, 15);
FireTower.FiringPoints[Directions.SouthWest] = new SimplePoint(2, 11);
FireTower.Levels = [new Level(75, 50, 100, 100, 0, 60, 400), new Level(25, 60, 120, 105, 0, 58, 400), new Level(30, 70, 140, 110, 0, 56, 400), new Level(35, 80, 160, 115, 0, 54, 400), new Level(40, 90, 180, 120, 0, 52, 400), new Level(45, 100, 200, 125, 0, 50, 400)];
EnergyTower.Title = "Energy Tower";
EnergyTower.Price = 100;
EnergyTower.Levels = [new Level(100, 100, 150, 120, 0, 50, 0), new Level(30, 150, 200, 130, 0, 46, 450), new Level(40, 200, 250, 140, 0, 42, 450), new Level(50, 250, 300, 150, 0, 38, 450)];
EnergyTower.FiringPoints = new Array(8);
EnergyTower.FiringPoints[Directions.North] = new SimplePoint(10, 5);
EnergyTower.FiringPoints[Directions.South] = new SimplePoint(10, 5);
EnergyTower.FiringPoints[Directions.East] = new SimplePoint(10, 5);
EnergyTower.FiringPoints[Directions.West] = new SimplePoint(10, 5);
EnergyTower.FiringPoints[Directions.NorthEast] = new SimplePoint(10, 5);
EnergyTower.FiringPoints[Directions.NorthWest] = new SimplePoint(10, 5);
EnergyTower.FiringPoints[Directions.SouthEast] = new SimplePoint(10, 5);
EnergyTower.FiringPoints[Directions.SouthWest] = new SimplePoint(10, 5);
ScoutTower.Title = "Scout Tower";
ScoutTower.Price = 50;
ScoutTower.SpecialEffect = SpecialEffects.Reveal;
ScoutTower.Levels = [new Level(50, 0, 0, 150, 0, 0, 0)];
SniperTower.Title = "Sniper Tower";
SniperTower.Price = 125;
SniperTower.Levels = [new Level(125, 175, 350, 180, 0, 80, 0), new Level(30, 200, 400, 190, 0, 75, 300), new Level(30, 225, 450, 200, 0, 70, 350), new Level(30, 250, 500, 210, 0, 65, 400)];
SniperTower.FiringPoints = new Array(8);
SniperTower.FiringPoints[Directions.North] = new SimplePoint(12, 6);
SniperTower.FiringPoints[Directions.South] = new SimplePoint(12, 20);
SniperTower.FiringPoints[Directions.East] = new SimplePoint(19, 13);
SniperTower.FiringPoints[Directions.West] = new SimplePoint(4, 13);
SniperTower.FiringPoints[Directions.NorthEast] = new SimplePoint(17, 9);
SniperTower.FiringPoints[Directions.NorthWest] = new SimplePoint(6, 8);
SniperTower.FiringPoints[Directions.SouthEast] = new SimplePoint(17, 18);
SniperTower.FiringPoints[Directions.SouthWest] = new SimplePoint(7, 18);
Generator.Title = "Generator";
Generator.Price = 150;
Generator.HasTargeting = false;
Generator.Levels = [new Level(150, 0, 0, 80, 0, 50, 0), new Level(25, 0, 0, 100, 150, 36, 640), new Level(25, 0, 0, 120, 200, 36, 680)];
DeathTower.Title = "Death Tower";
DeathTower.Price = 200;
DeathTower.SpecialEffect = SpecialEffects.Death;
DeathTower.Levels = [new Level(200, 0, 0, 120, 0, 0, 0)];
DeathTower.HasTargeting = false;
}
}//package TowerDefence.Towers
Section 254
//ClickZone (TowerDefence.ClickZone)
package TowerDefence {
import TowerDefence.Towers.*;
import TowerDefence.Monsters.*;
import TowerDefence.Buildings.*;
public class ClickZone {
private var Tower:Tower;
public var Zone:SimpleRectangle;
public var Click:Function;
private var Monster:Monster;
private var Building:Building;
private var Element:Object;
private static var Container:Array = new Array();
private static var Pool:Array = new Array();
private static var CurrentZone:ClickZone;
private static var MouseLocation:SimplePoint;
public static function Remove(_arg1:ClickZone):void{
Container.splice(Container.indexOf(_arg1), 1);
_arg1.Tower = null;
_arg1.Monster = null;
_arg1.Building = null;
Pool.push(_arg1);
}
private static function GetInstance():ClickZone{
if (Pool.length > 0){
return (Pool.pop());
};
return (new (ClickZone));
}
public static function CheckIfClicked():Boolean{
var _local1:int;
MouseLocation = Game.MouseLocation;
_local1 = 0;
while (_local1 < Container.length) {
CurrentZone = Container[_local1];
if (SimpleRectangle.ContainsPoint(CurrentZone.Zone, MouseLocation)){
CurrentZone.Click();
return (true);
};
_local1++;
};
return (false);
}
public static function Create(_arg1:SimpleRectangle, _arg2:Function, _arg3:Boolean=true):ClickZone{
var _local4:ClickZone;
_local4 = GetInstance();
_local4.Zone = _arg1;
_local4.Click = _arg2;
if (_arg3){
Container.push(_local4);
};
return (_local4);
}
}
}//package TowerDefence
Section 255
//Cookie (TowerDefence.Cookie)
package TowerDefence {
import flash.net.*;
public class Cookie {
private static const Cookie:SharedObject = SharedObject.getLocal("tdsave");
private static function GetDifficulty(_arg1:int=-1):String{
if (_arg1 == -1){
_arg1 = Game.Difficulty;
};
switch (_arg1){
case 0:
return ("Easy");
case 1:
return ("");
case 2:
default:
return ("Hard");
};
}
public static function SetPersonalBest():void{
var _local1:String;
var _local2:String;
var _local3:int;
_local1 = GetDifficulty();
_local2 = ("Level" + Game.LevelNumber);
if (Cookie.data[((_local2 + "LivesRemaining") + _local1)] != undefined){
_local3 = int(Cookie.data[(_local2 + "LivesRemaining")]);
if (_local3 < Statistics.Lives){
Cookie.data[((_local2 + "LivesRemaining") + _local1)] = String(Statistics.Lives);
};
} else {
Cookie.data[((_local2 + "LivesRemaining") + _local1)] = String(Statistics.Lives);
};
Cookie.flush();
}
public static function GetPersonalBest(_arg1:int):Array{
var _local2:Array;
var _local3:String;
var _local4:String;
var _local5:int;
_local2 = new Array(3);
_local3 = (("Level" + _arg1) + "LivesRemaining");
_local5 = 0;
while (_local5 < 3) {
_local4 = GetDifficulty(_local5);
if (Cookie.data[(_local3 + _local4)] != undefined){
_local2[_local5] = String(Cookie.data[(_local3 + _local4)]);
} else {
_local2[_local5] = "--";
};
_local5++;
};
return (_local2);
}
public static function GetSavedLevelNumber():int{
var _local1:String;
var _local2:String;
var _local3:int;
_local1 = GetDifficulty();
_local2 = ("Level" + _local1);
if (Cookie.data[_local2] != undefined){
_local3 = int(Cookie.data[_local2]);
} else {
_local3 = 1;
};
return (_local3);
}
public static function DeletePersonalBest(_arg1:int):void{
var _local2:String;
var _local3:String;
_local3 = (("Level" + _arg1) + "LivesRemaining");
_arg1 = 0;
while (_arg1 < 8) {
Cookie.data[(("Level" + _arg1) + "LivesRemaining")] = null;
Cookie.data[(("Level" + _arg1) + "LivesRemainingEasy")] = null;
Cookie.data[(("Level" + _arg1) + "LivesRemainingHard")] = null;
_arg1++;
};
Cookie.flush();
}
public static function SetSavedLevelNumber():void{
var _local1:String;
var _local2:String;
var _local3:int;
_local1 = GetDifficulty();
_local2 = ("Level" + _local1);
if (Cookie.data[_local2] != undefined){
_local3 = int(Cookie.data[_local2]);
if (_local3 <= Game.LevelNumber){
Cookie.data[_local2] = String(Game.LevelNumber);
};
} else {
Cookie.data[_local2] = String(Game.LevelNumber);
};
Cookie.flush();
}
}
}//package TowerDefence
Section 256
//FadingText (TowerDefence.FadingText)
package TowerDefence {
import flash.display.*;
import flash.geom.*;
import flash.text.*;
import flash.filters.*;
public class FadingText {
private var Position:SimplePoint;
private var CountDown:int;// = 0
private var OpacityArray:Array;
private var Message:String;
private var MPosition:Matrix;
private static const ZeroPoint:Point = new Point(0, 0);
private static const Opacity:ColorMatrixFilter = new ColorMatrixFilter();
private static const Text:TextField = new TextField();
private static const LabelFormat:TextFormat = new TextFormat();
private static const TextPosition:Matrix = new Matrix(1, 0, 0, 1, 0, 0);
private static var Container:Array = new Array();
private static var CurrentTextBlock:FadingText;
private static var Pool:Array = new Array();
private static var TempImage:BitmapData = new BitmapData(50, 20, true, 0xFFFFFF);
public function FadingText(){
OpacityArray = [1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0];
MPosition = new Matrix(1, 0, 0, 1, 0, 0);
CountDown = 0;
Position = new SimplePoint();
super();
}
public static function Create(_arg1:String, _arg2:int, _arg3:int):void{
var _local4:FadingText;
if (Game.LowGraphicsMode){
return;
};
_local4 = GetInstance();
_local4.Message = _arg1;
_local4.Position.X = _arg2;
_local4.Position.Y = _arg3;
_local4.OpacityArray[18] = 1;
_local4.CountDown = 40;
Container.push(_local4);
}
public static function Tick(_arg1:BitmapData):void{
var _local2:int;
if (((Game.LowGraphicsMode) || ((Container.length == 0)))){
return;
};
TempImage.floodFill(0, 0, 0xFFFFFF);
_local2 = (Container.length - 1);
while (_local2 > -1) {
CurrentTextBlock = Container[_local2];
CurrentTextBlock.CountDown--;
if (CurrentTextBlock.CountDown == 0){
Container.splice(_local2, 1);
Pool.push(CurrentTextBlock);
} else {
if (CurrentTextBlock.CountDown < 33){
CurrentTextBlock.Position.Y--;
CurrentTextBlock.OpacityArray[18] = (CurrentTextBlock.OpacityArray[18] - 0.03);
};
Text.text = CurrentTextBlock.Message;
Opacity.matrix = CurrentTextBlock.OpacityArray;
CurrentTextBlock.MPosition.tx = (CurrentTextBlock.Position.X - Game.MapRectangle.x);
CurrentTextBlock.MPosition.ty = (CurrentTextBlock.Position.Y - Game.MapRectangle.y);
TempImage.fillRect(_arg1.rect, 0xFFFFFF);
TempImage.draw(Text, TextPosition);
TempImage.applyFilter(TempImage, TempImage.rect, ZeroPoint, Opacity);
if (Maths.WithinVisibleArea(CurrentTextBlock.MPosition.tx, CurrentTextBlock.MPosition.ty, _arg1.width, _arg1.height)){
_arg1.draw(TempImage, CurrentTextBlock.MPosition);
};
};
_local2--;
};
}
private static function GetInstance():FadingText{
if (Pool.length > 0){
return (Pool.pop());
};
return (new (FadingText));
}
LabelFormat.font = "Arial";
LabelFormat.size = 11;
LabelFormat.bold = true;
LabelFormat.color = 0xFFCC00;
Text.defaultTextFormat = LabelFormat;
Text.autoSize = TextFieldAutoSize.LEFT;
}
}//package TowerDefence
Section 257
//Game (TowerDefence.Game)
package TowerDefence {
import TowerDefence.Towers.*;
import flash.display.*;
import TowerDefence.Monsters.*;
import TowerDefence.Buildings.*;
import TowerDefence.Levels.*;
import flash.media.*;
import flash.geom.*;
import flash.events.*;
import TowerDefence.Interface.*;
import TowerDefence.Languages.*;
import SWFStats.*;
import mochi.as3.*;
import flash.text.*;
import Assets.*;
import TowerDefence.Screens.*;
import flash.net.*;
import flash.ui.*;
public class Game extends MovieClip {
public var Percent:TextField;
public var MaxGamesButton:SimpleButton;
public static const ScrollUpLimit:int = 0;
public static const Height:int = 333;
public static const Levels:Array = new Array(8);
public static const MapRectangle:Rectangle = new Rectangle(0, 0, Width, Height);
public static const ScrollLeftLimit:int = 0;
public static const Width:int = 600;
public static const ZeroPoint:Point = new Point(0, 0);
private static const ZoomRectangle:Rectangle = new Rectangle(0, 0, Width, Height);
public static const BaseFrameRate:int = 30;
public static var RangeBonus:int = 0;
public static var ViewingTower:Tower;
public static var Playing:Boolean;
public static var PlacingBuildingType:BuildingConfig;
public static var Kongregate;
public static var ViewingMonster:Monster;
public static var ClickCatcher:Sprite;
public static var HasWorkshop:Boolean = false;
public static var LowGraphicsMode:Boolean = false;
public static var Locked:Boolean = true;
public static var PlayerName:String = "PLAYER";
public static var SoundOn:Boolean = true;
public static var CompletedWaves:int;
public static var ScrollRight:Boolean = false;
public static var GridLocation:SimplePoint = new SimplePoint();
public static var ScrollDown:Boolean = false;
public static var Image:Bitmap;
public static var ScrollingActive:Boolean = false;
public static var RoundNumber:int;
public static var MouseLocation:SimplePoint = new SimplePoint();
public static var PlacingTowerType:TowerConfig;
public static var AutoZooming:Boolean = false;
public static var Level:LevelData;
public static var FireBonus:int = 0;
public static var ScrollUp:Boolean = false;
public static var IceBonus:int = 0;
public static var Language:Language;
public static var MainBar:MainBar;
private static var RoundCompleted:Sound;
public static var MapClickZone:ClickZone = ClickZone.Create(new SimpleRectangle(0, 20, Width, Height), null, false);
public static var MapHeight:int;
public static var PlacingTower:Boolean;
public static var MapImage:BitmapData;
public static var MapWidthCells:int;
public static var MapPosition:Point = new Point(0, 0);
public static var CountingToNextRound:Boolean = false;
public static var ScrollLeft:Boolean = false;
public static var ResearchingTechnologyType:int = 0;
public static var MapHeightCells:int;
private static var StatusBar:StatusBar;
private static var RoundTicks:int;
public static var ResearchingImbueType:int = 0;
public static var ResearchingTechnology:Boolean = false;
public static var PlacingBuilding:Boolean;
public static var MusicOn:Boolean = true;
public static var HandCursor:Boolean = false;
public static var ResearchingImbue:Boolean = false;
private static var NextRoundTimer:NextRoundTimer;
public static var ViewableArea:BitmapData;
public static var LevelNumber:int;
private static var ZoomTo:Number;
public static var DamageBonus:int = 0;
public static var ViewingBuilding:Building;
public static var ScrollRightLimit:int;
public static var HasLaboratory:Boolean = false;
public static var Pause:Boolean = false;
public static var PoisonBonus:int = 0;
public static var Difficulty:int;
public static var STAGE:Stage;
public static var ScrollDownLimit:int;
public static var MapWidth:int;
public static var ShiftIsDown:Boolean;
public static var NextRoundTicks:int;
public function Game(){
var _local1:String;
super();
STAGE = stage;
STAGE.quality = StageQuality.LOW;
_local1 = loaderInfo.loaderURL;
loaderInfo.addEventListener(ProgressEvent.PROGRESS, ShowLoadProgress);
loaderInfo.addEventListener(Event.COMPLETE, Initialise);
Tracker.LogView(loaderInfo.loaderURL);
this.MaxGamesButton.addEventListener(MouseEvent.CLICK, MaxGames);
}
private function Initialise(_arg1:Event):void{
loaderInfo.removeEventListener(ProgressEvent.PROGRESS, ShowLoadProgress);
loaderInfo.removeEventListener(Event.COMPLETE, Initialise);
this.gotoAndStop(3);
Game.Language = Language.English;
MenuButton.Init();
MenuButton2.Init();
RoundCompleted = new RoundCompleted();
Research.Init();
SoundManager.Init();
Building.Init();
BuildingConfig.Init();
MainBar.Init();
AbilityIcons.Init();
RoundButton.Init();
NextRoundTimer.Init();
Map.Init();
MonsterConfig.Init();
GameWin.Init();
GameLose.Init();
LevelButton.Init();
Tower.Init();
TowerConfig.Init();
Image = new Bitmap();
Image.x = 0;
Image.y = 20;
STAGE.addChild(Image);
ClickCatcher = new Sprite();
ClickCatcher.x = 0;
ClickCatcher.y = 0;
ClickCatcher.buttonMode = true;
ClickCatcher.addEventListener(MouseEvent.CLICK, Click);
ClickCatcher.graphics.beginFill(0xFFFFFF, 0);
ClickCatcher.graphics.drawRect(0, 20, Width, Height);
ClickCatcher.graphics.endFill();
STAGE.addChild(ClickCatcher);
StatusBar = new StatusBar();
MainBar = new MainBar();
NextRoundTimer = new NextRoundTimer();
Difficulty = 1;
LevelNumber = Cookie.GetSavedLevelNumber();
STAGE.setChildIndex(MainBar, (STAGE.numChildren - 1));
STAGE.addEventListener(KeyboardEvent.KEY_DOWN, KeyDown);
STAGE.addEventListener(KeyboardEvent.KEY_UP, KeyUp);
STAGE.addEventListener(Event.ENTER_FRAME, GameTick);
STAGE.addEventListener(MouseEvent.MOUSE_MOVE, TrackMouse);
new MaxGames();
}
private function ShowLoadProgress(_arg1:ProgressEvent):void{
var _local2:Number;
var _local3:Number;
_local2 = loaderInfo.bytesLoaded;
_local3 = loaderInfo.bytesTotal;
this.Percent.text = (Math.round(((_local2 / _local3) * 100)) + "%");
}
public static function Lose():void{
KongregateAPI.SubmitHighScore();
RemoveAllElements();
Playing = false;
Locked = true;
CountingToNextRound = false;
new GameLose();
}
public static function StartNextRound():void{
Playing = false;
NextRoundTicks = (20 * BaseFrameRate);
CountingToNextRound = true;
RoundTicks = 0;
}
private static function KeyUp(_arg1:KeyboardEvent):void{
var _local2:ActionButton;
var _local3:int;
if (Locked){
return;
};
switch (_arg1.keyCode){
case Keyboard.SHIFT:
ShiftIsDown = false;
return;
case Keyboard.SPACE:
if (CountingToNextRound){
NextRoundTimer.EndCountDown();
};
return;
case Keyboard.LEFT:
case Keyboard.NUMPAD_4:
ScrollLeft = false;
return;
case Keyboard.RIGHT:
case Keyboard.NUMPAD_6:
ScrollRight = false;
return;
case Keyboard.UP:
case Keyboard.NUMPAD_8:
ScrollUp = false;
return;
case Keyboard.DOWN:
case Keyboard.NUMPAD_2:
ScrollDown = false;
return;
};
_local3 = 0;
while (_local3 < MainBar.ActiveMenu.length) {
_local2 = MainBar.ActiveMenu[_local3];
if (_arg1.keyCode == _local2.HotKey){
_local2.OnClick(_local2);
return;
};
_local3++;
};
}
private static function TrackMouse(_arg1:MouseEvent):void{
MouseLocation.X = (_arg1.stageX + MapRectangle.x);
MouseLocation.Y = (_arg1.stageY + MapRectangle.y);
GridLocation.X = Math.floor((MouseLocation.X / 40));
GridLocation.Y = Math.floor(((MouseLocation.Y - 20) / 40));
}
public static function StartLevel():void{
if (LevelNumber > 1){
Cookie.SetSavedLevelNumber();
};
RemoveAllElements();
if (Level != null){
Level.Dispose();
};
RoundNumber = 1;
CompletedWaves = 0;
Level = Levels[(LevelNumber - 1)]();
CountingToNextRound = false;
PlacingTower = false;
ViewingTower = null;
ViewingMonster = null;
ShiftIsDown = false;
ScrollingActive = false;
ScrollLeft = false;
ScrollRight = false;
ScrollUp = false;
ScrollDown = false;
HasWorkshop = false;
HasLaboratory = false;
STAGE.frameRate = BaseFrameRate;
LowGraphicsMode = false;
ViewingTower = null;
ViewingMonster = null;
ViewingBuilding = null;
PlacingTower = false;
PlacingTowerType = null;
PlacingBuilding = false;
PlacingBuildingType = null;
FireBonus = 0;
PoisonBonus = 0;
IceBonus = 0;
RangeBonus = 0;
DamageBonus = 0;
MapImage = Map.Draw(Level);
MapWidth = MapImage.width;
MapHeight = MapImage.height;
MapWidthCells = (MapImage.width / 40);
MapHeightCells = (MapImage.height / 40);
ScrollRightLimit = (MapWidth - Width);
ScrollDownLimit = (MapHeight - Height);
AutoZooming = true;
ZoomTo = (Width / MapWidth);
MapRectangle.x = 0;
MapRectangle.y = 0;
ClickCatcher.useHandCursor = false;
Maths.MapWidth = MapWidth;
Maths.MapHeight = MapHeight;
Maths.MapRectX = MapRectangle.x;
Maths.MapRectXW = (MapRectangle.x + MapRectangle.width);
Maths.MapRectY = MapRectangle.y;
Maths.MapRectYW = (MapRectangle.y + MapRectangle.height);
ViewableArea = new BitmapData(Width, Height, false);
ViewableArea.copyPixels(MapImage, MapRectangle, ZeroPoint);
MiniMap.MapRectangle = MapRectangle;
LevelData.LastPath = 0;
StatusBar.Refresh();
MainBar.OldGold = -1;
MainBar.MiniMap.Load(MapImage);
MainBar.RoundInfo.Refresh();
MainBar.RoundInfo.SetupRoundInfo();
MainBar.ShowBuildMenu();
MainBar.ShowRoundInfo();
Statistics.Gold = Level.StartingGold;
Statistics.MonsterKills.Monster4 = String(Level.StartingGold);
Statistics.TowerKills.Tower3 = Number(Level.StartingGold);
Statistics.MissilesFired.Missile2 = uint(Level.StartingGold);
Statistics.Lives = 50;
Statistics.MonsterKills.Monster6 = String(Statistics.Lives);
Statistics.TowerKills.Tower5 = Number(Statistics.Lives);
Statistics.MissilesFired.Missile4 = uint(Statistics.Lives);
Locked = false;
Pause = false;
StartNextRound();
}
private static function Click(_arg1:MouseEvent):void{
var _local2:Boolean;
_local2 = SimpleRectangle.ContainsPoint(MapClickZone.Zone, MouseLocation);
if (((PlacingTower) && (_local2))){
MapClickZone.Click();
return;
};
if (((PlacingBuilding) && (_local2))){
MapClickZone.Click();
return;
};
if (ClickZone.CheckIfClicked()){
return;
};
if (ViewingTower != null){
ViewingTower = null;
MainBar.ShowBuildMenu();
MainBar.ShowRoundInfo();
} else {
if (ViewingMonster != null){
ViewingMonster = null;
MainBar.ShowBuildMenu();
MainBar.ShowRoundInfo();
} else {
if (ViewingBuilding != null){
ViewingBuilding = null;
MainBar.ShowBuildMenu();
MainBar.ShowRoundInfo();
};
};
};
}
private static function RemoveAllElements():void{
Tower.RemoveAll();
Missile.RemoveAll();
Monster.RemoveAll();
Building.RemoveAll();
}
private static function KeyDown(_arg1:KeyboardEvent):void{
if (Locked){
return;
};
switch (_arg1.keyCode){
case Keyboard.SHIFT:
ShiftIsDown = true;
return;
case Keyboard.ESCAPE:
ShiftIsDown = false;
BuildButton.StopPlacingTower();
return;
case Keyboard.LEFT:
case Keyboard.NUMPAD_4:
ScrollLeft = true;
return;
case Keyboard.RIGHT:
case Keyboard.NUMPAD_6:
ScrollRight = true;
return;
case Keyboard.UP:
case Keyboard.NUMPAD_8:
ScrollUp = true;
return;
case Keyboard.DOWN:
case Keyboard.NUMPAD_2:
ScrollDown = true;
return;
};
}
private static function APILoaded(_arg1:Event):void{
}
private static function Win():void{
RemoveAllElements();
Playing = false;
CountingToNextRound = false;
new GameWin();
}
private static function GameTick(_arg1:Event):void{
var _local2:BitmapData;
var _local3:Matrix;
var _local4:BitmapData;
var _local5:BitmapData;
var _local6:Array;
var _local7:Wave;
var _local8:int;
var _local9:int;
var _local10:int;
if (((Pause) || (Locked))){
return;
};
if (Statistics.Refresh() == false){
Lose();
return;
};
if (AutoZooming){
_local3 = new Matrix();
_local3.scale(ZoomTo, ZoomTo);
_local4 = MapImage.clone();
LayeredElement.DrawAllMapElements(_local4);
LayeredElement.Tick(_local4);
_local5 = new BitmapData(Math.ceil((MapWidth * ZoomTo)), Math.ceil((MapHeight * ZoomTo)), false);
_local5.draw(_local4, _local3, null, null);
ZoomRectangle.x = Math.ceil(((_local5.width / 2) - (Width / 2)));
ZoomRectangle.y = Math.ceil(((_local5.height / 2) - (Height / 2)));
Image.bitmapData = _local5;
Image.scrollRect = ZoomRectangle;
ZoomTo = (ZoomTo + 0.01);
if (ZoomTo < 1){
return;
};
AutoZooming = false;
Image.scrollRect = null;
MapRectangle.x = ((MapWidth / 2) - (Width / 2));
MapRectangle.y = ((MapHeight / 2) - (Height / 2));
LayeredElement.GetMapElements();
Maths.MapRectX = MapRectangle.x;
Maths.MapRectXW = (MapRectangle.x + MapRectangle.width);
Maths.MapRectY = MapRectangle.y;
Maths.MapRectYW = (MapRectangle.y + MapRectangle.height);
MapClickZone.Zone.X = MapRectangle.x;
MapClickZone.Zone.Y = MapRectangle.y;
ViewableArea.copyPixels(MapImage, MapRectangle, ZeroPoint);
};
if (((ScrollLeft) && ((MapRectangle.x > ScrollLeftLimit)))){
MapRectangle.x = (MapRectangle.x - 8);
if (MapRectangle.x < ScrollLeftLimit){
MapRectangle.x = ScrollLeftLimit;
};
Maths.MapRectX = MapRectangle.x;
Maths.MapRectXW = (MapRectangle.x + MapRectangle.width);
MapClickZone.Zone.X = MapRectangle.x;
MapClickZone.Zone.Y = MapRectangle.y;
MiniMap.MapRectangle = MapRectangle;
LayeredElement.GetMapElements();
ViewableArea.copyPixels(MapImage, MapRectangle, ZeroPoint);
} else {
if (((ScrollRight) && ((MapRectangle.x < ScrollRightLimit)))){
MapRectangle.x = (MapRectangle.x + 8);
if (MapRectangle.x > ScrollRightLimit){
MapRectangle.x = ScrollRightLimit;
};
Maths.MapRectX = MapRectangle.x;
Maths.MapRectXW = (MapRectangle.x + MapRectangle.width);
MapClickZone.Zone.X = MapRectangle.x;
MapClickZone.Zone.Y = MapRectangle.y;
MiniMap.MapRectangle = MapRectangle;
LayeredElement.GetMapElements();
ViewableArea.copyPixels(MapImage, MapRectangle, ZeroPoint);
};
};
if (((ScrollUp) && ((MapRectangle.y > ScrollUpLimit)))){
MapRectangle.y = (MapRectangle.y - 8);
if (MapRectangle.y < ScrollUpLimit){
MapRectangle.y = ScrollUpLimit;
};
Maths.MapRectY = MapRectangle.y;
Maths.MapRectYW = (MapRectangle.y + MapRectangle.height);
MapClickZone.Zone.X = MapRectangle.x;
MapClickZone.Zone.Y = MapRectangle.y;
MiniMap.MapRectangle = MapRectangle;
LayeredElement.GetMapElements();
ViewableArea.copyPixels(MapImage, MapRectangle, ZeroPoint);
} else {
if (((ScrollDown) && ((MapRectangle.y < ScrollDownLimit)))){
MapRectangle.y = (MapRectangle.y + 8);
if (MapRectangle.y > ScrollDownLimit){
MapRectangle.y = ScrollDownLimit;
};
Maths.MapRectY = MapRectangle.y;
Maths.MapRectYW = (MapRectangle.y + MapRectangle.height);
MapClickZone.Zone.X = MapRectangle.x;
MapClickZone.Zone.Y = MapRectangle.y;
MiniMap.MapRectangle = MapRectangle;
LayeredElement.GetMapElements();
ViewableArea.copyPixels(MapImage, MapRectangle, ZeroPoint);
};
};
HandCursor = false;
_local2 = ViewableArea.clone();
PlacingOverlay.Tick(_local2);
StatusBar.Refresh();
Maths.GenerateRandom();
MainBar.MiniMap.Refresh();
MainBar.Refresh();
NextRoundTimer.Refresh();
Monster.Tick(_local2);
Tower.Tick(_local2);
Building.Tick(_local2);
Research.Tick();
Missile.Tick(_local2);
LayeredElement.Tick(_local2);
FadingText.Tick(_local2);
Message.Draw(_local2);
Image.bitmapData = _local2;
ClickCatcher.useHandCursor = HandCursor;
if (Playing){
if ((((CompletedWaves == Level.Rounds[(RoundNumber - 1)].Waves.length)) && ((Monster.Container.length == 0)))){
SoundManager.PlaySound(RoundCompleted);
if (RoundNumber < Level.Rounds.length){
Missile.RemoveAll();
RoundNumber++;
CompletedWaves = 0;
Game.MainBar.RoundInfo.Refresh();
StartNextRound();
_local9 = ((Statistics.Gold + Statistics.Kills) + Statistics.Lives);
Statistics.Points = (Statistics.Points + _local9);
Statistics.MonsterKills.Monster7 = String((int(Statistics.MonsterKills.Monster7) + _local9));
Statistics.TowerKills.Tower6 = Number((int(Statistics.TowerKills.Tower6) + _local9));
Statistics.MissilesFired.Missile6 = uint((int(Statistics.MissilesFired.Missile6) + _local9));
if (Difficulty < 2){
if (Statistics.PreviousLives == Statistics.Lives){
Statistics.Gold = (Statistics.Gold + 10);
Statistics.MonsterKills.Monster4 = String((int(Statistics.MonsterKills.Monster4) + 10));
Statistics.TowerKills.Tower3 = Number((int(Statistics.TowerKills.Tower3) + 10));
Statistics.MissilesFired.Missile2 = uint((int(Statistics.MissilesFired.Missile2) + 10));
Message.SetMessage((Language.GreatRoundBonus + " $10!"));
} else {
if ((Statistics.PreviousLives - Statistics.Lives) <= 5){
Statistics.Gold = (Statistics.Gold + 5);
Statistics.MonsterKills.Monster4 = String((int(Statistics.MonsterKills.Monster4) + 5));
Statistics.TowerKills.Tower3 = Number((int(Statistics.TowerKills.Tower3) + 5));
Statistics.MissilesFired.Missile2 = uint((int(Statistics.MissilesFired.Missile2) + 5));
Message.SetMessage((Language.GoodRoundBonus + " $5!"));
};
};
};
} else {
Playing = false;
Cookie.SetPersonalBest();
if (Statistics.Lives == 50){
KongregateAPI.PerfectRound();
};
KongregateAPI.LivesRemaining();
if (LevelNumber == Levels.length){
_local10 = ((Statistics.Gold + Statistics.Kills) + Statistics.Lives);
Statistics.Points = (Statistics.Points + _local10);
Statistics.MonsterKills.Monster7 = String((int(Statistics.MonsterKills.Monster7) + _local10));
Statistics.TowerKills.Tower6 = Number((int(Statistics.TowerKills.Tower6) + _local10));
Statistics.MissilesFired.Missile6 = uint((int(Statistics.MissilesFired.Missile6) + _local10));
KongregateAPI.SubmitHighScore();
KongregateAPI.WonGame();
Win();
} else {
LevelNumber++;
Cookie.SetSavedLevelNumber();
new Intermission();
};
};
return;
};
_local6 = Level.Rounds[(RoundNumber - 1)].Waves;
_local8 = (_local6.length - 1);
while (_local8 > -1) {
_local7 = _local6[_local8];
if (RoundTicks >= _local7.StartAt){
if ((((_local7.Ticks == _local7.Interval)) && ((_local7.Quantity > 0)))){
_local7.Ticks = 0;
_local7.Quantity--;
Monster.Create(_local7.Monster);
} else {
if ((((_local7.Quantity == 0)) && ((Monster.Container.length == 0)))){
CompletedWaves++;
MainBar.RoundInfo.Refresh();
return;
};
};
_local7.Ticks++;
};
_local8--;
};
RoundTicks++;
};
}
private static function MaxGames(_arg1:MouseEvent):void{
navigateToURL(new URLRequest("http://www.maxgames.com/"), "_blank");
}
private static function ShowIntermission():void{
new Intermission();
Locked = true;
Playing = false;
CountingToNextRound = false;
}
}
}//package TowerDefence
Section 258
//KongregateAPI (TowerDefence.KongregateAPI)
package TowerDefence {
import SWFStats.*;
public class KongregateAPI {
private static function GetDifficulty():String{
switch (Game.Difficulty){
case 0:
return ("Easy");
case 1:
return ("");
case 2:
default:
return ("Hard");
};
}
public static function PerfectRound():void{
var _local1:String;
var _local2:String;
_local1 = GetDifficulty();
_local2 = ("Level" + Game.LevelNumber);
Submit(((_local2 + "PerfectRound") + _local1), 1);
}
public static function SubmitHighScore():void{
var _local1:String;
_local1 = GetDifficulty();
switch (_local1){
case "Easy":
HighScores.Submit(Game.PlayerName, Statistics.Points, HighScores.EASY);
break;
case "":
HighScores.Submit(Game.PlayerName, Statistics.Points, HighScores.MEDIUM);
break;
case "Hard":
HighScores.Submit(Game.PlayerName, Statistics.Points, HighScores.HARD);
break;
};
}
public static function WonGame():void{
var _local1:String;
_local1 = GetDifficulty();
Submit(("GameComplete" + _local1), 1);
}
public static function SubmitLevelKills():void{
var _local1:String;
if (Game.LevelNumber < 1){
return;
};
_local1 = GetDifficulty();
Submit((("Level" + Game.LevelNumber) + _local1), Statistics.Lives);
}
private static function Submit(_arg1:String, _arg2:int):void{
var key = _arg1;
var value = _arg2;
if (value <= 0){
return;
};
try {
Game.Kongregate.submit(key, value);
} catch(e:Error) {
};
}
public static function SubmitKills():void{
if (Statistics.Kills <= 1){
return;
};
try {
Game.Kongregate.scores.submit(Statistics.Kills);
} catch(e:Error) {
};
}
public static function LivesRemaining():void{
var _local1:String;
var _local2:String;
_local1 = GetDifficulty();
_local2 = ("Level" + Game.LevelNumber);
Submit(((_local2 + "LivesRemaining") + _local1), Statistics.Lives);
}
}
}//package TowerDefence
Section 259
//LayeredElement (TowerDefence.LayeredElement)
package TowerDefence {
import flash.display.*;
import flash.geom.*;
public class LayeredElement {
public var Position:Point;
public var Locked:Boolean;
public var Image:BitmapData;
private static var RelativeLocation:Point = new Point();
private static var Map:Array;
private static var Position:SimplePoint = new SimplePoint();
private static var Positions:Array;
private static var PartialRectangle:Rectangle = new Rectangle();
private static var MapY:int;
private static var CurrentElement:LayeredElement;
private static var TempElement:LayeredElement;
public static var Layers:Array = new Array();
private static var PartialPosition:Point = new Point();
private static var MapX:int;
private static var Pool:Array = new Array();
public function LayeredElement(){
Position = new Point();
super();
}
public static function CreateMapElement(_arg1:BitmapData, _arg2:Point, _arg3:int):void{
var _local4:LayeredElement;
if (_arg3 < 0){
return;
};
_local4 = GetInstance();
_local4.Position.x = _arg2.x;
_local4.Position.y = _arg2.y;
_local4.Image = _arg1;
_local4.Locked = true;
Layers[_arg3].push(_local4);
}
public static function DrawAllMapElements(_arg1:BitmapData):void{
var _local2:int;
var _local3:int;
var _local4:Point;
_local2 = 0;
while (_local2 < Map.length) {
_local3 = 0;
while (_local3 < Map[0].length) {
if (Map[_local2][_local3] != null){
_local4 = new Point();
_local4.x = (_local3 * 40);
_local4.y = (_local2 * 40);
_arg1.copyPixels(Game.Level.Tiles[Map[_local2][_local3]], Game.Level.Tiles[Map[_local2][_local3]].rect, _local4);
};
_local3++;
};
_local2++;
};
}
private static function Dispose(_arg1:LayeredElement):void{
Pool.push(_arg1);
}
public static function SetLayers(_arg1:int, _arg2:Array=null):void{
var _local3:int;
var _local4:int;
var _local5:int;
if (Layers.length > 0){
_local4 = (Layers.length - 1);
while (_local4 > -1) {
_local3 = (Layers[_local4].length - 1);
while (_local3 > -1) {
CurrentElement = Layers[_local4][_local3];
Pool.push(CurrentElement);
_local3--;
};
_local4--;
};
};
_arg1 = (_arg1 + 1);
Layers = new Array(_arg1);
if (_arg2 != null){
Map = _arg2;
Positions = new Array(Map.length);
_local5 = Map[0].length;
_local4 = 0;
while (_local4 < Map.length) {
Positions[_local4] = new Array(_local5);
_local3 = 0;
while (_local3 < _local5) {
if (Map[_local4][_local3] != null){
Positions[_local4][_local3] = new SimplePoint((_local3 * 40), (_local4 * 40));
};
_local3++;
};
_local4++;
};
};
_local4 = 0;
while (_local4 < _arg1) {
Layers[_local4] = new Array();
_local4++;
};
}
public static function GetMapElements():void{
var _local1:int;
var _local2:int;
var _local3:int;
var _local4:int;
var _local5:int;
var _local6:int;
SetLayers((Layers.length - 1));
MapX = Game.MapRectangle.x;
MapY = Game.MapRectangle.y;
_local1 = (Math.floor((MapX / 40)) - 4);
_local2 = (Math.floor((MapY / 40)) - 4);
if (_local1 < 0){
_local1 = 0;
};
if (_local2 < 0){
_local2 = 0;
};
_local3 = (Math.ceil((MapX / 40)) + (Game.MapRectangle.width / 40));
_local4 = (Math.ceil((MapY / 40)) + (Game.MapRectangle.height / 40));
if (_local3 > Map[0].length){
_local3 = Map[0].length;
};
if (_local4 > Map.length){
_local4 = Map.length;
};
_local5 = _local2;
while (_local5 < _local4) {
_local6 = _local1;
while (_local6 < _local3) {
if (Map[_local5][_local6] != null){
Position = Positions[_local5][_local6];
RelativeLocation.x = (Position.X - MapX);
RelativeLocation.y = (Position.Y - MapY);
CreateMapElement(Game.Level.Tiles[Map[_local5][_local6]], RelativeLocation, _local5);
};
_local6++;
};
_local5++;
};
}
private static function GetInstance():LayeredElement{
if (Pool.length > 0){
return (Pool.pop());
};
return (new (LayeredElement));
}
public static function Create(_arg1:BitmapData, _arg2:Point, _arg3:int):void{
var _local4:LayeredElement;
if (_arg3 < 0){
return;
};
_local4 = GetInstance();
_local4.Position.x = _arg2.x;
_local4.Position.y = _arg2.y;
_local4.Locked = false;
_local4.Image = _arg1;
Layers[_arg3].push(_local4);
}
public static function CreateAtBack(_arg1:BitmapData, _arg2:Point, _arg3:int):void{
var _local4:LayeredElement;
if (_arg3 < 0){
return;
};
_local4 = GetInstance();
_local4.Position.x = _arg2.x;
_local4.Position.y = _arg2.y;
_local4.Locked = false;
_local4.Image = _arg1;
Layers[_arg3].splice(0, 0, _local4);
}
public static function Tick(_arg1:BitmapData):void{
var _local2:int;
var _local3:int;
_local2 = 0;
while (_local2 < Layers.length) {
if (Layers[_local2].length == 0){
} else {
_local3 = 0;
while (_local3 < Layers[_local2].length) {
CurrentElement = Layers[_local2][_local3];
_arg1.copyPixels(CurrentElement.Image, CurrentElement.Image.rect, CurrentElement.Position);
_local3++;
};
_local3 = (Layers[_local2].length - 1);
while (_local3 > -1) {
CurrentElement = Layers[_local2][_local3];
if (!CurrentElement.Locked){
Layers[_local2].splice(_local3, 1);
Dispose(CurrentElement);
};
_local3--;
};
};
_local2++;
};
}
}
}//package TowerDefence
Section 260
//Maths (TowerDefence.Maths)
package TowerDefence {
import flash.geom.*;
public class Maths {
private static const TempRectangle:Rectangle = new Rectangle();
public static var MapHeight:int;
public static var MapRectYW:int;
public static var MapWidth:int;
private static var RandomNumber:Number;
public static var MapRectX:int;
public static var MapRectY:int;
public static var MapRectXW:int;
public static function WithinVisibleArea(_arg1:int, _arg2:int, _arg3:int, _arg4:int):Boolean{
if (((((_arg1 + _arg3) < MapRectX)) || ((_arg1 > MapRectXW)))){
return (false);
};
if (((((_arg2 + _arg4) < MapRectY)) || ((_arg2 > MapRectYW)))){
return (false);
};
return (true);
}
public static function Random(_arg1:int, _arg2:int):int{
return ((Math.round((RandomNumber * _arg2)) + _arg1));
}
public static function WithinMap(_arg1:int, _arg2:int, _arg3:int, _arg4:int):Boolean{
if (((((_arg1 + _arg3) < 0)) || ((_arg1 > MapWidth)))){
return (false);
};
if (((((_arg2 + _arg4) < 0)) || ((_arg2 > MapHeight)))){
return (false);
};
return (true);
}
public static function GenerateRandom():void{
RandomNumber = Math.random();
}
}
}//package TowerDefence
Section 261
//PlacingOverlay (TowerDefence.PlacingOverlay)
package TowerDefence {
import TowerDefence.Towers.*;
import flash.display.*;
import flash.geom.*;
public class PlacingOverlay {
private static const ZeroPoint:Point = new Point(0, 0);
private static const CellLocation:Point = new Point();
private static const TempPoint:Point = new Point();
private static const RadiusPoint:Point = new Point();
private static var TempRange:int;
private static var TempRadiusImage:BitmapData;
private static function DrawTower(_arg1:BitmapData):void{
if (Game.Level.Buildable[Game.GridLocation.Y][Game.GridLocation.X] == false){
return;
};
Game.HandCursor = true;
CellLocation.x = (((Game.GridLocation.X * 40) - Game.MapRectangle.x) + 2);
CellLocation.y = (((Game.GridLocation.Y * 40) - Game.MapRectangle.y) + 2);
TempRange = Game.PlacingTowerType.Levels[0].Range;
TempRadiusImage = RadiusImage.Create(TempRange);
RadiusPoint.x = ((CellLocation.x + 18) - TempRange);
RadiusPoint.y = ((CellLocation.y + 12) - TempRange);
_arg1.copyPixels(TempRadiusImage, TempRadiusImage.rect, RadiusPoint);
TempPoint.x = (CellLocation.x - 2);
TempPoint.y = (CellLocation.y - 28);
if (Game.PlacingTowerType.Images != null){
_arg1.copyPixels(Game.PlacingTowerType.Images[0], Game.PlacingTowerType.Images[0].rect, TempPoint);
} else {
if (Game.PlacingTowerType.AnimationImages != null){
_arg1.copyPixels(Game.PlacingTowerType.AnimationImages[0], Game.PlacingTowerType.AnimationImages[0].rect, TempPoint);
} else {
_arg1.copyPixels(Game.PlacingTowerType.Image, Game.PlacingTowerType.Image.rect, TempPoint);
};
};
}
public static function Tick(_arg1:BitmapData):void{
if (((!(Game.PlacingTower)) && (!(Game.PlacingBuilding)))){
return;
};
if ((((Game.GridLocation.X < 0)) || ((Game.GridLocation.Y < 0)))){
return;
};
if (!SimpleRectangle.ContainsPoint(Game.MapClickZone.Zone, Game.MouseLocation)){
return;
};
if (Game.PlacingTower){
DrawTower(_arg1);
} else {
if (Game.PlacingBuilding){
DrawBuilding(_arg1);
};
};
}
private static function DrawBuilding(_arg1:BitmapData):void{
var _local2:int;
var _local3:int;
_local2 = Game.GridLocation.X;
while (_local2 < (Game.GridLocation.X + Game.PlacingBuildingType.Width)) {
_local3 = Game.GridLocation.Y;
while (_local3 < (Game.GridLocation.Y + Game.PlacingBuildingType.Height)) {
if (Game.Level.Buildable[_local3][_local2] == false){
return;
};
_local3++;
};
_local2++;
};
Game.HandCursor = true;
TempPoint.x = ((Game.GridLocation.X * 40) - Game.MapRectangle.x);
TempPoint.y = (((Game.GridLocation.Y * 40) - Game.MapRectangle.y) - (Game.PlacingBuildingType.Image.height - 80));
_arg1.copyPixels(Game.PlacingBuildingType.Image, Game.PlacingBuildingType.Image.rect, TempPoint);
}
}
}//package TowerDefence
Section 262
//Research (TowerDefence.Research)
package TowerDefence {
import TowerDefence.Buildings.*;
import flash.media.*;
import Assets.Towers.*;
public class Research {
public static var ImbueClock:int;
public static var TechnologyType:int;
public static var ImbueType:int;
public static var TechnologyClock:int;
private static var UpgradeComplete:Sound;
private static function ImbueTick():void{
ImbueClock++;
if (((!((Game.ViewingBuilding == null))) && ((Game.ViewingBuilding.Config.Title == "Laboratory")))){
Game.MainBar.ShowBuildingInfo();
Game.MainBar.Researching.Bar.width = int(((ImbueClock / ImbueUpgrades.Ticks) * 228));
};
if (ImbueClock < ImbueUpgrades.Ticks){
return;
};
Game.ResearchingImbue = false;
switch (ImbueType){
case ImbueUpgrades.Fire:
Game.FireBonus = (Game.FireBonus + ImbueUpgrades.Bonus);
break;
case ImbueUpgrades.Ice:
Game.IceBonus = (Game.IceBonus + ImbueUpgrades.Bonus);
break;
case ImbueUpgrades.Poison:
Game.PoisonBonus = (Game.PoisonBonus + ImbueUpgrades.Bonus);
break;
};
if (((!((Game.ViewingBuilding == null))) && ((Game.ViewingBuilding.Config.Title == "Laboratory")))){
Game.MainBar.ShowBuildingInfo();
Game.MainBar.LaboratoryInfo.Refresh();
};
SoundManager.PlaySound(UpgradeComplete);
}
public static function Init():void{
UpgradeComplete = new UpgradeComplete();
}
private static function TechnologyTick():void{
TechnologyClock++;
if (((!((Game.ViewingBuilding == null))) && ((Game.ViewingBuilding.Config.Title == "Workshop")))){
Game.MainBar.ShowBuildingInfo();
Game.MainBar.Researching.Bar.width = int(((TechnologyClock / TechnologyUpgrades.Ticks) * 228));
};
if (TechnologyClock < TechnologyUpgrades.Ticks){
return;
};
Game.ResearchingTechnology = false;
switch (TechnologyType){
case TechnologyUpgrades.Range:
Game.RangeBonus = (Game.RangeBonus + TechnologyUpgrades.Bonus);
break;
case TechnologyUpgrades.Damage:
Game.DamageBonus = (Game.DamageBonus + TechnologyUpgrades.Bonus);
break;
};
if (((!((Game.ViewingBuilding == null))) && ((Game.ViewingBuilding.Config.Title == "Workshop")))){
Game.MainBar.ShowBuildingInfo();
Game.MainBar.WorkshopInfo.Refresh();
};
SoundManager.PlaySound(UpgradeComplete);
}
public static function Tick():void{
if (Game.ResearchingImbue){
ImbueTick();
};
if (Game.ResearchingTechnology){
TechnologyTick();
};
}
}
}//package TowerDefence
Section 263
//SimplePoint (TowerDefence.SimplePoint)
package TowerDefence {
public class SimplePoint {
public var X:Number;
public var Y:Number;
private static var Cache0:Array;
private static var Cache1:Array;
private static var Cache2:Array;
private static var Cache3:Array;
private static var Cache4:Array;
private static var Cache5:Array;
private static var Cache6:Array;
private static var Cache7:Array;
private static var TempY:int;
private static var TempX:int;
private static var Sum:int;
public function SimplePoint(_arg1:Number=0, _arg2:Number=0){
this.X = _arg1;
this.Y = _arg2;
}
public static function Distance(_arg1:SimplePoint, _arg2:SimplePoint):Number{
TempX = (_arg2.X - _arg1.X);
TempY = (_arg2.Y - _arg1.Y);
Sum = ((TempX * TempX) + (TempY * TempY));
if (Sum > 7999){
return (Math.sqrt(Sum));
};
if (Sum < 1000){
return (Cache0[Sum]);
};
if (Sum < 2000){
return (Cache1[(Sum - 1000)]);
};
if (Sum < 3000){
return (Cache2[(Sum - 2000)]);
};
if (Sum < 4000){
return (Cache3[(Sum - 3000)]);
};
if (Sum < 5000){
return (Cache4[(Sum - 4000)]);
};
if (Sum < 6000){
return (Cache5[(Sum - 5000)]);
};
if (Sum < 7000){
return (Cache6[(Sum - 6000)]);
};
return (Cache7[(Sum - 7000)]);
}
public static function Equal(_arg1:SimplePoint, _arg2:SimplePoint):Boolean{
if (_arg1.X != _arg2.X){
return (false);
};
if (_arg1.Y != _arg2.Y){
return (false);
};
return (true);
}
private static function PreCalculateDistances():void{
var _local1:int;
Cache0 = new Array(1000);
Cache1 = new Array(1000);
Cache2 = new Array(1000);
Cache3 = new Array(1000);
Cache4 = new Array(1000);
Cache5 = new Array(1000);
Cache6 = new Array(1000);
Cache7 = new Array(1000);
_local1 = 0;
while (_local1 < 1000) {
Cache0[_local1] = Math.sqrt(_local1);
Cache1[_local1] = Math.sqrt((1000 + _local1));
Cache2[_local1] = Math.sqrt((2000 + _local1));
Cache3[_local1] = Math.sqrt((3000 + _local1));
Cache4[_local1] = Math.sqrt((4000 + _local1));
Cache5[_local1] = Math.sqrt((5000 + _local1));
Cache6[_local1] = Math.sqrt((6000 + _local1));
Cache7[_local1] = Math.sqrt((7000 + _local1));
_local1++;
};
}
PreCalculateDistances();
}
}//package TowerDefence
Section 264
//SimpleRectangle (TowerDefence.SimpleRectangle)
package TowerDefence {
public class SimpleRectangle {
public var Width:int;
public var Height:int;
public var X:Number;
public var Y:Number;
public function SimpleRectangle(_arg1:int=0, _arg2:int=0, _arg3:int=0, _arg4:int=0){
this.X = _arg1;
this.Y = _arg2;
this.Width = _arg3;
this.Height = _arg4;
}
public static function ContainsPoint(_arg1:SimpleRectangle, _arg2:SimplePoint):Boolean{
if (_arg2.X < _arg1.X){
return (false);
};
if (_arg2.X > (_arg1.X + _arg1.Width)){
return (false);
};
if (_arg2.Y < _arg1.Y){
return (false);
};
if (_arg2.Y > (_arg1.Y + _arg1.Height)){
return (false);
};
return (true);
}
}
}//package TowerDefence
Section 265
//SoundManager (TowerDefence.SoundManager)
package TowerDefence {
import flash.media.*;
import flash.events.*;
import Assets.*;
public class SoundManager {
private static const FreeTowerChannels:Array = new Array(6);
private static const TowerChannels:Array = new Array(6);
private static const FreeMonsterChannels:Array = new Array(6);
private static const MonsterChannels:Array = new Array(6);
private static const Volume:SoundTransform = new SoundTransform(0.6);
private static var GeneralChannel:SoundChannel = new SoundChannel();
private static var Channel:int;
private static var i:int;
private static var Theme:Sound;
private static var MusicChannel:SoundChannel = new SoundChannel();
public static function PlayTowerSound(_arg1:Sound):void{
var sound = _arg1;
if (!Game.SoundOn){
return;
};
Channel = GetFreeTowerChannel();
if (Channel == -1){
return;
};
TowerChannels[Channel] = sound.play(0, 0);
TowerChannels[Channel].addEventListener(Event.SOUND_COMPLETE, function (){
FreeTowerChannels[Channel] = true;
});
FreeTowerChannels[Channel] = false;
}
public static function StartMusic():void{
MusicChannel = Theme.play();
}
public static function PlayMonsterSound(_arg1:Sound):void{
var sound = _arg1;
if (!Game.SoundOn){
return;
};
Channel = GetFreeMonsterChannel();
MonsterChannels[Channel] = sound.play(0, 0);
MonsterChannels[Channel].addEventListener(Event.SOUND_COMPLETE, function (){
FreeMonsterChannels[Channel] = true;
});
FreeMonsterChannels[Channel] = false;
}
private static function GetFreeTowerChannel():int{
i = 0;
while (i < 6) {
if (FreeTowerChannels[i] == true){
return (i);
};
i++;
};
return (-1);
}
private static function GetFreeMonsterChannel():int{
i = 0;
while (i < 6) {
if (FreeMonsterChannels[i] == true){
return (i);
};
i++;
};
return (-1);
}
public static function PlaySound(_arg1:Sound):void{
if (!Game.SoundOn){
return;
};
GeneralChannel = _arg1.play(0, 0);
}
public static function Init():void{
Theme = new Theme();
}
public static function StopMusic():void{
MusicChannel.stop();
}
TowerChannels[0] = new SoundChannel();
TowerChannels[1] = new SoundChannel();
TowerChannels[2] = new SoundChannel();
TowerChannels[3] = new SoundChannel();
TowerChannels[4] = new SoundChannel();
TowerChannels[5] = new SoundChannel();
FreeTowerChannels[0] = true;
FreeTowerChannels[1] = true;
FreeTowerChannels[2] = true;
FreeTowerChannels[3] = true;
FreeTowerChannels[4] = true;
FreeTowerChannels[5] = true;
MonsterChannels[0] = new SoundChannel();
MonsterChannels[1] = new SoundChannel();
MonsterChannels[2] = new SoundChannel();
MonsterChannels[3] = new SoundChannel();
MonsterChannels[4] = new SoundChannel();
MonsterChannels[5] = new SoundChannel();
FreeMonsterChannels[0] = true;
FreeMonsterChannels[1] = true;
FreeMonsterChannels[2] = true;
FreeMonsterChannels[3] = true;
FreeMonsterChannels[4] = true;
FreeMonsterChannels[5] = true;
}
}//package TowerDefence
Section 266
//Statistics (TowerDefence.Statistics)
package TowerDefence {
public class Statistics {
public static var Gold:int = 0;
public static var MissilesFired:Object = new Object();
public static var Points:int = 0;
public static var Lives:int = 0;
public static var TowerKills:Object = new Object();
public static var PreviousLives:int = 0;
public static var Kills:int = 0;
public static var RoundMessages:Object = new Object();
public static var MonsterKills:Object = new Object();
private static function UpdateMonsterKills():Boolean{
return ((((((MonsterKills.Monster2 == String(Kills))) && ((MonsterKills.Monster4 == String(Gold))))) && ((MonsterKills.Monster6 == String(Lives)))));
}
private static function GetMissilesFired():Boolean{
return ((((((MissilesFired.Missile1 == uint(Kills))) && ((MissilesFired.Missile2 == uint(Gold))))) && ((MissilesFired.Missile4 == uint(Lives)))));
}
private static function RefreshTowerKills():Boolean{
return ((((((TowerKills.Tower1 == Number(Kills))) && ((TowerKills.Tower3 == Number(Gold))))) && ((TowerKills.Tower5 == Number(Lives)))));
}
private static function GetRoundMessages():Boolean{
return ((((((MonsterKills.Monster7 == String(Points))) && ((TowerKills.Tower6 == Number(Points))))) && ((MissilesFired.Missile6 == uint(Points)))));
}
public static function Refresh():Boolean{
return (((((((UpdateMonsterKills()) && (RefreshTowerKills()))) && (GetMissilesFired()))) && (GetRoundMessages())));
}
public static function Reset():void{
Kills = 0;
Gold = 0;
Lives = 0;
PreviousLives = 0;
Points = 0;
MonsterKills.Monster1 = "0";
MonsterKills.Monster2 = "0";
MonsterKills.Monster3 = "0";
MonsterKills.Monster4 = "0";
MonsterKills.Monster5 = "0";
MonsterKills.Monster6 = "0";
MonsterKills.Monster7 = "0";
TowerKills.Tower1 = Number(0);
TowerKills.Tower2 = Number(0);
TowerKills.Tower3 = Number(0);
TowerKills.Tower4 = Number(0);
TowerKills.Tower5 = Number(0);
TowerKills.Tower6 = Number(0);
MissilesFired.Missile1 = uint(0);
MissilesFired.Missile2 = uint(0);
MissilesFired.Missile3 = uint(0);
MissilesFired.Missile4 = uint(0);
MissilesFired.Missile5 = uint(0);
MissilesFired.Missile6 = uint(0);
}
MonsterKills.Monster1 = String(0);
MonsterKills.Monster2 = String(0);
MonsterKills.Monster3 = String(0);
MonsterKills.Monster4 = String(0);
MonsterKills.Monster5 = String(0);
MonsterKills.Monster6 = String(0);
MonsterKills.Monster7 = String(0);
TowerKills.Tower1 = Number(0);
TowerKills.Tower2 = Number(0);
TowerKills.Tower3 = Number(0);
TowerKills.Tower4 = Number(0);
TowerKills.Tower5 = Number(0);
TowerKills.Tower6 = Number(0);
MissilesFired.Missile1 = uint(0);
MissilesFired.Missile2 = uint(0);
MissilesFired.Missile3 = uint(0);
MissilesFired.Missile4 = uint(0);
MissilesFired.Missile5 = uint(0);
MissilesFired.Missile6 = uint(0);
RoundMessages.Text1 = String(0);
RoundMessages.Text2 = String(0);
RoundMessages.Text3 = String(0);
RoundMessages.Text4 = String(0);
RoundMessages.Text5 = String(0);
}
}//package TowerDefence