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

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

Kingdom of the wind.swf

This is the info page for
Flash #46480

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


Text
Create Rider Units
(engine unit)
(shotcut: 1)

<p align="right"><font face="Verdana" size="8" color="#ffcc00" letterSpacing="0.000000" kerning="1">5 mana</font></p>

Create Copter
(engine unit)
(shotcut: 2)

Create Eagle Warrior
(animal unit)
(shotcut: 3)

Create Panzer
(engine unit)
(shotcut: 4)

Create Dragon
(animal unit)
(shotcut: 5)

Create Ice Turret
(shotcut: Q)

Create Fire Turret
(shotcut: W)

Create Thunder Turret
(shotcut: E)

Upgrade units range
(shotcut: A)

Upgrade units health
(shotcut: S)

Upgrade units level
(shotcut: D)

Upgrade units attack level
(shotcut: F)

Upgrade units defense level
(shotcut: G)

Upgrade Max Manapool
(shotcut: Z)

Repair Castle
(1 mana for 10 health)
(shotcut: X)

Heal all units
(shotcut: C)

Cast Special Attack
(shotcut: V)

hundreds

of

online

games

awesome

VISIT

sponsored by

Please visit our sponsor
Link will be in new window

developed by

Kingdom Of The Wind

Play

<p align="center"></p>

<p align="center"></p>

<p align="center"></p>

<p align="center"></p>

<p align="center"><font face="Charlemagne Std" size="12" color="#ffcc00" letterSpacing="0.000000" kerning="1">Enemy Wave</font></p>

<p align="right"><font face="Verdana" size="10" color="#ffffff" letterSpacing="0.000000" kerning="1">9999999</font></p>

Click here to select
unit that will
be created
or
press [1]
for shortcut

Now click one
of these mark to select
the position of new unit
or
you can move icon
using right or left arrow
and then press [space]

While waiting
move cursor up or down
to see around the castle
up and down arrow
can be used for this purpose

Or
you can see enemy
strength on each
side from this meter

AND
you MAY need to
upgrade your troops
skills

or
launch
special attack

effects volume

music volume

graphic quality

Continue

Continue

New Game

New Game

Add Game To Your Site

Add Game To Your Site

Play More Games

Play More Games

Credit

Credit

Instructions

About Kingdom of the Wind Gameplay
Your goal as a Southern Wind Warrior leader is to defend your last Wind Castle for 8
days before help comes from another Wind Tribe. Create units and turrets from the
creation area on the right panel and choose their first stand so they'll be able to
defend your castle.
Repair your castle by using the repair option from the upgrade tab on the right
panel. Unit upgrades like range, attack, defense, level and Special attack can also be
cast in this area.
At the end of each day, you will receive experience points that can be used to
upgrade your castle with new turrets and units.  You can only do this at the end of
each day so manage your experience points wisely.

G
a
m
e
P
l
a
y

Shortcuts

Shortcuts

Shortcuts

Units

Units

Units

EXP

EXP

EXP

Battle

Battle

Battle

Upgrade

Upgrade

Upgrade

GamePlay

GamePlay

GamePlay

Here is some shortcuts for the gameplay

1 : Create rider units
2 : Create copter units
3 : Create eagle warrior
4 : Create panzer units
5 : Create red dragon
Q : Create ice turret
W : Create fire turret
E : Create thunder turret

Creating units and turrets

A : Upgrade units range
S : Upgrade units health
D : Upgrade units level
F : Upgrade units attack
G : Upgrade units defense
Z : Increase Manapool
X : Repair castle
C : Heal existing units
V : Perform special attack

Upgrading and repairing

I : Show/hide upgrade panel
O : Show/hide create panel
P : Show option panel and pause game
[esc] : hide option panel and resume game
cancel unit/turret creation

Miscellaneous functions

S
h
o
r
t
c
u
t
s

How to Create Units
Select which unit or turret will be created, then select their position. Use mouse to
click on the unit or turret icon on the right panel, and move it to one of the plus
signs that appear. Or with keyboard shortcuts, select the unit or turret with the
shortcut keys described on the "SHORTCUTS" page, and select their new position
using right or left arrows, and press [space] to place your unit position
You will automatically generate mana as time progresses. This maximum can be
increased by either purchasing an upgrade with experience between levels, or using
mana within a level to boost your total limit. You also gain mana from killing
opponents; stronger enemies will give you more mana.

U
n
i
t
s

What is EXP for?
You can gain EXP by killing enemies, create units and turrets. You can use your
earned EXP in the Upgrade Menu to purchase new skills and upgrade existing ones.
Choose your upgrades wisely, as you cannot reset your decisions! You can replay
previous battle to make your EXP grow. If you quit battle you wouldn’t earn any
EXP. If you die at battle you only learn half of your EXP.

E
X
P

How to Win the Battle
The goal of this game is to complete each day by surviving the enemy onslaught,
while sending your own forces to destroy them. Each day will continue until the
time that is shown on the Enemy Wave bar is full.
While your opponent may have the advantage of superior numbers, your castle can
be equipped with powerful turrets. You can build Ice turrets, Fire turrets, and
Thunder turrets that are strong enough to defend your castle.

B
a
t
t
l
e

How to Upgrade during Battle
There are some temporary upgrades during battle that can increase your unit’s
ability, your mana pool, or to repair your castle from damage. These upgrades are
available on the right panel in the upgrade areas.
Unit upgrade is used to increase a newly created unit’s range, level, health, attack,
or defense, so that they will be more powerful than before. Of course these upgrades
cost mana.
Mana pool upgrade is used to increase your mana limit and regeneration speed, so
that you will receive more mana as time progresses. This upgrade costs mana too.
Healing is used to heal all present units and Repair is used to reduce the castle’s
damage.

U
p
g
r
a
d
e

Continue

Continue

Level Select

Day  #1

Day  #2

Day  #3

Day  #4

Day  #5

Day  #6

Day  #7

Day  #8

Play

Play

Load

Load

Save

Save

Play More Games

Play More Games

Upgrade

Upgrade

Statistics

Statistics

Instructions

Instructions

Day 1:
It's you, the Lost Eagle of Wind Warriors
that has been chosen to be the one to
finish this long war against evil.
Defend our Castle, so they won't be able
to destroy our last stand.
Hint: Save your mana for mana pool upgrade.
More mana, more troops.

Day 2:

It flies, it is red, and it is attacking. Big
Red Bats have come to show their
strength.
Make sure that we have our army
prepared before they come to the field.
Hint: You need to train your units faster than
before.

Day 3:

Half of the Panzer troops have changed
their side sir. This is bad because they
already know our strength.
And also they have changed their color.
Do we already have our Panzer troop
sir?
Hint: More mana at the start of battle is
needed, unless you can regenerate it faster.

Day 4:

Ever thought about Flying Knights?
Here come the real ones without horses.
And yes, they have their swords and
wings of course.
Hint: You need to unlock turrets. The bigger
it is the better.

Day 5:

Each day feels longer than before. Do
you realize that?
Today, their Dragon army is coming to
the battlefield. You must prepare your
Dragon.
Hint: Repair your castle quickly as your
enemy hurts it.

Day 6:

Nothing special, unless they are getting
stronger by the day. Are they upgrading
their troops? Have you upgraded your
troops?
And of course, today’s battle will take
longer than yesterday’s.

Day 7:

It seems that our troop morale is coming
down as time progresses.
We need more and more upgrades for our
troops, don't we?

Day 8: Final Battle

Here comes the Ultimate Evil, daring to
challenge your defense.
Do whatever it takes to defend your
very castle. Or die with honor as a Wind
Warrior.

Main Menu

Main Menu

Click here to upgrade
your skills

Saving Game

Your progress has been
saved

Loading Game

Your progress has been
loaded

Cannot load game progress
Create new game ?

Upgrades

experience point :

<p align="right"><font face="Palatino Linotype" size="17" color="#000000" letterSpacing="0.000000" kerning="1">0</font></p>

Insufficient experience point

Maximum upgrade reached

<p align="right"><font face="Franklin Gothic Medium" size="10" color="#ffcc00" letterSpacing="0.000000" kerning="1">0</font></p>

exp.

upgrades castle level

upgrades ice turret level

upgrades fire turret level

upgrades thunder turret level

upgrades rider level

upgrades copter level

upgrades eagle level

upgrades panzer level

upgrades dragon level

faster unit create time

faster turrets create time

faster mana regeneration
time

increase initial mana

unlock castle

unlock ice turret

unlock fire turret

unlock thunder turret

unlock rider

unlock copter

unlock eagle

unlock panzer

unlock dragon

unlock faster unit create time

unlock faster turrets
create time

unlock faster mana
regeneration time

unlock greater initial mana

Statistics

Cancel

Cancel

Experience gained
Experience spent
Enemy killed
Unit built
Unit lost
Turret built
Turret lost
Mana earned
Mana spent

<p align="right"><font face="Charlemagne Std" size="16" color="#000000" letterSpacing="1.000000" kerning="1">0</font></p>

<p align="right"><font face="Charlemagne Std" size="16" color="#000000" letterSpacing="1.000000" kerning="1">0</font></p>

<p align="right"><font face="Charlemagne Std" size="16" color="#000000" letterSpacing="1.000000" kerning="1">0</font></p>

<p align="right"><font face="Charlemagne Std" size="16" color="#000000" letterSpacing="1.000000" kerning="1">0</font></p>

<p align="right"><font face="Charlemagne Std" size="16" color="#000000" letterSpacing="1.000000" kerning="1">0</font></p>

<p align="right"><font face="Charlemagne Std" size="16" color="#000000" letterSpacing="1.000000" kerning="1">0</font></p>

<p align="right"><font face="Charlemagne Std" size="16" color="#000000" letterSpacing="1.000000" kerning="1">0</font></p>

<p align="right"><font face="Charlemagne Std" size="16" color="#000000" letterSpacing="1.000000" kerning="1">0</font></p>

<p align="right"><font face="Charlemagne Std" size="16" color="#000000" letterSpacing="1.000000" kerning="1">0</font></p>

Loading Game

Game result

Result

Evil ultimate killed

Evil knight killed

Evil panzer killed

Big bat killed

Evil copter killed

Small bat killed

Dragon created

Panzer created

Eagle created

Copter created

Rider created

Ice turret created

Evil dragon killed

Fire turret created

Thunder turret
created

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

Experience earned

<p align="right"><font face="Palatino Linotype" size="16" color="#990000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

Your castle has down with the dust
Try again and get your honor back

Retry

Retry

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="16" color="#990000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

x   7 XP

x   6 XP

x   5 XP

x   4 XP

x   3 XP

x   2 XP

x   1 XP

x 2.5 XP

x    2 XP

x 1.5 XP

x    1 XP

x 0.5 XP

x    3 XP

x    4 XP

(= total XP/2)

Congratulations for beating down all enemies
Progress to the next level

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="14" color="#000000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

<p align="right"><font face="Palatino Linotype" size="16" color="#990000" letterSpacing="0.000000" kerning="1"><b>0</b></font></p>

Congratulations for beating down all enemies
You are definitely a wind warrior
Wanna beat the scores ?

Credits

Musics
Fierce Battle by Evil-Dog
-.sOuNdWaVeS.- by digital-musician
Entering the Stronghold by Denny Schneidemesser (Danman87)
all musics taken from Newgrounds.com
Project Manager
Rudy Sudarto
Programmer
Andi Eko Suryono
Illustrator  & Animator
Firmansyah

ActionScript [AS3]

Section 1
//KongregateEvent (com.kongregate.as3.client.events.KongregateEvent) package com.kongregate.as3.client.events { import flash.events.*; public class KongregateEvent extends Event { public static const COMPLETE:String = "component_api_available"; public function KongregateEvent(_arg1:String){ super(_arg1); } } }//package com.kongregate.as3.client.events
Section 2
//AbstractShadowService (com.kongregate.as3.client.services.AbstractShadowService) package com.kongregate.as3.client.services { import flash.events.*; public class AbstractShadowService extends EventDispatcher { protected function alert(_arg1:String, _arg2:String, _arg3="", _arg4:String=""):void{ trace(((((((("Kongregate API: " + _arg1) + ".") + _arg2) + "(") + _arg3) + ") ") + _arg4)); } } }//package com.kongregate.as3.client.services
Section 3
//HighScoreServiceShadow (com.kongregate.as3.client.services.HighScoreServiceShadow) package com.kongregate.as3.client.services { public class HighScoreServiceShadow extends AbstractShadowService implements IHighScoreServices { private var mode:String; public function HighScoreServiceShadow(){ mode = ""; } public function submit(_arg1:Number, _arg2:String=null):void{ alert("IHighScoreServices", "submit", arguments); } public function connect():Boolean{ alert("IKongregateServices", "connect"); return (true); } public function requestList(_arg1:Function):void{ alert("IHighScoreServices", "requestList", "", (("[Mode: " + mode) + "]")); _arg1({success:false}); } public function setMode(_arg1:String):void{ alert("IHighScoreServices", "setMode", arguments); this.mode = _arg1; } } }//package com.kongregate.as3.client.services
Section 4
//IHighScoreServices (com.kongregate.as3.client.services.IHighScoreServices) package com.kongregate.as3.client.services { public interface IHighScoreServices { function setMode(_arg1:String):void; function submit(_arg1:Number, _arg2:String=null):void; function requestList(_arg1:Function):void; } }//package com.kongregate.as3.client.services
Section 5
//IKongregateServices (com.kongregate.as3.client.services.IKongregateServices) package com.kongregate.as3.client.services { import flash.events.*; public interface IKongregateServices extends IEventDispatcher { function getPlayerInfo(_arg1:Function):void; function connect(_arg1:Number=-1):Boolean; } }//package com.kongregate.as3.client.services
Section 6
//IStatServices (com.kongregate.as3.client.services.IStatServices) package com.kongregate.as3.client.services { public interface IStatServices { function submitArray(_arg1:Array):void; function submit(_arg1:String, _arg2:Number):void; } }//package com.kongregate.as3.client.services
Section 7
//IUserServices (com.kongregate.as3.client.services.IUserServices) package com.kongregate.as3.client.services { public interface IUserServices { function getName():String; function getPlayerInfo(_arg1:Function):void; } }//package com.kongregate.as3.client.services
Section 8
//KongregateServiceShadow (com.kongregate.as3.client.services.KongregateServiceShadow) package com.kongregate.as3.client.services { public class KongregateServiceShadow extends AbstractShadowService implements IKongregateServices { public function getName():String{ alert("IKongregateServices", "getName"); return ("Guest"); } public function connect(_arg1:Number=-1):Boolean{ alert("IKongregateServices", "connect", arguments); return (true); } public function getPlayerInfo(_arg1:Function):void{ alert("IKongregateServices", "getPlayerInfo"); _arg1(new Object()); } } }//package com.kongregate.as3.client.services
Section 9
//StatServiceShadow (com.kongregate.as3.client.services.StatServiceShadow) package com.kongregate.as3.client.services { public class StatServiceShadow extends AbstractShadowService implements IStatServices { public function submitArray(_arg1:Array):void{ alert("IStatServices", "submitArray", arguments); } public function submit(_arg1:String, _arg2:Number):void{ alert("IStatServices", "submitStat", arguments); } } }//package com.kongregate.as3.client.services
Section 10
//UserServiceShadow (com.kongregate.as3.client.services.UserServiceShadow) package com.kongregate.as3.client.services { public class UserServiceShadow extends AbstractShadowService implements IUserServices { public function getName():String{ alert("UserService", "getName"); return ("Guest"); } public function getPlayerInfo(_arg1:Function):void{ alert("UserService", "getPlayerInfo"); _arg1({isGuest:true, name:"Guest", points:0, level:0, isMode:false, isAdmin:false, isDeveloper:false, avatarPath:"", chatAvatarPath:""}); } } }//package com.kongregate.as3.client.services
Section 11
//IAPIBootstrap (com.kongregate.as3.client.IAPIBootstrap) package com.kongregate.as3.client { import flash.events.*; import flash.display.*; public interface IAPIBootstrap { function init(_arg1:Event=null, _arg2:Stage=null):void; function hideLog():void; function showLog(_arg1:int=0):void; } }//package com.kongregate.as3.client
Section 12
//KongregateAPI (com.kongregate.as3.client.KongregateAPI) package com.kongregate.as3.client { import flash.events.*; import flash.display.*; import com.kongregate.as3.client.events.*; import com.kongregate.as3.client.services.*; import flash.utils.*; import flash.net.*; import flash.system.*; import flash.errors.*; public class KongregateAPI extends Sprite { private const VERSION:Number = 1; private var loader:Loader; private var loadedDomain:ApplicationDomain; private static const CLASS_USER:String = "com.kongregate.as3.client.services.UserServices"; private static const CLASS_STATS:String = "com.kongregate.as3.client.services.StatServices"; private static const CLASS_SERVICES:String = "com.kongregate.as3.client.services.KongregateServices"; private static const CLASS_SCORES:String = "com.kongregate.as3.client.services.HighScoreServices"; private static const DEBUG_API_URL:String = "//Linuxpc/kongregate/public/flash/API_AS3.swf"; private static var _connected:Boolean; private static var kUser:IUserServices; private static var _loaded:Boolean; private static var kServices:IKongregateServices; private static var kScores:IHighScoreServices; private static var mInstance:KongregateAPI; private static var kStats:IStatServices; private static var kAPI:IAPIBootstrap; public function KongregateAPI(){ if (mInstance != null){ throw (new Error("Warning: KongregateAPI has been added to stage more than once or accessed improperly. Use getInstance() or a stage reference to access.")); }; mInstance = this; this.addEventListener(Event.ADDED_TO_STAGE, init, false, 0, true); } public function get loaded():Boolean{ return (_loaded); } public function get connected():Boolean{ return (_connected); } private function alertConnected(_arg1:TimerEvent=null):void{ var _local2:KongregateEvent; var _local3:Boolean; _local2 = new KongregateEvent(KongregateEvent.COMPLETE); _local3 = this.dispatchEvent(_local2); } private function init(_arg1:Event):void{ var _local2:Object; var _local3:String; var _local4:URLRequest; var _local5:LoaderContext; this.removeEventListener(Event.ADDED_TO_STAGE, init); _loaded = false; _connected = false; _local2 = LoaderInfo(root.loaderInfo).parameters; _local3 = _local2.api_path; if (_local3 == null){ trace("Alert: Kongregate API could not be loaded, due to local testing. API will load when the game is uploaded."); createShadowServices(); return; }; Security.allowDomain("*.kongregate.com"); Security.allowDomain("kongregatetrunk.com"); _local4 = new URLRequest(_local3); _local5 = new LoaderContext(false); _local5.applicationDomain = ApplicationDomain.currentDomain; _local5.securityDomain = SecurityDomain.currentDomain; loader = new Loader(); loader.contentLoaderInfo.addEventListener(Event.COMPLETE, loadComplete); loader.addEventListener(IOErrorEvent.IO_ERROR, ioErrorHandler); loader.load(_local4, _local5); } public function get api():IAPIBootstrap{ return (kAPI); } private function loadComplete(_arg1:Event):void{ getServices(); } public function get scores():IHighScoreServices{ return (kScores); } private function ioErrorHandler(_arg1:IOErrorEvent):void{ throw (new IOError(("API file not found. " + _arg1))); } public function get services():IKongregateServices{ return (kServices); } public function get stats():IStatServices{ return (kStats); } private function createShadowServices():void{ var _local1:Timer; trace(">>> Kongregate Shadow Services instantiated for local development.."); kServices = new KongregateServiceShadow(); kScores = new HighScoreServiceShadow(); kStats = new StatServiceShadow(); kUser = new UserServiceShadow(); _local1 = new Timer(200, 1); _local1.addEventListener(TimerEvent.TIMER_COMPLETE, alertConnected); _local1.start(); _connected = true; } public function get user():IUserServices{ return (kUser); } private function getServices():void{ var _local1:ApplicationDomain; var _local2:*; var _local3:*; var _local4:*; var _local5:*; _local1 = ApplicationDomain.currentDomain; kAPI = IAPIBootstrap(loader.getChildAt(0)); this.addChild(loader); _local2 = _local1.getDefinition(CLASS_SERVICES); trace(_local2); kServices = _local2.getInstance(); _local3 = _local1.getDefinition(CLASS_SCORES); kScores = _local3.getInstance(); _local4 = _local1.getDefinition(CLASS_STATS); kStats = _local4.getInstance(); _local5 = _local1.getDefinition(CLASS_USER); kUser = _local5.getInstance(); kServices.connect(VERSION); _loaded = true; _connected = true; alertConnected(); } public static function getInstance():KongregateAPI{ if (!mInstance){ throw (new IllegalOperationError("You must add the Kongregate API component to the stage before attempting to access it.")); }; return (mInstance); } } }//package com.kongregate.as3.client
Section 13
//BaseButton (fl.controls.BaseButton) package fl.controls { import flash.events.*; import flash.display.*; import fl.core.*; import flash.utils.*; import fl.events.*; public class BaseButton extends UIComponent { protected var _selected:Boolean;// = false private var unlockedMouseState:String; protected var pressTimer:Timer; protected var mouseState:String; protected var background:DisplayObject; private var _mouseStateLocked:Boolean;// = false protected var _autoRepeat:Boolean;// = false private static var defaultStyles:Object = {upSkin:"Button_upSkin", downSkin:"Button_downSkin", overSkin:"Button_overSkin", disabledSkin:"Button_disabledSkin", selectedDisabledSkin:"Button_selectedDisabledSkin", selectedUpSkin:"Button_selectedUpSkin", selectedDownSkin:"Button_selectedDownSkin", selectedOverSkin:"Button_selectedOverSkin", focusRectSkin:null, focusRectPadding:null, repeatDelay:500, repeatInterval:35}; public function BaseButton(){ _selected = false; _autoRepeat = false; _mouseStateLocked = false; super(); buttonMode = true; mouseChildren = false; useHandCursor = false; setupMouseEvents(); setMouseState("up"); pressTimer = new Timer(1, 0); pressTimer.addEventListener(TimerEvent.TIMER, buttonDown, false, 0, true); } protected function endPress():void{ pressTimer.reset(); } public function set mouseStateLocked(_arg1:Boolean):void{ _mouseStateLocked = _arg1; if (_arg1 == false){ setMouseState(unlockedMouseState); } else { unlockedMouseState = mouseState; }; } public function get autoRepeat():Boolean{ return (_autoRepeat); } public function set autoRepeat(_arg1:Boolean):void{ _autoRepeat = _arg1; } override public function set enabled(_arg1:Boolean):void{ super.enabled = _arg1; mouseEnabled = _arg1; } public function get selected():Boolean{ return (_selected); } protected function mouseEventHandler(_arg1:MouseEvent):void{ if (_arg1.type == MouseEvent.MOUSE_DOWN){ setMouseState("down"); startPress(); } else { if ((((_arg1.type == MouseEvent.ROLL_OVER)) || ((_arg1.type == MouseEvent.MOUSE_UP)))){ setMouseState("over"); endPress(); } else { if (_arg1.type == MouseEvent.ROLL_OUT){ setMouseState("up"); endPress(); }; }; }; } public function setMouseState(_arg1:String):void{ if (_mouseStateLocked){ unlockedMouseState = _arg1; return; }; if (mouseState == _arg1){ return; }; mouseState = _arg1; invalidate(InvalidationType.STATE); } protected function startPress():void{ if (_autoRepeat){ pressTimer.delay = Number(getStyleValue("repeatDelay")); pressTimer.start(); }; dispatchEvent(new ComponentEvent(ComponentEvent.BUTTON_DOWN, true)); } protected function buttonDown(_arg1:TimerEvent):void{ if (!_autoRepeat){ endPress(); return; }; if (pressTimer.currentCount == 1){ pressTimer.delay = Number(getStyleValue("repeatInterval")); }; dispatchEvent(new ComponentEvent(ComponentEvent.BUTTON_DOWN, true)); } public function set selected(_arg1:Boolean):void{ if (_selected == _arg1){ return; }; _selected = _arg1; invalidate(InvalidationType.STATE); } override public function get enabled():Boolean{ return (super.enabled); } override protected function draw():void{ if (isInvalid(InvalidationType.STYLES, InvalidationType.STATE)){ drawBackground(); invalidate(InvalidationType.SIZE, false); }; if (isInvalid(InvalidationType.SIZE)){ drawLayout(); }; super.draw(); } protected function setupMouseEvents():void{ addEventListener(MouseEvent.ROLL_OVER, mouseEventHandler, false, 0, true); addEventListener(MouseEvent.MOUSE_DOWN, mouseEventHandler, false, 0, true); addEventListener(MouseEvent.MOUSE_UP, mouseEventHandler, false, 0, true); addEventListener(MouseEvent.ROLL_OUT, mouseEventHandler, false, 0, true); } protected function drawLayout():void{ background.width = width; background.height = height; } protected function drawBackground():void{ var _local1:String; var _local2:DisplayObject; _local1 = (enabled) ? mouseState : "disabled"; if (selected){ _local1 = (("selected" + _local1.substr(0, 1).toUpperCase()) + _local1.substr(1)); }; _local1 = (_local1 + "Skin"); _local2 = background; background = getDisplayObjectInstance(getStyleValue(_local1)); addChildAt(background, 0); if (((!((_local2 == null))) && (!((_local2 == background))))){ removeChild(_local2); }; } public static function getStyleDefinition():Object{ return (defaultStyles); } } }//package fl.controls
Section 14
//Button (fl.controls.Button) package fl.controls { import flash.display.*; import fl.core.*; import fl.managers.*; public class Button extends LabelButton implements IFocusManagerComponent { protected var emphasizedBorder:DisplayObject; protected var _emphasized:Boolean;// = false private static var defaultStyles:Object = {emphasizedSkin:"Button_emphasizedSkin", emphasizedPadding:2}; public static var createAccessibilityImplementation:Function; public function Button(){ _emphasized = false; super(); } override public function drawFocus(_arg1:Boolean):void{ var _local2:Number; var _local3:*; super.drawFocus(_arg1); if (_arg1){ _local2 = Number(getStyleValue("emphasizedPadding")); if ((((_local2 < 0)) || (!(_emphasized)))){ _local2 = 0; }; _local3 = getStyleValue("focusRectPadding"); _local3 = ((_local3)==null) ? 2 : _local3; _local3 = (_local3 + _local2); uiFocusRect.x = -(_local3); uiFocusRect.y = -(_local3); uiFocusRect.width = (width + (_local3 * 2)); uiFocusRect.height = (height + (_local3 * 2)); }; } public function set emphasized(_arg1:Boolean):void{ _emphasized = _arg1; invalidate(InvalidationType.STYLES); } override protected function draw():void{ if (((isInvalid(InvalidationType.STYLES)) || (isInvalid(InvalidationType.SIZE)))){ drawEmphasized(); }; super.draw(); if (emphasizedBorder != null){ setChildIndex(emphasizedBorder, (numChildren - 1)); }; } public function get emphasized():Boolean{ return (_emphasized); } override protected function initializeAccessibility():void{ if (Button.createAccessibilityImplementation != null){ Button.createAccessibilityImplementation(this); }; } protected function drawEmphasized():void{ var _local1:Object; var _local2:Number; if (emphasizedBorder != null){ removeChild(emphasizedBorder); }; emphasizedBorder = null; if (!_emphasized){ return; }; _local1 = getStyleValue("emphasizedSkin"); if (_local1 != null){ emphasizedBorder = getDisplayObjectInstance(_local1); }; if (emphasizedBorder != null){ addChildAt(emphasizedBorder, 0); _local2 = Number(getStyleValue("emphasizedPadding")); emphasizedBorder.x = (emphasizedBorder.y = -(_local2)); emphasizedBorder.width = (width + (_local2 * 2)); emphasizedBorder.height = (height + (_local2 * 2)); }; } public static function getStyleDefinition():Object{ return (UIComponent.mergeStyles(LabelButton.getStyleDefinition(), defaultStyles)); } } }//package fl.controls
Section 15
//ButtonLabelPlacement (fl.controls.ButtonLabelPlacement) package fl.controls { public class ButtonLabelPlacement { public static const TOP:String = "top"; public static const LEFT:String = "left"; public static const BOTTOM:String = "bottom"; public static const RIGHT:String = "right"; } }//package fl.controls
Section 16
//LabelButton (fl.controls.LabelButton) package fl.controls { import flash.events.*; import flash.display.*; import fl.core.*; import fl.managers.*; import fl.events.*; import flash.text.*; import flash.ui.*; public class LabelButton extends BaseButton implements IFocusManagerComponent { protected var _labelPlacement:String;// = "right" protected var _toggle:Boolean;// = false protected var icon:DisplayObject; protected var oldMouseState:String; protected var mode:String;// = "center" public var textField:TextField; protected var _label:String;// = "Label" private static var defaultStyles:Object = {icon:null, upIcon:null, downIcon:null, overIcon:null, disabledIcon:null, selectedDisabledIcon:null, selectedUpIcon:null, selectedDownIcon:null, selectedOverIcon:null, textFormat:null, disabledTextFormat:null, textPadding:5, embedFonts:false}; public static var createAccessibilityImplementation:Function; public function LabelButton(){ _labelPlacement = ButtonLabelPlacement.RIGHT; _toggle = false; _label = "Label"; mode = "center"; super(); } protected function toggleSelected(_arg1:MouseEvent):void{ selected = !(selected); dispatchEvent(new Event(Event.CHANGE, true)); } public function get labelPlacement():String{ return (_labelPlacement); } override protected function keyDownHandler(_arg1:KeyboardEvent):void{ if (!enabled){ return; }; if (_arg1.keyCode == Keyboard.SPACE){ if (oldMouseState == null){ oldMouseState = mouseState; }; setMouseState("down"); startPress(); }; } protected function setEmbedFont(){ var _local1:Object; _local1 = getStyleValue("embedFonts"); if (_local1 != null){ textField.embedFonts = _local1; }; } override protected function keyUpHandler(_arg1:KeyboardEvent):void{ if (!enabled){ return; }; if (_arg1.keyCode == Keyboard.SPACE){ setMouseState(oldMouseState); oldMouseState = null; endPress(); dispatchEvent(new MouseEvent(MouseEvent.CLICK)); }; } override public function get selected():Boolean{ return ((_toggle) ? _selected : false); } public function set labelPlacement(_arg1:String):void{ _labelPlacement = _arg1; invalidate(InvalidationType.SIZE); } public function set toggle(_arg1:Boolean):void{ if (((!(_arg1)) && (super.selected))){ selected = false; }; _toggle = _arg1; if (_toggle){ addEventListener(MouseEvent.CLICK, toggleSelected, false, 0, true); } else { removeEventListener(MouseEvent.CLICK, toggleSelected); }; invalidate(InvalidationType.STATE); } public function get label():String{ return (_label); } override public function set selected(_arg1:Boolean):void{ _selected = _arg1; if (_toggle){ invalidate(InvalidationType.STATE); }; } override protected function draw():void{ if (textField.text != _label){ label = _label; }; if (isInvalid(InvalidationType.STYLES, InvalidationType.STATE)){ drawBackground(); drawIcon(); drawTextFormat(); invalidate(InvalidationType.SIZE, false); }; if (isInvalid(InvalidationType.SIZE)){ drawLayout(); }; if (isInvalid(InvalidationType.SIZE, InvalidationType.STYLES)){ if (((isFocused) && (focusManager.showFocusIndicator))){ drawFocus(true); }; }; validate(); } public function get toggle():Boolean{ return (_toggle); } override protected function configUI():void{ super.configUI(); textField = new TextField(); textField.type = TextFieldType.DYNAMIC; textField.selectable = false; addChild(textField); } override protected function drawLayout():void{ var _local1:Number; var _local2:String; var _local3:Number; var _local4:Number; var _local5:Number; var _local6:Number; var _local7:Number; var _local8:Number; _local1 = Number(getStyleValue("textPadding")); _local2 = ((((icon == null)) && ((mode == "center")))) ? ButtonLabelPlacement.TOP : _labelPlacement; textField.height = (textField.textHeight + 4); _local3 = (textField.textWidth + 4); _local4 = (textField.textHeight + 4); _local5 = ((icon)==null) ? 0 : (icon.width + _local1); _local6 = ((icon)==null) ? 0 : (icon.height + _local1); textField.visible = (label.length > 0); if (icon != null){ icon.x = Math.round(((width - icon.width) / 2)); icon.y = Math.round(((height - icon.height) / 2)); }; if (textField.visible == false){ textField.width = 0; textField.height = 0; } else { if ((((_local2 == ButtonLabelPlacement.BOTTOM)) || ((_local2 == ButtonLabelPlacement.TOP)))){ _local7 = Math.max(0, Math.min(_local3, (width - (2 * _local1)))); if ((height - 2) > _local4){ _local8 = _local4; } else { _local8 = (height - 2); }; _local3 = _local7; textField.width = _local3; _local4 = _local8; textField.height = _local4; textField.x = Math.round(((width - _local3) / 2)); textField.y = Math.round(((((height - textField.height) - _local6) / 2) + ((_local2)==ButtonLabelPlacement.BOTTOM) ? _local6 : 0)); if (icon != null){ icon.y = Math.round(((_local2)==ButtonLabelPlacement.BOTTOM) ? (textField.y - _local6) : ((textField.y + textField.height) + _local1)); }; } else { _local7 = Math.max(0, Math.min(_local3, ((width - _local5) - (2 * _local1)))); _local3 = _local7; textField.width = _local3; textField.x = Math.round(((((width - _local3) - _local5) / 2) + ((_local2)!=ButtonLabelPlacement.LEFT) ? _local5 : 0)); textField.y = Math.round(((height - textField.height) / 2)); if (icon != null){ icon.x = Math.round(((_local2)!=ButtonLabelPlacement.LEFT) ? (textField.x - _local5) : ((textField.x + _local3) + _local1)); }; }; }; super.drawLayout(); } override protected function initializeAccessibility():void{ if (LabelButton.createAccessibilityImplementation != null){ LabelButton.createAccessibilityImplementation(this); }; } protected function drawIcon():void{ var _local1:DisplayObject; var _local2:String; var _local3:Object; _local1 = icon; _local2 = (enabled) ? mouseState : "disabled"; if (selected){ _local2 = (("selected" + _local2.substr(0, 1).toUpperCase()) + _local2.substr(1)); }; _local2 = (_local2 + "Icon"); _local3 = getStyleValue(_local2); if (_local3 == null){ _local3 = getStyleValue("icon"); }; if (_local3 != null){ icon = getDisplayObjectInstance(_local3); }; if (icon != null){ addChildAt(icon, 1); }; if (((!((_local1 == null))) && (!((_local1 == icon))))){ removeChild(_local1); }; } public function set label(_arg1:String):void{ _label = _arg1; if (textField.text != _label){ textField.text = _label; dispatchEvent(new ComponentEvent(ComponentEvent.LABEL_CHANGE)); }; invalidate(InvalidationType.SIZE); invalidate(InvalidationType.STYLES); } protected function drawTextFormat():void{ var _local1:Object; var _local2:TextFormat; var _local3:TextFormat; _local1 = UIComponent.getStyleDefinition(); _local2 = (enabled) ? (_local1.defaultTextFormat as TextFormat) : (_local1.defaultDisabledTextFormat as TextFormat); textField.setTextFormat(_local2); _local3 = (getStyleValue((enabled) ? "textFormat" : "disabledTextFormat") as TextFormat); if (_local3 != null){ textField.setTextFormat(_local3); } else { _local3 = _local2; }; textField.defaultTextFormat = _local3; setEmbedFont(); } public static function getStyleDefinition():Object{ return (mergeStyles(defaultStyles, BaseButton.getStyleDefinition())); } } }//package fl.controls
Section 17
//Slider (fl.controls.Slider) package fl.controls { import flash.events.*; import flash.display.*; import fl.core.*; import fl.managers.*; import fl.events.*; import flash.ui.*; public class Slider extends UIComponent implements IFocusManagerComponent { protected var _direction:String; protected var _liveDragging:Boolean;// = false protected var _value:Number;// = 0 protected var _snapInterval:Number;// = 0 protected var _minimum:Number;// = 0 protected var _maximum:Number;// = 10 protected var track:BaseButton; protected var _tickInterval:Number;// = 0 protected var tickContainer:Sprite; protected var thumb:BaseButton; protected static const TICK_STYLES:Object = {upSkin:"tickSkin"}; protected static const TRACK_STYLES:Object = {upSkin:"sliderTrackSkin", overSkin:"sliderTrackSkin", downSkin:"sliderTrackSkin", disabledSkin:"sliderTrackDisabledSkin"}; protected static const THUMB_STYLES:Object = {upSkin:"thumbUpSkin", overSkin:"thumbOverSkin", downSkin:"thumbDownSkin", disabledSkin:"thumbDisabledSkin"}; protected static var defaultStyles:Object = {thumbUpSkin:"SliderThumb_upSkin", thumbOverSkin:"SliderThumb_overSkin", thumbDownSkin:"SliderThumb_downSkin", thumbDisabledSkin:"SliderThumb_disabledSkin", sliderTrackSkin:"SliderTrack_skin", sliderTrackDisabledSkin:"SliderTrack_disabledSkin", tickSkin:"SliderTick_skin", focusRectSkin:null, focusRectPadding:null}; public function Slider(){ _direction = SliderDirection.HORIZONTAL; _minimum = 0; _maximum = 10; _value = 0; _tickInterval = 0; _snapInterval = 0; _liveDragging = false; super(); setStyles(); } public function get minimum():Number{ return (_minimum); } public function set minimum(_arg1:Number):void{ _minimum = _arg1; this.value = Math.max(_arg1, this.value); invalidate(InvalidationType.DATA); } public function get maximum():Number{ return (_maximum); } protected function positionThumb():void{ thumb.x = ((((_direction)==SliderDirection.VERTICAL) ? ((maximum - minimum) - value) : (value - minimum) / (maximum - minimum)) * _width); } protected function clearTicks():void{ if (((!(tickContainer)) || (!(tickContainer.parent)))){ return; }; removeChild(tickContainer); } protected function onTrackClick(_arg1:MouseEvent):void{ calculateValue(track.mouseX, InteractionInputType.MOUSE, SliderEventClickTarget.TRACK); if (!liveDragging){ dispatchEvent(new SliderEvent(SliderEvent.CHANGE, value, SliderEventClickTarget.TRACK, InteractionInputType.MOUSE)); }; } public function set maximum(_arg1:Number):void{ _maximum = _arg1; this.value = Math.min(_arg1, this.value); invalidate(InvalidationType.DATA); } public function get liveDragging():Boolean{ return (_liveDragging); } protected function doDrag(_arg1:MouseEvent):void{ var _local2:Number; var _local3:Number; _local2 = (_width / snapInterval); _local3 = track.mouseX; calculateValue(_local3, InteractionInputType.MOUSE, SliderEventClickTarget.THUMB); dispatchEvent(new SliderEvent(SliderEvent.THUMB_DRAG, value, SliderEventClickTarget.THUMB, InteractionInputType.MOUSE)); } override protected function keyDownHandler(_arg1:KeyboardEvent):void{ var _local2:uint; var _local3:Number; var _local4:Boolean; if (!enabled){ return; }; _local2 = ((snapInterval)>0) ? snapInterval : 1; _local4 = (direction == SliderDirection.HORIZONTAL); if ((((((_arg1.keyCode == Keyboard.DOWN)) && (!(_local4)))) || ((((_arg1.keyCode == Keyboard.LEFT)) && (_local4))))){ _local3 = (value - _local2); } else { if ((((((_arg1.keyCode == Keyboard.UP)) && (!(_local4)))) || ((((_arg1.keyCode == Keyboard.RIGHT)) && (_local4))))){ _local3 = (value + _local2); } else { if ((((((_arg1.keyCode == Keyboard.PAGE_DOWN)) && (!(_local4)))) || ((((_arg1.keyCode == Keyboard.HOME)) && (_local4))))){ _local3 = minimum; } else { if ((((((_arg1.keyCode == Keyboard.PAGE_UP)) && (!(_local4)))) || ((((_arg1.keyCode == Keyboard.END)) && (_local4))))){ _local3 = maximum; }; }; }; }; if (!isNaN(_local3)){ _arg1.stopPropagation(); doSetValue(_local3, InteractionInputType.KEYBOARD, null, _arg1.keyCode); }; } override public function set enabled(_arg1:Boolean):void{ if (enabled == _arg1){ return; }; super.enabled = _arg1; track.enabled = (thumb.enabled = _arg1); } protected function thumbPressHandler(_arg1:MouseEvent):void{ stage.addEventListener(MouseEvent.MOUSE_MOVE, doDrag, false, 0, true); stage.addEventListener(MouseEvent.MOUSE_UP, thumbReleaseHandler, false, 0, true); dispatchEvent(new SliderEvent(SliderEvent.THUMB_PRESS, value, InteractionInputType.MOUSE, SliderEventClickTarget.THUMB)); } public function get snapInterval():Number{ return (_snapInterval); } protected function thumbReleaseHandler(_arg1:MouseEvent):void{ stage.removeEventListener(MouseEvent.MOUSE_MOVE, doDrag); stage.removeEventListener(MouseEvent.MOUSE_UP, thumbReleaseHandler); dispatchEvent(new SliderEvent(SliderEvent.THUMB_RELEASE, value, InteractionInputType.MOUSE, SliderEventClickTarget.THUMB)); dispatchEvent(new SliderEvent(SliderEvent.CHANGE, value, SliderEventClickTarget.THUMB, InteractionInputType.MOUSE)); } public function set liveDragging(_arg1:Boolean):void{ _liveDragging = _arg1; } public function set value(_arg1:Number):void{ doSetValue(_arg1); } public function set direction(_arg1:String):void{ var _local2:Boolean; _direction = _arg1; _local2 = (_direction == SliderDirection.VERTICAL); if (isLivePreview){ if (_local2){ setScaleY(-1); y = track.height; } else { setScaleY(1); y = 0; }; positionThumb(); return; }; if (((_local2) && (componentInspectorSetting))){ if ((rotation % 90) == 0){ setScaleY(-1); }; }; if (!componentInspectorSetting){ rotation = (_local2) ? 90 : 0; }; } public function set tickInterval(_arg1:Number):void{ _tickInterval = _arg1; invalidate(InvalidationType.SIZE); } override public function get enabled():Boolean{ return (super.enabled); } override protected function draw():void{ if (isInvalid(InvalidationType.STYLES)){ setStyles(); invalidate(InvalidationType.SIZE, false); }; if (isInvalid(InvalidationType.SIZE)){ track.setSize(_width, track.height); track.drawNow(); thumb.drawNow(); }; if (tickInterval > 0){ drawTicks(); } else { clearTicks(); }; positionThumb(); super.draw(); } override protected function configUI():void{ super.configUI(); thumb = new BaseButton(); thumb.setSize(13, 13); thumb.autoRepeat = false; addChild(thumb); thumb.addEventListener(MouseEvent.MOUSE_DOWN, thumbPressHandler, false, 0, true); track = new BaseButton(); track.move(0, 0); track.setSize(80, 4); track.autoRepeat = false; track.useHandCursor = false; track.addEventListener(MouseEvent.CLICK, onTrackClick, false, 0, true); addChildAt(track, 0); } public function set snapInterval(_arg1:Number):void{ _snapInterval = _arg1; } public function get value():Number{ return (_value); } public function get direction():String{ return (_direction); } public function get tickInterval():Number{ return (_tickInterval); } override public function setSize(_arg1:Number, _arg2:Number):void{ if ((((_direction == SliderDirection.VERTICAL)) && (!(isLivePreview)))){ super.setSize(_arg2, _arg1); } else { super.setSize(_arg1, _arg2); }; invalidate(InvalidationType.SIZE); } protected function drawTicks():void{ var _local1:Number; var _local2:Number; var _local3:Number; var _local4:uint; var _local5:DisplayObject; clearTicks(); tickContainer = new Sprite(); _local1 = ((maximum)<1) ? (tickInterval / 100) : tickInterval; _local2 = ((maximum - minimum) / _local1); _local3 = (_width / _local2); _local4 = 0; while (_local4 <= _local2) { _local5 = getDisplayObjectInstance(getStyleValue("tickSkin")); _local5.x = (_local3 * _local4); _local5.y = ((track.y - _local5.height) - 2); tickContainer.addChild(_local5); _local4++; }; addChild(tickContainer); } protected function calculateValue(_arg1:Number, _arg2:String, _arg3:String, _arg4:int=undefined):void{ var _local5:Number; _local5 = ((_arg1 / _width) * (maximum - minimum)); if (_direction == SliderDirection.VERTICAL){ _local5 = (maximum - _local5); } else { _local5 = (minimum + _local5); }; doSetValue(_local5, _arg2, _arg3, _arg4); } protected function getPrecision(_arg1:Number):Number{ var _local2:String; _local2 = _arg1.toString(); if (_local2.indexOf(".") == -1){ return (0); }; return (_local2.split(".").pop().length); } protected function doSetValue(_arg1:Number, _arg2:String=null, _arg3:String=null, _arg4:int=undefined):void{ var _local5:Number; var _local6:Number; var _local7:Number; var _local8:Number; var _local9:Number; _local5 = _value; if (((!((_snapInterval == 0))) && (!((_snapInterval == 1))))){ _local6 = Math.pow(10, getPrecision(snapInterval)); _local7 = (_snapInterval * _local6); _local8 = Math.round((_arg1 * _local6)); _local9 = (Math.round((_local8 / _local7)) * _local7); _arg1 = (_local9 / _local6); _value = Math.max(minimum, Math.min(maximum, _arg1)); } else { _value = Math.max(minimum, Math.min(maximum, Math.round(_arg1))); }; if (((!((_local5 == _value))) && (((((liveDragging) && (!((_arg3 == null))))) || ((_arg2 == InteractionInputType.KEYBOARD)))))){ dispatchEvent(new SliderEvent(SliderEvent.CHANGE, value, _arg3, _arg2, _arg4)); }; positionThumb(); } protected function setStyles():void{ copyStylesToChild(thumb, THUMB_STYLES); copyStylesToChild(track, TRACK_STYLES); } public static function getStyleDefinition():Object{ return (defaultStyles); } } }//package fl.controls
Section 18
//SliderDirection (fl.controls.SliderDirection) package fl.controls { public class SliderDirection { public static var HORIZONTAL:String = "horizontal"; public static var VERTICAL:String = "vertical"; } }//package fl.controls
Section 19
//ComponentShim (fl.core.ComponentShim) package fl.core { import flash.display.*; public dynamic class ComponentShim extends MovieClip { } }//package fl.core
Section 20
//InvalidationType (fl.core.InvalidationType) package fl.core { public class InvalidationType { public static const SIZE:String = "size"; public static const ALL:String = "all"; public static const DATA:String = "data"; public static const SCROLL:String = "scroll"; public static const STATE:String = "state"; public static const STYLES:String = "styles"; public static const SELECTED:String = "selected"; public static const RENDERER_STYLES:String = "rendererStyles"; } }//package fl.core
Section 21
//UIComponent (fl.core.UIComponent) package fl.core { import flash.events.*; import flash.display.*; import fl.managers.*; import flash.utils.*; import fl.events.*; import flash.system.*; import flash.text.*; public class UIComponent extends Sprite { protected var _enabled:Boolean;// = true private var _mouseFocusEnabled:Boolean;// = true protected var startHeight:Number; protected var _height:Number; protected var _oldIMEMode:String;// = null protected var startWidth:Number; public var focusTarget:IFocusManagerComponent; protected var errorCaught:Boolean;// = false protected var uiFocusRect:DisplayObject; protected var _width:Number; public var version:String;// = "3.0.0.15" protected var isFocused:Boolean;// = false protected var callLaterMethods:Dictionary; private var _focusEnabled:Boolean;// = true private var tempText:TextField; protected var invalidateFlag:Boolean;// = false protected var _inspector:Boolean;// = false protected var sharedStyles:Object; protected var invalidHash:Object; protected var isLivePreview:Boolean;// = false protected var _imeMode:String;// = null protected var instanceStyles:Object; protected var _x:Number; protected var _y:Number; public static var inCallLaterPhase:Boolean = false; private static var defaultStyles:Object = {focusRectSkin:"focusRectSkin", focusRectPadding:2, textFormat:new TextFormat("_sans", 11, 0, false, false, false, "", "", TextFormatAlign.LEFT, 0, 0, 0, 0), disabledTextFormat:new TextFormat("_sans", 11, 0x999999, false, false, false, "", "", TextFormatAlign.LEFT, 0, 0, 0, 0), defaultTextFormat:new TextFormat("_sans", 11, 0, false, false, false, "", "", TextFormatAlign.LEFT, 0, 0, 0, 0), defaultDisabledTextFormat:new TextFormat("_sans", 11, 0x999999, false, false, false, "", "", TextFormatAlign.LEFT, 0, 0, 0, 0)}; public static var createAccessibilityImplementation:Function; private static var focusManagers:Dictionary = new Dictionary(false); public function UIComponent(){ version = "3.0.0.15"; isLivePreview = false; invalidateFlag = false; _enabled = true; isFocused = false; _focusEnabled = true; _mouseFocusEnabled = true; _imeMode = null; _oldIMEMode = null; errorCaught = false; _inspector = false; super(); instanceStyles = {}; sharedStyles = {}; invalidHash = {}; callLaterMethods = new Dictionary(); StyleManager.registerInstance(this); configUI(); invalidate(InvalidationType.ALL); tabEnabled = (this is IFocusManagerComponent); focusRect = false; if (tabEnabled){ addEventListener(FocusEvent.FOCUS_IN, focusInHandler); addEventListener(FocusEvent.FOCUS_OUT, focusOutHandler); addEventListener(KeyboardEvent.KEY_DOWN, keyDownHandler); addEventListener(KeyboardEvent.KEY_UP, keyUpHandler); }; initializeFocusManager(); addEventListener(Event.ENTER_FRAME, hookAccessibility, false, 0, true); } public function drawFocus(_arg1:Boolean):void{ var _local2:Number; isFocused = _arg1; if (((!((uiFocusRect == null))) && (contains(uiFocusRect)))){ removeChild(uiFocusRect); uiFocusRect = null; }; if (_arg1){ uiFocusRect = (getDisplayObjectInstance(getStyleValue("focusRectSkin")) as Sprite); if (uiFocusRect == null){ return; }; _local2 = Number(getStyleValue("focusRectPadding")); uiFocusRect.x = -(_local2); uiFocusRect.y = -(_local2); uiFocusRect.width = (width + (_local2 * 2)); uiFocusRect.height = (height + (_local2 * 2)); addChildAt(uiFocusRect, 0); }; } private function callLaterDispatcher(_arg1:Event):void{ var _local2:Dictionary; var _local3:Object; if (_arg1.type == Event.ADDED_TO_STAGE){ removeEventListener(Event.ADDED_TO_STAGE, callLaterDispatcher); stage.addEventListener(Event.RENDER, callLaterDispatcher, false, 0, true); stage.invalidate(); return; }; _arg1.target.removeEventListener(Event.RENDER, callLaterDispatcher); if (stage == null){ addEventListener(Event.ADDED_TO_STAGE, callLaterDispatcher, false, 0, true); return; }; inCallLaterPhase = true; _local2 = callLaterMethods; for (_local3 in _local2) { _local3(); delete _local2[_local3]; }; inCallLaterPhase = false; } private function addedHandler(_arg1:Event):void{ removeEventListener("addedToStage", addedHandler); initializeFocusManager(); } protected function getStyleValue(_arg1:String):Object{ return (((instanceStyles[_arg1])==null) ? sharedStyles[_arg1] : instanceStyles[_arg1]); } protected function isOurFocus(_arg1:DisplayObject):Boolean{ return ((_arg1 == this)); } override public function get scaleX():Number{ return ((width / startWidth)); } override public function get scaleY():Number{ return ((height / startHeight)); } override public function set height(_arg1:Number):void{ if (_height == _arg1){ return; }; setSize(width, _arg1); } protected function keyDownHandler(_arg1:KeyboardEvent):void{ } protected function focusInHandler(_arg1:FocusEvent):void{ var _local2:IFocusManager; if (isOurFocus((_arg1.target as DisplayObject))){ _local2 = focusManager; if (((_local2) && (_local2.showFocusIndicator))){ drawFocus(true); isFocused = true; }; }; } public function setStyle(_arg1:String, _arg2:Object):void{ if ((((instanceStyles[_arg1] === _arg2)) && (!((_arg2 is TextFormat))))){ return; }; instanceStyles[_arg1] = _arg2; invalidate(InvalidationType.STYLES); } override public function get visible():Boolean{ return (super.visible); } public function get componentInspectorSetting():Boolean{ return (_inspector); } override public function get x():Number{ return ((isNaN(_x)) ? super.x : _x); } override public function get y():Number{ return ((isNaN(_y)) ? super.y : _y); } protected function setIMEMode(_arg1:Boolean){ var enabled = _arg1; if (_imeMode != null){ if (enabled){ IME.enabled = true; _oldIMEMode = IME.conversionMode; try { if (((!(errorCaught)) && (!((IME.conversionMode == IMEConversionMode.UNKNOWN))))){ IME.conversionMode = _imeMode; }; errorCaught = false; } catch(e:Error) { errorCaught = true; throw (new Error(("IME mode not supported: " + _imeMode))); }; } else { if (((!((IME.conversionMode == IMEConversionMode.UNKNOWN))) && (!((_oldIMEMode == IMEConversionMode.UNKNOWN))))){ IME.conversionMode = _oldIMEMode; }; IME.enabled = false; }; }; } public function set enabled(_arg1:Boolean):void{ if (_arg1 == _enabled){ return; }; _enabled = _arg1; invalidate(InvalidationType.STATE); } public function setSharedStyle(_arg1:String, _arg2:Object):void{ if ((((sharedStyles[_arg1] === _arg2)) && (!((_arg2 is TextFormat))))){ return; }; sharedStyles[_arg1] = _arg2; if (instanceStyles[_arg1] == null){ invalidate(InvalidationType.STYLES); }; } protected function keyUpHandler(_arg1:KeyboardEvent):void{ } public function set focusEnabled(_arg1:Boolean):void{ _focusEnabled = _arg1; } override public function set scaleX(_arg1:Number):void{ setSize((startWidth * _arg1), height); } public function get mouseFocusEnabled():Boolean{ return (_mouseFocusEnabled); } override public function set scaleY(_arg1:Number):void{ setSize(width, (startHeight * _arg1)); } protected function getDisplayObjectInstance(_arg1:Object):DisplayObject{ var classDef:Object; var skin = _arg1; classDef = null; if ((skin is Class)){ return ((new (skin) as DisplayObject)); }; if ((skin is DisplayObject)){ (skin as DisplayObject).x = 0; (skin as DisplayObject).y = 0; return ((skin as DisplayObject)); }; try { classDef = getDefinitionByName(skin.toString()); } catch(e:Error) { try { classDef = (loaderInfo.applicationDomain.getDefinition(skin.toString()) as Object); } catch(e:Error) { }; }; if (classDef == null){ return (null); }; return ((new (classDef) as DisplayObject)); } protected function copyStylesToChild(_arg1:UIComponent, _arg2:Object):void{ var _local3:String; for (_local3 in _arg2) { _arg1.setStyle(_local3, getStyleValue(_arg2[_local3])); }; } protected function beforeComponentParameters():void{ } protected function callLater(_arg1:Function):void{ if (inCallLaterPhase){ return; }; callLaterMethods[_arg1] = true; if (stage != null){ stage.addEventListener(Event.RENDER, callLaterDispatcher, false, 0, true); stage.invalidate(); } else { addEventListener(Event.ADDED_TO_STAGE, callLaterDispatcher, false, 0, true); }; } protected function createFocusManager():void{ if (focusManagers[stage] == null){ focusManagers[stage] = new FocusManager(stage); }; } override public function set visible(_arg1:Boolean):void{ var _local2:String; if (super.visible == _arg1){ return; }; super.visible = _arg1; _local2 = (_arg1) ? ComponentEvent.SHOW : ComponentEvent.HIDE; dispatchEvent(new ComponentEvent(_local2, true)); } protected function hookAccessibility(_arg1:Event):void{ removeEventListener(Event.ENTER_FRAME, hookAccessibility); initializeAccessibility(); } public function set componentInspectorSetting(_arg1:Boolean):void{ _inspector = _arg1; if (_inspector){ beforeComponentParameters(); } else { afterComponentParameters(); }; } override public function set x(_arg1:Number):void{ move(_arg1, _y); } public function drawNow():void{ draw(); } override public function set y(_arg1:Number):void{ move(_x, _arg1); } protected function checkLivePreview():Boolean{ var className:String; if (parent == null){ return (false); }; try { className = getQualifiedClassName(parent); } catch(e:Error) { }; return ((className == "fl.livepreview::LivePreviewParent")); } protected function focusOutHandler(_arg1:FocusEvent):void{ if (isOurFocus((_arg1.target as DisplayObject))){ drawFocus(false); isFocused = false; }; } public function set mouseFocusEnabled(_arg1:Boolean):void{ _mouseFocusEnabled = _arg1; } public function getFocus():InteractiveObject{ if (stage){ return (stage.focus); }; return (null); } protected function validate():void{ invalidHash = {}; } override public function get height():Number{ return (_height); } public function invalidate(_arg1:String="all", _arg2:Boolean=true):void{ invalidHash[_arg1] = true; if (_arg2){ this.callLater(draw); }; } public function get enabled():Boolean{ return (_enabled); } protected function getScaleX():Number{ return (super.scaleX); } protected function getScaleY():Number{ return (super.scaleY); } public function get focusEnabled():Boolean{ return (_focusEnabled); } protected function afterComponentParameters():void{ } protected function draw():void{ if (isInvalid(InvalidationType.SIZE, InvalidationType.STYLES)){ if (((isFocused) && (focusManager.showFocusIndicator))){ drawFocus(true); }; }; validate(); } protected function configUI():void{ var _local1:Number; var _local2:Number; var _local3:Number; isLivePreview = checkLivePreview(); _local1 = rotation; rotation = 0; _local2 = super.width; _local3 = super.height; var _local4 = 1; super.scaleY = _local4; super.scaleX = _local4; setSize(_local2, _local3); move(super.x, super.y); rotation = _local1; startWidth = _local2; startHeight = _local3; if (numChildren > 0){ removeChildAt(0); }; } protected function setScaleX(_arg1:Number):void{ super.scaleX = _arg1; } protected function setScaleY(_arg1:Number):void{ super.scaleY = _arg1; } private function initializeFocusManager():void{ if (stage == null){ addEventListener(Event.ADDED_TO_STAGE, addedHandler, false, 0, true); } else { createFocusManager(); }; } public function set focusManager(_arg1:IFocusManager):void{ UIComponent.focusManagers[this] = _arg1; } public function clearStyle(_arg1:String):void{ setStyle(_arg1, null); } protected function isInvalid(_arg1:String, ... _args):Boolean{ if (((invalidHash[_arg1]) || (invalidHash[InvalidationType.ALL]))){ return (true); }; while (_args.length > 0) { if (invalidHash[_args.pop()]){ return (true); }; }; return (false); } public function setSize(_arg1:Number, _arg2:Number):void{ _width = _arg1; _height = _arg2; invalidate(InvalidationType.SIZE); dispatchEvent(new ComponentEvent(ComponentEvent.RESIZE, false)); } override public function set width(_arg1:Number):void{ if (_width == _arg1){ return; }; setSize(_arg1, height); } public function setFocus():void{ if (stage){ stage.focus = this; }; } protected function initializeAccessibility():void{ if (UIComponent.createAccessibilityImplementation != null){ UIComponent.createAccessibilityImplementation(this); }; } public function get focusManager():IFocusManager{ var _local1:DisplayObject; _local1 = this; while (_local1) { if (UIComponent.focusManagers[_local1] != null){ return (IFocusManager(UIComponent.focusManagers[_local1])); }; _local1 = _local1.parent; }; return (null); } override public function get width():Number{ return (_width); } public function move(_arg1:Number, _arg2:Number):void{ _x = _arg1; _y = _arg2; super.x = Math.round(_arg1); super.y = Math.round(_arg2); dispatchEvent(new ComponentEvent(ComponentEvent.MOVE)); } public function validateNow():void{ invalidate(InvalidationType.ALL, false); draw(); } public function getStyle(_arg1:String):Object{ return (instanceStyles[_arg1]); } public static function getStyleDefinition():Object{ return (defaultStyles); } public static function mergeStyles(... _args):Object{ var _local2:Object; var _local3:uint; var _local4:uint; var _local5:Object; var _local6:String; _local2 = {}; _local3 = _args.length; _local4 = 0; while (_local4 < _local3) { _local5 = _args[_local4]; for (_local6 in _local5) { if (_local2[_local6] != null){ } else { _local2[_local6] = _args[_local4][_local6]; }; }; _local4++; }; return (_local2); } } }//package fl.core
Section 22
//ComponentEvent (fl.events.ComponentEvent) package fl.events { import flash.events.*; public class ComponentEvent extends Event { public static const HIDE:String = "hide"; public static const BUTTON_DOWN:String = "buttonDown"; public static const MOVE:String = "move"; public static const RESIZE:String = "resize"; public static const ENTER:String = "enter"; public static const LABEL_CHANGE:String = "labelChange"; public static const SHOW:String = "show"; public function ComponentEvent(_arg1:String, _arg2:Boolean=false, _arg3:Boolean=false){ super(_arg1, _arg2, _arg3); } override public function toString():String{ return (formatToString("ComponentEvent", "type", "bubbles", "cancelable")); } override public function clone():Event{ return (new ComponentEvent(type, bubbles, cancelable)); } } }//package fl.events
Section 23
//InteractionInputType (fl.events.InteractionInputType) package fl.events { public class InteractionInputType { public static const MOUSE:String = "mouse"; public static const KEYBOARD:String = "keyboard"; } }//package fl.events
Section 24
//SliderEvent (fl.events.SliderEvent) package fl.events { import flash.events.*; public class SliderEvent extends Event { protected var _triggerEvent:String; protected var _keyCode:Number; protected var _value:Number; protected var _clickTarget:String; public static const CHANGE:String = "change"; public static const THUMB_PRESS:String = "thumbPress"; public static const THUMB_DRAG:String = "thumbDrag"; public static const THUMB_RELEASE:String = "thumbRelease"; public function SliderEvent(_arg1:String, _arg2:Number, _arg3:String, _arg4:String, _arg5:int=0){ _value = _arg2; _keyCode = _arg5; _triggerEvent = _arg4; _clickTarget = _arg3; super(_arg1); } public function get clickTarget():String{ return (_clickTarget); } override public function clone():Event{ return (new SliderEvent(type, _value, _clickTarget, _triggerEvent, _keyCode)); } override public function toString():String{ return (formatToString("SliderEvent", "type", "value", "bubbles", "cancelable", "keyCode", "triggerEvent", "clickTarget")); } public function get triggerEvent():String{ return (_triggerEvent); } public function get value():Number{ return (_value); } public function get keyCode():Number{ return (_keyCode); } } }//package fl.events
Section 25
//SliderEventClickTarget (fl.events.SliderEventClickTarget) package fl.events { public class SliderEventClickTarget { public static const TRACK:String = "track"; public static const THUMB:String = "thumb"; } }//package fl.events
Section 26
//FocusManager (fl.managers.FocusManager) package fl.managers { import flash.events.*; import flash.display.*; import fl.controls.*; import fl.core.*; import flash.utils.*; import flash.text.*; import flash.ui.*; public class FocusManager implements IFocusManager { private var focusableObjects:Dictionary; private var _showFocusIndicator:Boolean;// = true private var defButton:Button; private var focusableCandidates:Array; private var _form:DisplayObjectContainer; private var _defaultButtonEnabled:Boolean;// = true private var activated:Boolean;// = false private var _defaultButton:Button; private var calculateCandidates:Boolean;// = true private var lastFocus:InteractiveObject; private var lastAction:String; public function FocusManager(_arg1:DisplayObjectContainer){ activated = false; calculateCandidates = true; _showFocusIndicator = true; _defaultButtonEnabled = true; super(); focusableObjects = new Dictionary(true); if (_arg1 != null){ _form = _arg1; addFocusables(DisplayObject(_arg1)); _arg1.addEventListener(Event.ADDED, addedHandler); _arg1.addEventListener(Event.REMOVED, removedHandler); activate(); }; } public function get showFocusIndicator():Boolean{ return (_showFocusIndicator); } private function getIndexOfNextObject(_arg1:int, _arg2:Boolean, _arg3:Boolean, _arg4:String):int{ var _local5:int; var _local6:int; var _local7:DisplayObject; var _local8:IFocusManagerGroup; var _local9:int; var _local10:DisplayObject; var _local11:IFocusManagerGroup; _local5 = focusableCandidates.length; _local6 = _arg1; while (true) { if (_arg2){ _arg1--; } else { _arg1++; }; if (_arg3){ if (((_arg2) && ((_arg1 < 0)))){ break; }; if (((!(_arg2)) && ((_arg1 == _local5)))){ break; }; } else { _arg1 = ((_arg1 + _local5) % _local5); if (_local6 == _arg1){ break; }; }; if (isValidFocusCandidate(focusableCandidates[_arg1], _arg4)){ _local7 = DisplayObject(findFocusManagerComponent(focusableCandidates[_arg1])); if ((_local7 is IFocusManagerGroup)){ _local8 = IFocusManagerGroup(_local7); _local9 = 0; while (_local9 < focusableCandidates.length) { _local10 = focusableCandidates[_local9]; if ((_local10 is IFocusManagerGroup)){ _local11 = IFocusManagerGroup(_local10); if ((((_local11.groupName == _local8.groupName)) && (_local11.selected))){ _arg1 = _local9; break; }; }; _local9++; }; }; return (_arg1); }; }; return (_arg1); } public function set form(_arg1:DisplayObjectContainer):void{ _form = _arg1; } private function addFocusables(_arg1:DisplayObject, _arg2:Boolean=false):void{ var focusable:IFocusManagerComponent; var io:InteractiveObject; var doc:DisplayObjectContainer; var i:int; var child:DisplayObject; var o = _arg1; var skipTopLevel = _arg2; if (!skipTopLevel){ if ((o is IFocusManagerComponent)){ focusable = IFocusManagerComponent(o); if (focusable.focusEnabled){ if (((focusable.tabEnabled) && (isTabVisible(o)))){ focusableObjects[o] = true; calculateCandidates = true; }; o.addEventListener(Event.TAB_ENABLED_CHANGE, tabEnabledChangeHandler); o.addEventListener(Event.TAB_INDEX_CHANGE, tabIndexChangeHandler); }; } else { if ((o is InteractiveObject)){ io = (o as InteractiveObject); if (((((io) && (io.tabEnabled))) && ((findFocusManagerComponent(io) == io)))){ focusableObjects[io] = true; calculateCandidates = true; }; io.addEventListener(Event.TAB_ENABLED_CHANGE, tabEnabledChangeHandler); io.addEventListener(Event.TAB_INDEX_CHANGE, tabIndexChangeHandler); }; }; }; if ((o is DisplayObjectContainer)){ doc = DisplayObjectContainer(o); o.addEventListener(Event.TAB_CHILDREN_CHANGE, tabChildrenChangeHandler); if ((((((doc is Stage)) || ((doc.parent is Stage)))) || (doc.tabChildren))){ i = 0; while (i < doc.numChildren) { try { child = doc.getChildAt(i); if (child != null){ addFocusables(doc.getChildAt(i)); }; } catch(error:SecurityError) { }; i = (i + 1); }; }; }; } private function getChildIndex(_arg1:DisplayObjectContainer, _arg2:DisplayObject):int{ return (_arg1.getChildIndex(_arg2)); } private function mouseFocusChangeHandler(_arg1:FocusEvent):void{ if ((_arg1.relatedObject is TextField)){ return; }; _arg1.preventDefault(); } private function focusOutHandler(_arg1:FocusEvent):void{ var _local2:InteractiveObject; _local2 = (_arg1.target as InteractiveObject); } private function isValidFocusCandidate(_arg1:DisplayObject, _arg2:String):Boolean{ var _local3:IFocusManagerGroup; if (!isEnabledAndVisible(_arg1)){ return (false); }; if ((_arg1 is IFocusManagerGroup)){ _local3 = IFocusManagerGroup(_arg1); if (_arg2 == _local3.groupName){ return (false); }; }; return (true); } public function findFocusManagerComponent(_arg1:InteractiveObject):InteractiveObject{ var _local2:InteractiveObject; _local2 = _arg1; while (_arg1) { if ((((_arg1 is IFocusManagerComponent)) && (IFocusManagerComponent(_arg1).focusEnabled))){ return (_arg1); }; _arg1 = _arg1.parent; }; return (_local2); } private function sortFocusableObjectsTabIndex():void{ var _local1:Object; var _local2:InteractiveObject; focusableCandidates = []; for (_local1 in focusableObjects) { _local2 = InteractiveObject(_local1); if (((_local2.tabIndex) && (!(isNaN(Number(_local2.tabIndex)))))){ focusableCandidates.push(_local2); }; }; focusableCandidates.sort(sortByTabIndex); } private function removeFocusables(_arg1:DisplayObject):void{ var _local2:Object; var _local3:DisplayObject; if ((_arg1 is DisplayObjectContainer)){ _arg1.removeEventListener(Event.TAB_CHILDREN_CHANGE, tabChildrenChangeHandler); _arg1.removeEventListener(Event.TAB_INDEX_CHANGE, tabIndexChangeHandler); for (_local2 in focusableObjects) { _local3 = DisplayObject(_local2); if (DisplayObjectContainer(_arg1).contains(_local3)){ if (_local3 == lastFocus){ lastFocus = null; }; _local3.removeEventListener(Event.TAB_ENABLED_CHANGE, tabEnabledChangeHandler); delete focusableObjects[_local2]; calculateCandidates = true; }; }; }; } private function addedHandler(_arg1:Event):void{ var _local2:DisplayObject; _local2 = DisplayObject(_arg1.target); if (_local2.stage){ addFocusables(DisplayObject(_arg1.target)); }; } private function getTopLevelFocusTarget(_arg1:InteractiveObject):InteractiveObject{ while (_arg1 != InteractiveObject(form)) { if ((((((((_arg1 is IFocusManagerComponent)) && (IFocusManagerComponent(_arg1).focusEnabled))) && (IFocusManagerComponent(_arg1).mouseFocusEnabled))) && (UIComponent(_arg1).enabled))){ return (_arg1); }; _arg1 = _arg1.parent; if (_arg1 == null){ break; }; }; return (null); } private function tabChildrenChangeHandler(_arg1:Event):void{ var _local2:DisplayObjectContainer; if (_arg1.target != _arg1.currentTarget){ return; }; calculateCandidates = true; _local2 = DisplayObjectContainer(_arg1.target); if (_local2.tabChildren){ addFocusables(_local2, true); } else { removeFocusables(_local2); }; } public function sendDefaultButtonEvent():void{ defButton.dispatchEvent(new MouseEvent(MouseEvent.CLICK)); } public function getFocus():InteractiveObject{ var _local1:InteractiveObject; _local1 = form.stage.focus; return (findFocusManagerComponent(_local1)); } private function isEnabledAndVisible(_arg1:DisplayObject):Boolean{ var _local2:DisplayObjectContainer; var _local3:TextField; var _local4:SimpleButton; _local2 = DisplayObject(form).parent; while (_arg1 != _local2) { if ((_arg1 is UIComponent)){ if (!UIComponent(_arg1).enabled){ return (false); }; } else { if ((_arg1 is TextField)){ _local3 = TextField(_arg1); if ((((_local3.type == TextFieldType.DYNAMIC)) || (!(_local3.selectable)))){ return (false); }; } else { if ((_arg1 is SimpleButton)){ _local4 = SimpleButton(_arg1); if (!_local4.enabled){ return (false); }; }; }; }; if (!_arg1.visible){ return (false); }; _arg1 = _arg1.parent; }; return (true); } public function set defaultButton(_arg1:Button):void{ var _local2:Button; _local2 = (_arg1) ? Button(_arg1) : null; if (_local2 != _defaultButton){ if (_defaultButton){ _defaultButton.emphasized = false; }; if (defButton){ defButton.emphasized = false; }; _defaultButton = _local2; defButton = _local2; if (_local2){ _local2.emphasized = true; }; }; } private function deactivateHandler(_arg1:Event):void{ var _local2:InteractiveObject; _local2 = InteractiveObject(_arg1.target); } public function setFocus(_arg1:InteractiveObject):void{ if ((_arg1 is IFocusManagerComponent)){ IFocusManagerComponent(_arg1).setFocus(); } else { form.stage.focus = _arg1; }; } private function setFocusToNextObject(_arg1:FocusEvent):void{ var _local2:InteractiveObject; if (!hasFocusableObjects()){ return; }; _local2 = getNextFocusManagerComponent(_arg1.shiftKey); if (_local2){ setFocus(_local2); }; } private function hasFocusableObjects():Boolean{ var _local1:Object; for (_local1 in focusableObjects) { return (true); }; return (false); } private function tabIndexChangeHandler(_arg1:Event):void{ calculateCandidates = true; } private function sortFocusableObjects():void{ var _local1:Object; var _local2:InteractiveObject; focusableCandidates = []; for (_local1 in focusableObjects) { _local2 = InteractiveObject(_local1); if (((((_local2.tabIndex) && (!(isNaN(Number(_local2.tabIndex)))))) && ((_local2.tabIndex > 0)))){ sortFocusableObjectsTabIndex(); return; }; focusableCandidates.push(_local2); }; focusableCandidates.sort(sortByDepth); } private function keyFocusChangeHandler(_arg1:FocusEvent):void{ showFocusIndicator = true; if ((((((_arg1.keyCode == Keyboard.TAB)) || ((_arg1.keyCode == 0)))) && (!(_arg1.isDefaultPrevented())))){ setFocusToNextObject(_arg1); _arg1.preventDefault(); }; } private function getIndexOfFocusedObject(_arg1:DisplayObject):int{ var _local2:int; var _local3:int; _local2 = focusableCandidates.length; _local3 = 0; _local3 = 0; while (_local3 < _local2) { if (focusableCandidates[_local3] == _arg1){ return (_local3); }; _local3++; }; return (-1); } public function hideFocus():void{ } private function removedHandler(_arg1:Event):void{ var _local2:int; var _local3:DisplayObject; var _local4:InteractiveObject; _local3 = DisplayObject(_arg1.target); if ((((_local3 is IFocusManagerComponent)) && ((focusableObjects[_local3] == true)))){ if (_local3 == lastFocus){ IFocusManagerComponent(lastFocus).drawFocus(false); lastFocus = null; }; _local3.removeEventListener(Event.TAB_ENABLED_CHANGE, tabEnabledChangeHandler); delete focusableObjects[_local3]; calculateCandidates = true; } else { if ((((_local3 is InteractiveObject)) && ((focusableObjects[_local3] == true)))){ _local4 = (_local3 as InteractiveObject); if (_local4){ if (_local4 == lastFocus){ lastFocus = null; }; delete focusableObjects[_local4]; calculateCandidates = true; }; _local3.addEventListener(Event.TAB_ENABLED_CHANGE, tabEnabledChangeHandler); }; }; removeFocusables(_local3); } private function sortByDepth(_arg1:InteractiveObject, _arg2:InteractiveObject):Number{ var _local3:String; var _local4:String; var _local5:int; var _local6:String; var _local7:String; var _local8:String; var _local9:DisplayObject; var _local10:DisplayObject; _local3 = ""; _local4 = ""; _local8 = "0000"; _local9 = DisplayObject(_arg1); _local10 = DisplayObject(_arg2); while (((!((_local9 == DisplayObject(form)))) && (_local9.parent))) { _local5 = getChildIndex(_local9.parent, _local9); _local6 = _local5.toString(16); if (_local6.length < 4){ _local7 = (_local8.substring(0, (4 - _local6.length)) + _local6); }; _local3 = (_local7 + _local3); _local9 = _local9.parent; }; while (((!((_local10 == DisplayObject(form)))) && (_local10.parent))) { _local5 = getChildIndex(_local10.parent, _local10); _local6 = _local5.toString(16); if (_local6.length < 4){ _local7 = (_local8.substring(0, (4 - _local6.length)) + _local6); }; _local4 = (_local7 + _local4); _local10 = _local10.parent; }; return (((_local3 > _local4)) ? 1 : ((_local3 < _local4)) ? -1 : 0); } public function get defaultButton():Button{ return (_defaultButton); } private function activateHandler(_arg1:Event):void{ var _local2:InteractiveObject; _local2 = InteractiveObject(_arg1.target); if (lastFocus){ if ((lastFocus is IFocusManagerComponent)){ IFocusManagerComponent(lastFocus).setFocus(); } else { form.stage.focus = lastFocus; }; }; lastAction = "ACTIVATE"; } public function showFocus():void{ } public function set defaultButtonEnabled(_arg1:Boolean):void{ _defaultButtonEnabled = _arg1; } public function getNextFocusManagerComponent(_arg1:Boolean=false):InteractiveObject{ var _local2:DisplayObject; var _local3:String; var _local4:int; var _local5:Boolean; var _local6:int; var _local7:int; var _local8:IFocusManagerGroup; if (!hasFocusableObjects()){ return (null); }; if (calculateCandidates){ sortFocusableObjects(); calculateCandidates = false; }; _local2 = form.stage.focus; _local2 = DisplayObject(findFocusManagerComponent(InteractiveObject(_local2))); _local3 = ""; if ((_local2 is IFocusManagerGroup)){ _local8 = IFocusManagerGroup(_local2); _local3 = _local8.groupName; }; _local4 = getIndexOfFocusedObject(_local2); _local5 = false; _local6 = _local4; if (_local4 == -1){ if (_arg1){ _local4 = focusableCandidates.length; }; _local5 = true; }; _local7 = getIndexOfNextObject(_local4, _arg1, _local5, _local3); return (findFocusManagerComponent(focusableCandidates[_local7])); } private function mouseDownHandler(_arg1:MouseEvent):void{ var _local2:InteractiveObject; if (_arg1.isDefaultPrevented()){ return; }; _local2 = getTopLevelFocusTarget(InteractiveObject(_arg1.target)); if (!_local2){ return; }; showFocusIndicator = false; if (((((!((_local2 == lastFocus))) || ((lastAction == "ACTIVATE")))) && (!((_local2 is TextField))))){ setFocus(_local2); }; lastAction = "MOUSEDOWN"; } private function isTabVisible(_arg1:DisplayObject):Boolean{ var _local2:DisplayObjectContainer; _local2 = _arg1.parent; while (((((_local2) && (!((_local2 is Stage))))) && (!(((_local2.parent) && ((_local2.parent is Stage))))))) { if (!_local2.tabChildren){ return (false); }; _local2 = _local2.parent; }; return (true); } public function get nextTabIndex():int{ return (0); } private function keyDownHandler(_arg1:KeyboardEvent):void{ if (_arg1.keyCode == Keyboard.TAB){ lastAction = "KEY"; if (calculateCandidates){ sortFocusableObjects(); calculateCandidates = false; }; }; if (((((((defaultButtonEnabled) && ((_arg1.keyCode == Keyboard.ENTER)))) && (defaultButton))) && (defButton.enabled))){ sendDefaultButtonEvent(); }; } private function focusInHandler(_arg1:FocusEvent):void{ var _local2:InteractiveObject; var _local3:Button; _local2 = InteractiveObject(_arg1.target); if (form.contains(_local2)){ lastFocus = findFocusManagerComponent(InteractiveObject(_local2)); if ((lastFocus is Button)){ _local3 = Button(lastFocus); if (defButton){ defButton.emphasized = false; defButton = _local3; _local3.emphasized = true; }; } else { if (((defButton) && (!((defButton == _defaultButton))))){ defButton.emphasized = false; defButton = _defaultButton; _defaultButton.emphasized = true; }; }; }; } private function tabEnabledChangeHandler(_arg1:Event):void{ var _local2:InteractiveObject; var _local3:Boolean; calculateCandidates = true; _local2 = InteractiveObject(_arg1.target); _local3 = (focusableObjects[_local2] == true); if (_local2.tabEnabled){ if (((!(_local3)) && (isTabVisible(_local2)))){ if (!(_local2 is IFocusManagerComponent)){ _local2.focusRect = false; }; focusableObjects[_local2] = true; }; } else { if (_local3){ delete focusableObjects[_local2]; }; }; } public function set showFocusIndicator(_arg1:Boolean):void{ _showFocusIndicator = _arg1; } public function get form():DisplayObjectContainer{ return (_form); } private function sortByTabIndex(_arg1:InteractiveObject, _arg2:InteractiveObject):int{ return (((_arg1.tabIndex > _arg2.tabIndex)) ? 1 : ((_arg1.tabIndex < _arg2.tabIndex)) ? -1 : sortByDepth(_arg1, _arg2)); } public function activate():void{ if (activated){ return; }; form.stage.addEventListener(FocusEvent.MOUSE_FOCUS_CHANGE, mouseFocusChangeHandler, false, 0, true); form.stage.addEventListener(FocusEvent.KEY_FOCUS_CHANGE, keyFocusChangeHandler, false, 0, true); form.addEventListener(FocusEvent.FOCUS_IN, focusInHandler, true); form.addEventListener(FocusEvent.FOCUS_OUT, focusOutHandler, true); form.stage.addEventListener(Event.ACTIVATE, activateHandler, false, 0, true); form.stage.addEventListener(Event.DEACTIVATE, deactivateHandler, false, 0, true); form.addEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler); form.addEventListener(KeyboardEvent.KEY_DOWN, keyDownHandler, true); activated = true; if (lastFocus){ setFocus(lastFocus); }; } public function deactivate():void{ form.stage.removeEventListener(FocusEvent.MOUSE_FOCUS_CHANGE, mouseFocusChangeHandler); form.stage.removeEventListener(FocusEvent.KEY_FOCUS_CHANGE, keyFocusChangeHandler); form.removeEventListener(FocusEvent.FOCUS_IN, focusInHandler, true); form.removeEventListener(FocusEvent.FOCUS_OUT, focusOutHandler, true); form.stage.removeEventListener(Event.ACTIVATE, activateHandler); form.stage.removeEventListener(Event.DEACTIVATE, deactivateHandler); form.removeEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler); form.removeEventListener(KeyboardEvent.KEY_DOWN, keyDownHandler, true); activated = false; } public function get defaultButtonEnabled():Boolean{ return (_defaultButtonEnabled); } } }//package fl.managers
Section 27
//IFocusManager (fl.managers.IFocusManager) package fl.managers { import flash.display.*; import fl.controls.*; public interface IFocusManager { function getFocus():InteractiveObject; function deactivate():void; function set defaultButton(_arg1:Button):void; function set showFocusIndicator(_arg1:Boolean):void; function get defaultButtonEnabled():Boolean; function get nextTabIndex():int; function get defaultButton():Button; function get showFocusIndicator():Boolean; function setFocus(_arg1:InteractiveObject):void; function activate():void; function showFocus():void; function set defaultButtonEnabled(_arg1:Boolean):void; function hideFocus():void; function findFocusManagerComponent(_arg1:InteractiveObject):InteractiveObject; function getNextFocusManagerComponent(_arg1:Boolean=false):InteractiveObject; } }//package fl.managers
Section 28
//IFocusManagerComponent (fl.managers.IFocusManagerComponent) package fl.managers { public interface IFocusManagerComponent { function set focusEnabled(_arg1:Boolean):void; function drawFocus(_arg1:Boolean):void; function setFocus():void; function get focusEnabled():Boolean; function get tabEnabled():Boolean; function get tabIndex():int; function get mouseFocusEnabled():Boolean; } }//package fl.managers
Section 29
//IFocusManagerGroup (fl.managers.IFocusManagerGroup) package fl.managers { public interface IFocusManagerGroup { function set groupName(_arg1:String):void; function set selected(_arg1:Boolean):void; function get groupName():String; function get selected():Boolean; } }//package fl.managers
Section 30
//StyleManager (fl.managers.StyleManager) package fl.managers { import fl.core.*; import flash.utils.*; import flash.text.*; public class StyleManager { private var globalStyles:Object; private var classToDefaultStylesDict:Dictionary; private var styleToClassesHash:Object; private var classToStylesDict:Dictionary; private var classToInstancesDict:Dictionary; private static var _instance:StyleManager; public function StyleManager(){ styleToClassesHash = {}; classToInstancesDict = new Dictionary(true); classToStylesDict = new Dictionary(true); classToDefaultStylesDict = new Dictionary(true); globalStyles = UIComponent.getStyleDefinition(); } public static function clearComponentStyle(_arg1:Object, _arg2:String):void{ var _local3:Class; var _local4:Object; _local3 = getClassDef(_arg1); _local4 = getInstance().classToStylesDict[_local3]; if (((!((_local4 == null))) && (!((_local4[_arg2] == null))))){ delete _local4[_arg2]; invalidateComponentStyle(_local3, _arg2); }; } private static function getClassDef(_arg1:Object):Class{ var component = _arg1; if ((component is Class)){ return ((component as Class)); }; try { return ((getDefinitionByName(getQualifiedClassName(component)) as Class)); } catch(e:Error) { if ((component is UIComponent)){ try { return ((component.loaderInfo.applicationDomain.getDefinition(getQualifiedClassName(component)) as Class)); } catch(e:Error) { }; }; }; return (null); } public static function clearStyle(_arg1:String):void{ setStyle(_arg1, null); } public static function setComponentStyle(_arg1:Object, _arg2:String, _arg3:Object):void{ var _local4:Class; var _local5:Object; _local4 = getClassDef(_arg1); _local5 = getInstance().classToStylesDict[_local4]; if (_local5 == null){ _local5 = (getInstance().classToStylesDict[_local4] = {}); }; if (_local5 == _arg3){ return; }; _local5[_arg2] = _arg3; invalidateComponentStyle(_local4, _arg2); } private static function setSharedStyles(_arg1:UIComponent):void{ var _local2:StyleManager; var _local3:Class; var _local4:Object; var _local5:String; _local2 = getInstance(); _local3 = getClassDef(_arg1); _local4 = _local2.classToDefaultStylesDict[_local3]; for (_local5 in _local4) { _arg1.setSharedStyle(_local5, getSharedStyle(_arg1, _local5)); }; } public static function getComponentStyle(_arg1:Object, _arg2:String):Object{ var _local3:Class; var _local4:Object; _local3 = getClassDef(_arg1); _local4 = getInstance().classToStylesDict[_local3]; return (((_local4)==null) ? null : _local4[_arg2]); } private static function getInstance(){ if (_instance == null){ _instance = new (StyleManager); }; return (_instance); } private static function invalidateComponentStyle(_arg1:Class, _arg2:String):void{ var _local3:Dictionary; var _local4:Object; var _local5:UIComponent; _local3 = getInstance().classToInstancesDict[_arg1]; if (_local3 == null){ return; }; for (_local4 in _local3) { _local5 = (_local4 as UIComponent); if (_local5 == null){ } else { _local5.setSharedStyle(_arg2, getSharedStyle(_local5, _arg2)); }; }; } private static function invalidateStyle(_arg1:String):void{ var _local2:Dictionary; var _local3:Object; _local2 = getInstance().styleToClassesHash[_arg1]; if (_local2 == null){ return; }; for (_local3 in _local2) { invalidateComponentStyle(Class(_local3), _arg1); }; } public static function registerInstance(_arg1:UIComponent):void{ var inst:StyleManager; var classDef:Class; var target:Class; var defaultStyles:Object; var styleToClasses:Object; var n:String; var instance = _arg1; inst = getInstance(); classDef = getClassDef(instance); if (classDef == null){ return; }; if (inst.classToInstancesDict[classDef] == null){ inst.classToInstancesDict[classDef] = new Dictionary(true); target = classDef; while (defaultStyles == null) { if (target["getStyleDefinition"] != null){ defaultStyles = target["getStyleDefinition"](); break; }; try { target = (instance.loaderInfo.applicationDomain.getDefinition(getQualifiedSuperclassName(target)) as Class); } catch(err:Error) { try { target = (getDefinitionByName(getQualifiedSuperclassName(target)) as Class); } catch(e:Error) { defaultStyles = UIComponent.getStyleDefinition(); break; }; }; }; styleToClasses = inst.styleToClassesHash; for (n in defaultStyles) { if (styleToClasses[n] == null){ styleToClasses[n] = new Dictionary(true); }; styleToClasses[n][classDef] = true; }; inst.classToDefaultStylesDict[classDef] = defaultStyles; inst.classToStylesDict[classDef] = {}; }; inst.classToInstancesDict[classDef][instance] = true; setSharedStyles(instance); } public static function getStyle(_arg1:String):Object{ return (getInstance().globalStyles[_arg1]); } private static function getSharedStyle(_arg1:UIComponent, _arg2:String):Object{ var _local3:Class; var _local4:StyleManager; var _local5:Object; _local3 = getClassDef(_arg1); _local4 = getInstance(); _local5 = _local4.classToStylesDict[_local3][_arg2]; if (_local5 != null){ return (_local5); }; _local5 = _local4.globalStyles[_arg2]; if (_local5 != null){ return (_local5); }; return (_local4.classToDefaultStylesDict[_local3][_arg2]); } public static function setStyle(_arg1:String, _arg2:Object):void{ var _local3:Object; _local3 = getInstance().globalStyles; if ((((_local3[_arg1] === _arg2)) && (!((_arg2 is TextFormat))))){ return; }; _local3[_arg1] = _arg2; invalidateStyle(_arg1); } } }//package fl.managers
Section 31
//ag_intro_mc_115 (windkingdom_armor_fla.ag_intro_mc_115) package windkingdom_armor_fla { import flash.display.*; public dynamic class ag_intro_mc_115 extends MovieClip { public function ag_intro_mc_115(){ addFrameScript(0, frame1, 217, frame218); } function frame218(){ stop(); } function frame1(){ gotoAndPlay(2); } } }//package windkingdom_armor_fla
Section 32
//armor_promo_3 (windkingdom_armor_fla.armor_promo_3) package windkingdom_armor_fla { import flash.display.*; public dynamic class armor_promo_3 extends MovieClip { public function armor_promo_3(){ addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package windkingdom_armor_fla
Section 33
//btupgradecastle_155 (windkingdom_armor_fla.btupgradecastle_155) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgradecastle_155 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 34
//btupgradecopter_158 (windkingdom_armor_fla.btupgradecopter_158) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgradecopter_158 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 35
//btupgradedragon_161 (windkingdom_armor_fla.btupgradedragon_161) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgradedragon_161 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 36
//btupgradeeagle_159 (windkingdom_armor_fla.btupgradeeagle_159) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgradeeagle_159 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 37
//btupgradefireturret_163 (windkingdom_armor_fla.btupgradefireturret_163) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgradefireturret_163 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 38
//btupgradeiceturret_162 (windkingdom_armor_fla.btupgradeiceturret_162) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgradeiceturret_162 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 39
//btupgradeinitialmanabank_168 (windkingdom_armor_fla.btupgradeinitialmanabank_168) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgradeinitialmanabank_168 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 40
//btupgrademanaregeneratetime_167 (windkingdom_armor_fla.btupgrademanaregeneratetime_167) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgrademanaregeneratetime_167 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 41
//btupgradepanzer_160 (windkingdom_armor_fla.btupgradepanzer_160) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgradepanzer_160 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 42
//btupgraderider_157 (windkingdom_armor_fla.btupgraderider_157) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgraderider_157 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 43
//btupgradethunderturret_164 (windkingdom_armor_fla.btupgradethunderturret_164) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgradethunderturret_164 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 44
//btupgradeturretcreatetime_166 (windkingdom_armor_fla.btupgradeturretcreatetime_166) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgradeturretcreatetime_166 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 45
//btupgradeunitcreatetime_165 (windkingdom_armor_fla.btupgradeunitcreatetime_165) package windkingdom_armor_fla { import flash.display.*; public dynamic class btupgradeunitcreatetime_165 extends MovieClip { public var locker:MovieClip; } }//package windkingdom_armor_fla
Section 46
//health_90 (windkingdom_armor_fla.health_90) package windkingdom_armor_fla { import flash.display.*; public dynamic class health_90 extends MovieClip { public function health_90(){ addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package windkingdom_armor_fla
Section 47
//iconspecialattack_68 (windkingdom_armor_fla.iconspecialattack_68) package windkingdom_armor_fla { import flash.display.*; public dynamic class iconspecialattack_68 extends MovieClip { public var powermeter:MovieClip; } }//package windkingdom_armor_fla
Section 48
//instructionnotes_126 (windkingdom_armor_fla.instructionnotes_126) package windkingdom_armor_fla { import flash.display.*; public dynamic class instructionnotes_126 extends MovieClip { public var btunits:SimpleButton; public var btgameplay:SimpleButton; public var btbattle:SimpleButton; public var btupgrade:SimpleButton; public var btexp:SimpleButton; public var btshortcuts:SimpleButton; public function instructionnotes_126(){ addFrameScript(0, frame1, 10, frame11, 20, frame21, 30, frame31, 40, frame41, 50, frame51); } function frame1(){ stop(); } function frame21(){ stop(); } function frame11(){ stop(); } function frame31(){ stop(); } function frame41(){ stop(); } function frame51(){ stop(); } } }//package windkingdom_armor_fla
Section 49
//lv1_22 (windkingdom_armor_fla.lv1_22) package windkingdom_armor_fla { import flash.display.*; public dynamic class lv1_22 extends MovieClip { public var c1:MovieClip; public var c2:MovieClip; public function lv1_22(){ addFrameScript(0, frame1, 20, frame21); } function frame1(){ stop(); } function frame21(){ gotoAndPlay(2); } } }//package windkingdom_armor_fla
Section 50
//lv2_31 (windkingdom_armor_fla.lv2_31) package windkingdom_armor_fla { import flash.display.*; public dynamic class lv2_31 extends MovieClip { public var c1:MovieClip; public var c3:MovieClip; public var c2:MovieClip; public function lv2_31(){ addFrameScript(0, frame1, 20, frame21); } function frame1(){ stop(); } function frame21(){ gotoAndPlay(2); } } }//package windkingdom_armor_fla
Section 51
//lv3_33 (windkingdom_armor_fla.lv3_33) package windkingdom_armor_fla { import flash.display.*; public dynamic class lv3_33 extends MovieClip { public var c1:MovieClip; public var c3:MovieClip; public var c4:MovieClip; public var c5:MovieClip; public var c2:MovieClip; public function lv3_33(){ addFrameScript(0, frame1, 20, frame21); } function frame21(){ gotoAndPlay(2); } function frame1(){ stop(); } } }//package windkingdom_armor_fla
Section 52
//MainTimeline (windkingdom_armor_fla.MainTimeline) package windkingdom_armor_fla { import flash.events.*; import flash.display.*; import flash.utils.*; import flash.net.*; import flash.media.*; import flash.system.*; import flash.text.*; import flash.ui.*; import flash.errors.*; import adobe.utils.*; import flash.accessibility.*; import flash.external.*; import flash.filters.*; import flash.geom.*; import flash.printing.*; import flash.xml.*; public dynamic class MainTimeline extends MovieClip { public var upgradewarning:MovieClip; public var tutorial_mc:MovieClip; public var btupgradedragon:MovieClip; public var ad:DisplayObject; public var result:MovieClip; public var btupgradecopter:MovieClip; public var btarmor:SimpleButton; public var btloadgame:SimpleButton; public var addGameURL:URLRequest; public var btupgradeturretcreatetime:MovieClip; public var btupgradeunitcreatetime:MovieClip; public var soundMgr; public var btplay:SimpleButton; public var CPMStarContentSpotID:String; public var adBox:MovieClip; public var ep:TextField; public var playbtn:SimpleButton; public var btupgrademanaregeneratetime:MovieClip; public var btupgradeeagle:MovieClip; public var armorbtn:SimpleButton; public var gameData; public var gameMgr; public var btplaymore:SimpleButton; public var btmainmenu:SimpleButton; public var btupgradeiceturret:MovieClip; public var btstatistics:SimpleButton; public var btinstructions:SimpleButton; public var btupgradecastle:MovieClip; public var unlocked; public var obj; public var moreGameURL:URLRequest; public var artbtn:MovieClip; public var myMenu; public var btupgradepanzer:MovieClip; public var btupgraderider:MovieClip; public var locker; public var skipmochibot; public var btsavegame:SimpleButton; public var btcancel:SimpleButton; public var mc_armor:MovieClip; public var btday3:SimpleButton; public var btday4:SimpleButton; public var btday5:SimpleButton; public var btday7:SimpleButton; public var btday8:SimpleButton; public var btday6:SimpleButton; public var btday1:SimpleButton; public var btday2:SimpleButton; public var btupgradeinitialmanabank:MovieClip; public var item2:ContextMenuItem; public var btaddgame:SimpleButton; public var levelnote:MovieClip; public var instructionnote:MovieClip; public var btupgrade:SimpleButton; public var btupgradethunderturret:MovieClip; public var mcpreloader:MovieClip; public var selectedLevel; public var adsbtn:MovieClip; public var btupgradefireturret:MovieClip; public var item1:ContextMenuItem; public var txt1:TextField; public var txt2:TextField; public var txt3:TextField; public var txt5:TextField; public var txt8:TextField; public var txt9:TextField; public var txt6:TextField; public var txt7:TextField; public var btcredit:SimpleButton; public var txt4:TextField; public var panelnote:MovieClip; public function MainTimeline(){ addFrameScript(0, frame1, 1, frame2, 2, frame3, 3, frame4, 4, frame5, 5, frame6, 7, frame8, 9, frame10, 13, frame14, 23, frame24, 33, frame34, 43, frame44, 53, frame54, 63, frame64, 73, frame74, 83, frame84, 93, frame94, 103, frame104, 113, frame114, 123, frame124, 134, frame135); } public function goCredit(_arg1=null){ gotoAndPlay("credits"); } public function startUpgradeListeners(){ btupgradecastle.addEventListener(MouseEvent.CLICK, upgradeCastleClick); btupgradeiceturret.addEventListener(MouseEvent.CLICK, upgradeIceTurretClick); btupgradefireturret.addEventListener(MouseEvent.CLICK, upgradeFireTurretClick); btupgradethunderturret.addEventListener(MouseEvent.CLICK, upgradeThunderTurretClick); btupgraderider.addEventListener(MouseEvent.CLICK, upgradeRiderClick); btupgradecopter.addEventListener(MouseEvent.CLICK, upgradeCopterClick); btupgradeeagle.addEventListener(MouseEvent.CLICK, upgradeEagleClick); btupgradepanzer.addEventListener(MouseEvent.CLICK, upgradePanzerClick); btupgradedragon.addEventListener(MouseEvent.CLICK, upgradeDragonClick); btupgradeunitcreatetime.addEventListener(MouseEvent.CLICK, upgradeUnitCreateTimeClick); btupgradeturretcreatetime.addEventListener(MouseEvent.CLICK, upgradeTurretCreateTimeClick); btupgrademanaregeneratetime.addEventListener(MouseEvent.CLICK, upgradeManaRegenerateTimeClick); btupgradeinitialmanabank.addEventListener(MouseEvent.CLICK, upgradeInitialManaBankClick); btupgradecastle.addEventListener(MouseEvent.MOUSE_OVER, upgradeCastleOver); btupgradeiceturret.addEventListener(MouseEvent.MOUSE_OVER, upgradeIceTurretOver); btupgradefireturret.addEventListener(MouseEvent.MOUSE_OVER, upgradeFireTurretOver); btupgradethunderturret.addEventListener(MouseEvent.MOUSE_OVER, upgradeThunderTurretOver); btupgraderider.addEventListener(MouseEvent.MOUSE_OVER, upgradeRiderOver); btupgradecopter.addEventListener(MouseEvent.MOUSE_OVER, upgradeCopterOver); btupgradeeagle.addEventListener(MouseEvent.MOUSE_OVER, upgradeEagleOver); btupgradepanzer.addEventListener(MouseEvent.MOUSE_OVER, upgradePanzerOver); btupgradedragon.addEventListener(MouseEvent.MOUSE_OVER, upgradeDragonOver); btupgradeunitcreatetime.addEventListener(MouseEvent.MOUSE_OVER, upgradeUnitCreateTimeOver); btupgradeturretcreatetime.addEventListener(MouseEvent.MOUSE_OVER, upgradeTurretCreateTimeOver); btupgrademanaregeneratetime.addEventListener(MouseEvent.MOUSE_OVER, upgradeManaRegenerateTimeOver); btupgradeinitialmanabank.addEventListener(MouseEvent.MOUSE_OVER, upgradeInitialManaBankOver); btupgradecastle.addEventListener(MouseEvent.MOUSE_OUT, upgradeCastleOut); btupgradeiceturret.addEventListener(MouseEvent.MOUSE_OUT, upgradeIceTurretOut); btupgradefireturret.addEventListener(MouseEvent.MOUSE_OUT, upgradeFireTurretOut); btupgradethunderturret.addEventListener(MouseEvent.MOUSE_OUT, upgradeThunderTurretOut); btupgraderider.addEventListener(MouseEvent.MOUSE_OUT, upgradeRiderOut); btupgradecopter.addEventListener(MouseEvent.MOUSE_OUT, upgradeCopterOut); btupgradeeagle.addEventListener(MouseEvent.MOUSE_OUT, upgradeEagleOut); btupgradepanzer.addEventListener(MouseEvent.MOUSE_OUT, upgradePanzerOut); btupgradedragon.addEventListener(MouseEvent.MOUSE_OUT, upgradeDragonOut); btupgradeunitcreatetime.addEventListener(MouseEvent.MOUSE_OUT, upgradeUnitCreateTimeOut); btupgradeturretcreatetime.addEventListener(MouseEvent.MOUSE_OUT, upgradeTurretCreateTimeOut); btupgrademanaregeneratetime.addEventListener(MouseEvent.MOUSE_OUT, upgradeManaRegenerateTimeOut); btupgradeinitialmanabank.addEventListener(MouseEvent.MOUSE_OUT, upgradeInitialManaBankOut); } public function upgradeFireTurretOver(_arg1=null){ showNote("fireturret"); } public function gotoArt(_arg1=null){ navigateToURL(new URLRequest("http://www.artlogicgames.com"), "_blank"); } public function upgradeIceTurretOver(_arg1=null){ showNote("iceturret"); } public function upgradeThunderTurretOut(_arg1=null){ hideNote(); } public function upgradePanzerOver(_arg1=null){ showNote("panzer"); } public function goSaveGame(_arg1=null){ gotoAndPlay("savegame"); } public function upgradeManaRegenerateTimeOver(_arg1=null){ showNote("manaregeneratetime"); } public function refreshButtons(){ ep.text = String(Math.floor(gameData.experienceTotal)); btupgradecastle.gotoAndStop((gameData.castleLevel + 1)); btupgradeiceturret.gotoAndStop((gameData.turretsLevel[0] + 1)); btupgradefireturret.gotoAndStop((gameData.turretsLevel[1] + 1)); btupgradethunderturret.gotoAndStop((gameData.turretsLevel[2] + 1)); btupgraderider.gotoAndStop((gameData.unitsLevel[0] + 1)); btupgradecopter.gotoAndStop((gameData.unitsLevel[1] + 1)); btupgradeeagle.gotoAndStop((gameData.unitsLevel[2] + 1)); btupgradepanzer.gotoAndStop((gameData.unitsLevel[3] + 1)); btupgradedragon.gotoAndStop((gameData.unitsLevel[4] + 1)); btupgradeunitcreatetime.gotoAndStop(gameData.unitsCreationTimerLevel); btupgradeturretcreatetime.gotoAndStop(gameData.turretsCreationTimerLevel); btupgrademanaregeneratetime.gotoAndStop(gameData.manaRegenerationLevel); btupgradeinitialmanabank.gotoAndStop(gameData.manaCountLevel); } public function upgradeIceTurretClick(_arg1=null){ if (gameData.isTurretsLevelUpgradable("iceturret")){ gameData.increaseTurretsLevel("iceturret"); refreshButtons(); showNote("iceturret"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } public function removeLevelListener(){ } public function upgradeIceTurretOut(_arg1=null){ hideNote(); } public function upgradeThunderTurretClick(_arg1=null){ if (gameData.isTurretsLevelUpgradable("thunderturret")){ gameData.increaseTurretsLevel("thunderturret"); refreshButtons(); showNote("thunderturret"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } public function upgradeInitialManaBankOver(_arg1=null){ showNote("initialmanabank"); } public function upgradeUnitCreateTimeOver(_arg1=null){ showNote("unitcreatetime"); } public function showResults(){ result.txt1.text = gameData.levelUnitsBuilt[4]; result.txt2.text = gameData.levelUnitsBuilt[3]; result.txt3.text = gameData.levelUnitsBuilt[2]; result.txt4.text = gameData.levelUnitsBuilt[1]; result.txt5.text = gameData.levelUnitsBuilt[0]; result.txt6.text = gameData.levelTurretsBuilt[0]; result.txt7.text = gameData.levelTurretsBuilt[1]; result.txt8.text = gameData.levelTurretsBuilt[2]; result.txt9.text = gameData.levelEnemyKilled[6]; result.txt10.text = gameData.levelEnemyKilled[5]; result.txt11.text = gameData.levelEnemyKilled[4]; result.txt12.text = gameData.levelEnemyKilled[3]; result.txt13.text = gameData.levelEnemyKilled[2]; result.txt14.text = gameData.levelEnemyKilled[1]; result.txt15.text = gameData.levelEnemyKilled[0]; result.txt16.text = Math.floor(gameData.levelExperience); } function frame10(){ soundMgr.playBGM("cover"); btplay.addEventListener(MouseEvent.CLICK, goNewGame); btplaymore.addEventListener(MouseEvent.CLICK, playMoreGames); btaddgame.addEventListener(MouseEvent.CLICK, addGames); btloadgame.addEventListener(MouseEvent.CLICK, goLoadGame); btcredit.addEventListener(MouseEvent.CLICK, goCredit); btarmor.addEventListener(MouseEvent.CLICK, gotoArmor); stop(); } function frame14(){ soundMgr.playBGM("intro"); btcancel.addEventListener(MouseEvent.CLICK, goLevelSelect); instructionnote.btgameplay.addEventListener(MouseEvent.CLICK, showInstruction1); instructionnote.btshortcuts.addEventListener(MouseEvent.CLICK, showInstruction2); instructionnote.btunits.addEventListener(MouseEvent.CLICK, showInstruction3); instructionnote.btexp.addEventListener(MouseEvent.CLICK, showInstruction4); instructionnote.btbattle.addEventListener(MouseEvent.CLICK, showInstruction5); instructionnote.btupgrade.addEventListener(MouseEvent.CLICK, showInstruction6); showInstructionNote(1); stop(); } public function upgradeFireTurretOut(_arg1=null){ hideNote(); } public function hideNote(){ panelnote.visible = false; panelnote.gotoAndStop(1); } function frame3(){ mc_armor.addEventListener(MouseEvent.CLICK, gotoArmor); stage.addEventListener(Event.ENTER_FRAME, FinishLogo); stop(); } function frame4(){ if (!unlocked){ gotoAndStop("locked"); }; } function frame5(){ if (!unlocked){ gotoAndStop("locked"); }; } public function upgradeEagleOver(_arg1=null){ showNote("eagle"); } public function upgradeRiderClick(_arg1=null){ if (gameData.isUnitsLevelUpgradable("rider")){ gameData.increaseUnitsLevel("rider"); refreshButtons(); showNote("rider"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } function frame1(){ locker = new SiteLock(stage); skipmochibot = locker.checkArmorgames(); unlocked = true; if (!skipmochibot){ trace("mochibot is tracking..."); MochiBot.track(this, "f0660fdb"); }; stage.scaleMode = "noScale"; myMenu = new ContextMenu(); myMenu.hideBuiltInItems(); item1 = new ContextMenuItem("armorgames.com"); item1.separatorBefore = true; item1.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, gotoArmor); myMenu.customItems.push(item1); item2 = new ContextMenuItem("artlogicgames.com"); item2.separatorBefore = true; item2.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, gotoArt); myMenu.customItems.push(item2); obj = stage.getChildAt(0); obj.contextMenu = myMenu; mcpreloader.stop(); stage.addEventListener(Event.ENTER_FRAME, updatePreloader); armorbtn.addEventListener(MouseEvent.MOUSE_DOWN, gotoArmor); adsbtn.addEventListener(MouseEvent.MOUSE_DOWN, gotoAds); artbtn.addEventListener(MouseEvent.MOUSE_DOWN, gotoArt); CPMStarContentSpotID = "197QF7072A36"; if (locker.checkKongregate()){ adBox.visible = false; } else { trace("choosing ads to load...."); if (Math.random() < 0.5){ ad = new AdLoader(CPMStarContentSpotID); adBox.addChild(ad); adsbtn.visible = false; trace(">> CPMStar is loading...."); } else { trace(">> Armor is loaded...."); adBox.visible = false; }; }; stop(); } public function gotoAds(_arg1=null):void{ navigateToURL(new URLRequest("http://www.armorgames.com/?gamereferral=kingdomofthewind"), "_blank"); } function frame6(){ if (!unlocked){ gotoAndStop("locked"); }; moreGameURL = new URLRequest("http://www.armorgames.com/?gamereferral=kingdomofthewind"); addGameURL = new URLRequest("http://armorgames.com/free-website-games?gamereferral=kingdomofthewind"); selectedLevel = 1; gameData = new GameData(this, selectedLevel); soundMgr = new SoundManager(); soundMgr.playBGM("cover"); btplay.addEventListener(MouseEvent.CLICK, goNewGame); btplaymore.addEventListener(MouseEvent.CLICK, playMoreGames); btaddgame.addEventListener(MouseEvent.CLICK, addGames); btloadgame.addEventListener(MouseEvent.CLICK, goLoadGame); btcredit.addEventListener(MouseEvent.CLICK, goCredit); btarmor.addEventListener(MouseEvent.CLICK, gotoArmor); stop(); } function frame2(){ playbtn.addEventListener(MouseEvent.MOUSE_DOWN, goto3); stop(); } function frame24(){ soundMgr.playBGM("intro"); if (btday1){ btday1.addEventListener(MouseEvent.CLICK, day1Selected); }; if (btday2){ btday2.addEventListener(MouseEvent.CLICK, day2Selected); }; if (btday3){ btday3.addEventListener(MouseEvent.CLICK, day3Selected); }; if (btday4){ btday4.addEventListener(MouseEvent.CLICK, day4Selected); }; if (btday5){ btday5.addEventListener(MouseEvent.CLICK, day5Selected); }; if (btday6){ btday6.addEventListener(MouseEvent.CLICK, day6Selected); }; if (btday7){ btday7.addEventListener(MouseEvent.CLICK, day7Selected); }; if (btday8){ btday8.addEventListener(MouseEvent.CLICK, day8Selected); }; if (btday1){ btday1.visible = gameData.unlockedLevel[0]; }; if (btday2){ btday2.visible = gameData.unlockedLevel[1]; }; if (btday3){ btday3.visible = gameData.unlockedLevel[2]; }; if (btday4){ btday4.visible = gameData.unlockedLevel[3]; }; if (btday5){ btday5.visible = gameData.unlockedLevel[4]; }; if (btday6){ btday6.visible = gameData.unlockedLevel[5]; }; if (btday7){ btday7.visible = gameData.unlockedLevel[6]; }; if (btday8){ btday8.visible = gameData.unlockedLevel[7]; }; if (btplay){ btplay.addEventListener(MouseEvent.CLICK, startGame); }; if (btplaymore){ btplaymore.addEventListener(MouseEvent.CLICK, playMoreGames); }; if (btsavegame){ btsavegame.addEventListener(MouseEvent.CLICK, saveGame); }; if (btloadgame){ btloadgame.addEventListener(MouseEvent.CLICK, goLoadGame); }; if (btinstructions){ btinstructions.addEventListener(MouseEvent.CLICK, openInstructions); }; if (btstatistics){ btstatistics.addEventListener(MouseEvent.CLICK, openStatistics); }; if (btupgrade){ btupgrade.addEventListener(MouseEvent.CLICK, openUpgrade); }; if (btmainmenu){ btmainmenu.addEventListener(MouseEvent.CLICK, backToMain); }; switch (selectedLevel){ case 8: day8Selected(); break; case 7: day7Selected(); break; case 6: day6Selected(); break; case 5: day5Selected(); break; case 4: day4Selected(); break; case 3: day3Selected(); break; case 2: day2Selected(); break; case 1: default: day1Selected(); break; }; if (gameData.isSkillTutorial()){ tutorial_mc.gotoAndPlay(2); }; stop(); } public function upgradeInitialManaBankOut(_arg1=null){ hideNote(); } public function openUpgrade(_arg1){ removeLevelListener(); gotoAndPlay("upgrade"); } public function showNote(_arg1){ switch (_arg1){ case "castle": panelnote.x = btupgradecastle.x; panelnote.y = btupgradecastle.y; panelnote.gotoAndStop(2); panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(0))); panelnote.visible = true; break; case "iceturret": panelnote.x = btupgradeiceturret.x; panelnote.y = btupgradeiceturret.y; panelnote.gotoAndStop(3); if (!gameData.unlockedTurrets[0]){ panelnote.gotoAndStop((3 + 13)); }; panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(1))); panelnote.visible = true; break; case "fireturret": panelnote.x = btupgradefireturret.x; panelnote.y = btupgradefireturret.y; panelnote.gotoAndStop(4); if (!gameData.unlockedTurrets[1]){ panelnote.gotoAndStop((4 + 13)); }; panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(2))); panelnote.visible = true; break; case "thunderturret": panelnote.x = btupgradethunderturret.x; panelnote.y = btupgradethunderturret.y; panelnote.gotoAndStop(5); if (!gameData.unlockedTurrets[2]){ panelnote.gotoAndStop((5 + 13)); }; panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(3))); panelnote.visible = true; break; case "rider": panelnote.x = btupgraderider.x; panelnote.y = btupgraderider.y; panelnote.gotoAndStop(6); if (!gameData.unlockedUnits[0]){ panelnote.gotoAndStop((6 + 13)); }; panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(4))); panelnote.visible = true; break; case "copter": panelnote.x = btupgradecopter.x; panelnote.y = btupgradecopter.y; panelnote.gotoAndStop(7); if (!gameData.unlockedUnits[1]){ panelnote.gotoAndStop((7 + 13)); }; panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(5))); panelnote.visible = true; break; case "eagle": panelnote.x = btupgradeeagle.x; panelnote.y = btupgradeeagle.y; panelnote.gotoAndStop(8); if (!gameData.unlockedUnits[2]){ panelnote.gotoAndStop((8 + 13)); }; panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(6))); panelnote.visible = true; break; case "panzer": panelnote.x = btupgradepanzer.x; panelnote.y = btupgradepanzer.y; panelnote.gotoAndStop(9); if (!gameData.unlockedUnits[3]){ panelnote.gotoAndStop((9 + 13)); }; panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(7))); panelnote.visible = true; break; case "dragon": panelnote.x = btupgradedragon.x; panelnote.y = btupgradedragon.y; panelnote.gotoAndStop(10); if (!gameData.unlockedUnits[4]){ panelnote.gotoAndStop((10 + 13)); }; panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(8))); panelnote.visible = true; break; case "unitcreatetime": panelnote.x = btupgradeunitcreatetime.x; panelnote.y = btupgradeunitcreatetime.y; panelnote.gotoAndStop(11); panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(9))); panelnote.visible = true; break; case "turretcreatetime": panelnote.x = btupgradeturretcreatetime.x; panelnote.y = btupgradeturretcreatetime.y; panelnote.gotoAndStop(12); panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(10))); panelnote.visible = true; break; case "manaregeneratetime": panelnote.x = btupgrademanaregeneratetime.x; panelnote.y = btupgrademanaregeneratetime.y; panelnote.gotoAndStop(13); panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(11))); panelnote.visible = true; break; case "initialmanabank": panelnote.x = btupgradeinitialmanabank.x; panelnote.y = btupgradeinitialmanabank.y; panelnote.gotoAndStop(14); panelnote.ep.text = String(Math.ceil(gameData.getExperiencePrice(12))); panelnote.visible = true; break; }; if (panelnote.ep.text == "NaN"){ panelnote.ep.text = "~"; }; } public function backToMain(_arg1=null){ gotoAndStop("menuselect"); } function frame34(){ soundMgr.playBGM("intro"); doSaveGame(); btcancel.addEventListener(MouseEvent.CLICK, goLevelSelect); stop(); } public function upgradeFireTurretClick(_arg1=null){ if (gameData.isTurretsLevelUpgradable("fireturret")){ gameData.increaseTurretsLevel("fireturret"); refreshButtons(); showNote("fireturret"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } public function addGames(_arg1=null){ navigateToURL(addGameURL, "_blank"); } function frame44(){ soundMgr.playBGM("intro"); btcancel.addEventListener(MouseEvent.CLICK, goLevelSelect); stop(); } public function upgradeRiderOut(_arg1=null){ hideNote(); } function frame8(){ gotoAndPlay("levelselect"); } public function doSaveGame(){ gameData.saveData(); gameData.submitStat(); } public function upgradeUnitCreateTimeOut(_arg1=null){ hideNote(); } public function upgradeDragonOver(_arg1=null){ showNote("dragon"); } function frame54(){ soundMgr.playBGM("intro"); btcancel.addEventListener(MouseEvent.CLICK, goLevelSelect); stop(); } public function day2Selected(_arg1=null){ selectedLevel = 2; gameData.changeGameLevel(selectedLevel); levelnote.gotoAndStop(2); } public function day4Selected(_arg1=null){ selectedLevel = 4; gameData.changeGameLevel(selectedLevel); levelnote.gotoAndStop(4); } public function day6Selected(_arg1=null){ selectedLevel = 6; gameData.changeGameLevel(selectedLevel); levelnote.gotoAndStop(6); } public function day8Selected(_arg1=null){ selectedLevel = 8; gameData.changeGameLevel(selectedLevel); levelnote.gotoAndStop(8); } public function upgradeCastleOut(_arg1=null){ hideNote(); } public function upgradeEagleOut(_arg1=null){ hideNote(); } public function endUpgradePage(_arg1){ stopUpgradeListeners(); goLevelSelect(); } public function showInstruction5(_arg1){ showInstructionNote("battle"); } public function showInstructionNote(_arg1){ instructionnote.gotoAndStop(_arg1); } public function showInstruction3(_arg1){ showInstructionNote("units"); } public function openStatistics(_arg1){ removeLevelListener(); gotoAndPlay("statistics"); } public function saveGame(_arg1){ removeLevelListener(); gotoAndPlay("savegame"); } public function FinishLogo(_arg1=null){ if (mc_armor.currentFrame == mc_armor.totalFrames){ stage.removeEventListener(Event.ENTER_FRAME, FinishLogo); play(); }; } public function goLoadGame(_arg1=null){ if (gameData.loadData()){ gotoAndPlay("loadgame"); selectedLevel = gameData.selectedLevel; } else { gotoAndPlay("unloadgame"); selectedLevel = gameData.selectedLevel; }; } public function showInstruction2(_arg1){ showInstructionNote("shortcuts"); } public function showInstruction4(_arg1){ showInstructionNote("exp"); } function frame84(){ soundMgr.playBGM("stage"); stage.focus = this; gameMgr = new GameManager(this, gameData, soundMgr); stop(); } public function upgradeThunderTurretOver(_arg1=null){ showNote("thunderturret"); } public function upgradeEagleClick(_arg1=null){ if (gameData.isUnitsLevelUpgradable("eagle")){ gameData.increaseUnitsLevel("eagle"); refreshButtons(); showNote("eagle"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } public function openInstructions(_arg1){ removeLevelListener(); gotoAndPlay("instructions"); } public function showInstruction6(_arg1){ showInstructionNote("upgrade"); } public function upgradeCopterOut(_arg1=null){ hideNote(); } public function upgradeManaRegenerateTimeOut(_arg1=null){ hideNote(); } public function showInstruction1(_arg1){ showInstructionNote("gameplay"); } public function upgradePanzerClick(_arg1=null){ if (gameData.isUnitsLevelUpgradable("panzer")){ gameData.increaseUnitsLevel("panzer"); refreshButtons(); showNote("panzer"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } public function goto3(_arg1:MouseEvent):void{ gotoAndStop(3); } function frame74(){ soundMgr.playBGM("intro"); btcancel.addEventListener(MouseEvent.CLICK, goLevelSelect); txt1.text = String(Math.floor((gameData.experienceTotal + gameData.experienceSpent))); txt2.text = String(Math.floor(gameData.experienceSpent)); txt3.text = String(Math.floor(gameData.countEnemyKilled())); txt4.text = String(Math.floor(gameData.countUnitsBuilt())); txt5.text = String(Math.floor(gameData.countUnitsLost())); txt6.text = String(Math.floor(gameData.countTurretsBuilt())); txt7.text = String(Math.floor(gameData.countTurretsLost())); txt8.text = String(Math.floor(gameData.manaGained)); txt9.text = String(Math.floor(gameData.manaSpent)); stop(); } public function upgradeUnitCreateTimeClick(_arg1=null){ if (gameData.isUnitsCreationTimerLevelUpgradable()){ gameData.increaseUnitsCreationTimerLevel(); refreshButtons(); showNote("unitcreatetime"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } public function upgradeTurretCreateTimeClick(_arg1=null){ if (gameData.isTurretsCreationTimerLevelUpgradable()){ gameData.increaseTurretsCreationTimerLevel(); refreshButtons(); showNote("turretcreatetime"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } public function upgradeCastleOver(_arg1=null){ showNote("castle"); } public function upgradeManaRegenerateTimeClick(_arg1=null){ if (gameData.isManaRegenerationLevelUpgradable()){ gameData.increaseManaRegenerationLevel(); refreshButtons(); showNote("manaregeneratetime"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } public function upgradeDragonClick(_arg1=null){ if (gameData.isUnitsLevelUpgradable("dragon")){ gameData.increaseUnitsLevel("dragon"); refreshButtons(); showNote("dragon"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } public function startGame(_arg1){ removeLevelListener(); gotoAndPlay("gameplay"); } public function upgradeDragonOut(_arg1=null){ hideNote(); } public function goLevelSelect(_arg1=null){ gotoAndPlay("leveljumper"); } public function gotoArmor(_arg1=null):void{ navigateToURL(new URLRequest("http://www.armorgames.com/?gamereferral=kingdomofthewind"), "_blank"); } public function playMoreGames(_arg1=null){ navigateToURL(moreGameURL, "_blank"); } function frame104(){ soundMgr.playBGM("intro"); btcancel.addEventListener(MouseEvent.CLICK, goLevelSelect); showResults(); stop(); } function frame124(){ soundMgr.playBGM("intro"); selectedLevel = 1; btcancel.addEventListener(MouseEvent.CLICK, goLevelSelect); showResults(); stop(); } function frame64(){ soundMgr.playBGM("intro"); btcancel.addEventListener(MouseEvent.CLICK, endUpgradePage); refreshButtons(); startUpgradeListeners(); stop(); } public function goNewGame(_arg1=null){ gameData.resetData(); selectedLevel = 1; gotoAndPlay("levelselect"); } public function updatePreloader(_arg1:Event):void{ var _local2:Number; _local2 = ((this.loaderInfo.bytesLoaded / this.loaderInfo.bytesTotal) * 100); if (_local2 < 100){ mcpreloader.gotoAndStop(int(_local2)); } else { mcpreloader.gotoAndStop(mcpreloader.totalFrames); stage.removeEventListener(Event.ENTER_FRAME, updatePreloader); gotoAndStop(2); }; } public function upgradeCopterClick(_arg1=null){ if (gameData.isUnitsLevelUpgradable("copter")){ gameData.increaseUnitsLevel("copter"); refreshButtons(); showNote("copter"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } public function upgradeRiderOver(_arg1=null){ showNote("rider"); } public function stopUpgradeListeners(){ btupgradecastle.removeEventListener(MouseEvent.CLICK, upgradeCastleClick); btupgradeiceturret.removeEventListener(MouseEvent.CLICK, upgradeIceTurretClick); btupgradefireturret.removeEventListener(MouseEvent.CLICK, upgradeFireTurretClick); btupgradethunderturret.removeEventListener(MouseEvent.CLICK, upgradeThunderTurretClick); btupgraderider.removeEventListener(MouseEvent.CLICK, upgradeRiderClick); btupgradecopter.removeEventListener(MouseEvent.CLICK, upgradeCopterClick); btupgradeeagle.removeEventListener(MouseEvent.CLICK, upgradeEagleClick); btupgradepanzer.removeEventListener(MouseEvent.CLICK, upgradePanzerClick); btupgradedragon.removeEventListener(MouseEvent.CLICK, upgradeDragonClick); btupgradeunitcreatetime.removeEventListener(MouseEvent.CLICK, upgradeUnitCreateTimeClick); btupgradeturretcreatetime.removeEventListener(MouseEvent.CLICK, upgradeTurretCreateTimeClick); btupgrademanaregeneratetime.removeEventListener(MouseEvent.CLICK, upgradeManaRegenerateTimeClick); btupgradeinitialmanabank.removeEventListener(MouseEvent.CLICK, upgradeInitialManaBankClick); btupgradecastle.removeEventListener(MouseEvent.MOUSE_OVER, upgradeCastleOver); btupgradeiceturret.removeEventListener(MouseEvent.MOUSE_OVER, upgradeIceTurretOver); btupgradefireturret.removeEventListener(MouseEvent.MOUSE_OVER, upgradeFireTurretOver); btupgradethunderturret.removeEventListener(MouseEvent.MOUSE_OVER, upgradeThunderTurretOver); btupgraderider.removeEventListener(MouseEvent.MOUSE_OVER, upgradeRiderOver); btupgradecopter.removeEventListener(MouseEvent.MOUSE_OVER, upgradeCopterOver); btupgradeeagle.removeEventListener(MouseEvent.MOUSE_OVER, upgradeEagleOver); btupgradepanzer.removeEventListener(MouseEvent.MOUSE_OVER, upgradePanzerOver); btupgradedragon.removeEventListener(MouseEvent.MOUSE_OVER, upgradeDragonOver); btupgradeunitcreatetime.removeEventListener(MouseEvent.MOUSE_OVER, upgradeUnitCreateTimeOver); btupgradeturretcreatetime.removeEventListener(MouseEvent.MOUSE_OVER, upgradeTurretCreateTimeOver); btupgrademanaregeneratetime.removeEventListener(MouseEvent.MOUSE_OVER, upgradeManaRegenerateTimeOver); btupgradeinitialmanabank.removeEventListener(MouseEvent.MOUSE_OVER, upgradeInitialManaBankOver); btupgradecastle.removeEventListener(MouseEvent.MOUSE_OUT, upgradeCastleOut); btupgradeiceturret.removeEventListener(MouseEvent.MOUSE_OUT, upgradeIceTurretOut); btupgradefireturret.removeEventListener(MouseEvent.MOUSE_OUT, upgradeFireTurretOut); btupgradethunderturret.removeEventListener(MouseEvent.MOUSE_OUT, upgradeThunderTurretOut); btupgraderider.removeEventListener(MouseEvent.MOUSE_OUT, upgradeRiderOut); btupgradecopter.removeEventListener(MouseEvent.MOUSE_OUT, upgradeCopterOut); btupgradeeagle.removeEventListener(MouseEvent.MOUSE_OUT, upgradeEagleOut); btupgradepanzer.removeEventListener(MouseEvent.MOUSE_OUT, upgradePanzerOut); btupgradedragon.removeEventListener(MouseEvent.MOUSE_OUT, upgradeDragonOut); btupgradeunitcreatetime.removeEventListener(MouseEvent.MOUSE_OUT, upgradeUnitCreateTimeOut); btupgradeturretcreatetime.removeEventListener(MouseEvent.MOUSE_OUT, upgradeTurretCreateTimeOut); btupgrademanaregeneratetime.removeEventListener(MouseEvent.MOUSE_OUT, upgradeManaRegenerateTimeOut); btupgradeinitialmanabank.removeEventListener(MouseEvent.MOUSE_OUT, upgradeInitialManaBankOut); } public function upgradeCastleClick(_arg1=null){ if (gameData.isCastleLevelUpgradable()){ gameData.increaseCastleLevel(); refreshButtons(); showNote("castle"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } function frame114(){ soundMgr.playBGM("intro"); if (selectedLevel == 8){ gameData.gameCompleted = 8; gotoAndPlay("ultimatewin"); } else { gameData.gameCompleted = selectedLevel; selectedLevel++; }; btcancel.addEventListener(MouseEvent.CLICK, goLevelSelect); showResults(); stop(); } public function upgradePanzerOut(_arg1=null){ hideNote(); } public function day1Selected(_arg1=null){ selectedLevel = 1; gameData.changeGameLevel(selectedLevel); levelnote.gotoAndStop(1); } public function upgradeInitialManaBankClick(_arg1=null){ if (gameData.isManaCountLevelUpgradable()){ gameData.increaseManaCountLevel(); refreshButtons(); showNote("initialmanabank"); } else { if (panelnote.ep.text != "~"){ upgradewarning.gotoAndPlay("insufficient"); } else { upgradewarning.gotoAndPlay("maximum"); }; }; } public function day7Selected(_arg1=null){ selectedLevel = 7; gameData.changeGameLevel(selectedLevel); levelnote.gotoAndStop(7); } public function day3Selected(_arg1=null){ selectedLevel = 3; gameData.changeGameLevel(selectedLevel); levelnote.gotoAndStop(3); } public function day5Selected(_arg1=null){ selectedLevel = 5; gameData.changeGameLevel(selectedLevel); levelnote.gotoAndStop(5); } function frame94(){ soundMgr.playBGM("intro"); btcancel.addEventListener(MouseEvent.CLICK, goLevelSelect); gameData.levelExperience = 0; showResults(); stop(); } public function upgradeTurretCreateTimeOut(_arg1=null){ hideNote(); } public function upgradeCopterOver(_arg1=null){ showNote("copter"); } public function upgradeTurretCreateTimeOver(_arg1=null){ showNote("turretcreatetime"); } function frame135(){ soundMgr.playBGM("intro"); btcancel.addEventListener(MouseEvent.CLICK, backToMain); stop(); } } }//package windkingdom_armor_fla
Section 53
//mc_preload_dumper_12 (windkingdom_armor_fla.mc_preload_dumper_12) package windkingdom_armor_fla { import flash.display.*; public dynamic class mc_preload_dumper_12 extends MovieClip { public function mc_preload_dumper_12(){ addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package windkingdom_armor_fla
Section 54
//mc_redsplashfxcopy_27 (windkingdom_armor_fla.mc_redsplashfxcopy_27) package windkingdom_armor_fla { import flash.display.*; public dynamic class mc_redsplashfxcopy_27 extends MovieClip { public function mc_redsplashfxcopy_27(){ addFrameScript(9, frame10); } function frame10(){ gotoAndPlay(1); } } }//package windkingdom_armor_fla
Section 55
//mc_tutorialskills_151 (windkingdom_armor_fla.mc_tutorialskills_151) package windkingdom_armor_fla { import flash.display.*; public dynamic class mc_tutorialskills_151 extends MovieClip { public function mc_tutorialskills_151(){ addFrameScript(0, frame1, 60, frame61); } function frame1(){ stop(); } function frame61(){ stop(); } } }//package windkingdom_armor_fla
Section 56
//mcpreloaderBar_10 (windkingdom_armor_fla.mcpreloaderBar_10) package windkingdom_armor_fla { import flash.display.*; public dynamic class mcpreloaderBar_10 extends MovieClip { public function mcpreloaderBar_10(){ addFrameScript(100, frame101); } function frame101(){ stop(); } } }//package windkingdom_armor_fla
Section 57
//panelnote_169 (windkingdom_armor_fla.panelnote_169) package windkingdom_armor_fla { import flash.display.*; import flash.text.*; public dynamic class panelnote_169 extends MovieClip { public var ep:TextField; } }//package windkingdom_armor_fla
Section 58
//result_174 (windkingdom_armor_fla.result_174) package windkingdom_armor_fla { import flash.display.*; import flash.text.*; public dynamic class result_174 extends MovieClip { public var txt12:TextField; public var txt11:TextField; public var txt14:TextField; public var txt13:TextField; public var txt10:TextField; public var txt15:TextField; public var txt16:TextField; public var txt1:TextField; public var txt2:TextField; public var txt3:TextField; public var txt5:TextField; public var txt9:TextField; public var txt6:TextField; public var txt7:TextField; public var txt8:TextField; public var txt4:TextField; } }//package windkingdom_armor_fla
Section 59
//result_loose_173 (windkingdom_armor_fla.result_loose_173) package windkingdom_armor_fla { import flash.display.*; import flash.text.*; public dynamic class result_loose_173 extends MovieClip { public var txt12:TextField; public var txt11:TextField; public var txt14:TextField; public var txt13:TextField; public var txt10:TextField; public var txt15:TextField; public var txt16:TextField; public var txt1:TextField; public var txt2:TextField; public var txt3:TextField; public var txt5:TextField; public var txt9:TextField; public var txt6:TextField; public var txt7:TextField; public var txt8:TextField; public var txt4:TextField; } }//package windkingdom_armor_fla
Section 60
//result_quit_171 (windkingdom_armor_fla.result_quit_171) package windkingdom_armor_fla { import flash.display.*; import flash.text.*; public dynamic class result_quit_171 extends MovieClip { public var txt12:TextField; public var txt11:TextField; public var txt14:TextField; public var txt13:TextField; public var txt10:TextField; public var txt15:TextField; public var txt16:TextField; public var txt1:TextField; public var txt2:TextField; public var txt3:TextField; public var txt5:TextField; public var txt9:TextField; public var txt6:TextField; public var txt7:TextField; public var txt8:TextField; public var txt4:TextField; } }//package windkingdom_armor_fla
Section 61
//rightnote_89 (windkingdom_armor_fla.rightnote_89) package windkingdom_armor_fla { import flash.display.*; import flash.text.*; public dynamic class rightnote_89 extends MovieClip { public var txt1:TextField; public var txt2:TextField; public var txt3:TextField; public function rightnote_89(){ addFrameScript(0, frame1, 1, frame2); } function frame1(){ stop(); } function frame2(){ stop(); } } }//package windkingdom_armor_fla
Section 62
//upgradewarning_152 (windkingdom_armor_fla.upgradewarning_152) package windkingdom_armor_fla { import flash.display.*; public dynamic class upgradewarning_152 extends MovieClip { public function upgradewarning_152(){ addFrameScript(0, frame1, 29, frame30, 58, frame59); } function frame1(){ stop(); } function frame30(){ gotoAndStop(1); } function frame59(){ gotoAndStop(1); } } }//package windkingdom_armor_fla
Section 63
//AdLoader (AdLoader) package { import flash.events.*; import flash.display.*; import flash.net.*; import flash.system.*; public class AdLoader extends Sprite { private var contentspotid:String; private var cpmstarLoader:Loader; public function AdLoader(_arg1:String){ this.contentspotid = _arg1; addEventListener(Event.ADDED, addedHandler); } private function addedHandler(_arg1:Event):void{ var _local2:String; var _local3:DisplayObjectContainer; removeEventListener(Event.ADDED, addedHandler); Security.allowDomain("server.cpmstar.com"); _local2 = "http://server.cpmstar.com/adviewas3.swf"; _local3 = parent; cpmstarLoader = new Loader(); cpmstarLoader.contentLoaderInfo.addEventListener(Event.INIT, dispatchHandler); cpmstarLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, dispatchHandler); cpmstarLoader.load(new URLRequest(((_local2 + "?contentspotid=") + contentspotid))); addChild(cpmstarLoader); } private function dispatchHandler(_arg1:Event):void{ dispatchEvent(_arg1); } } }//package
Section 64
//background1 (background1) package { import flash.display.*; public dynamic class background1 extends MovieClip { } }//package
Section 65
//BaseAIClip (BaseAIClip) package { import flash.events.*; import flash.display.*; import flash.utils.*; import flash.geom.*; public class BaseAIClip extends MovieClip { private var attackingcounter;// = 0 private var healthbar; public var attack; public var defense; public var health; public var speed; public var typeInt; public var d1:MovieClip; private var dx; private var stopX; private var stopY; private var dy; public var splashSign; public var maxhealth; public var selectedSign; public var repairer:MovieClip; private var bullet; public var power; public var castle:MovieClip; public var attackrate; public var type; public var range; private var flipable; private var bulletfx; public var sceneContainer; public var weapontype; public var side; public var myParent; public var attacktype; public var target; private var createtime; public var cost; private var attackingspeed; private var maincastle; public var status; private var attacktimer; public function BaseAIClip(){ attackingcounter = 0; super(); } public function destroy(){ if (bullet){ sceneContainer.removeChild(bullet); bullet = null; }; this.removeEventListener(MouseEvent.CLICK, selectionHandler); } private function moveDown(){ if (this.y < 800){ dy = (1000 / this.width); this.y = (this.y + dy); } else { this.gotoAndStop("destroyed"); if (type == "castle"){ myParent.gameState = "stopplayerloose"; myParent.stopGame(); }; }; } private function selectionHandler(_arg1){ myParent.showObjectStatus(this); if (side == "enemy"){ myParent.setEnemyTarget(this); }; } private function attackMove(){ switch (weapontype){ case "sword": if (attackingcounter < 15){ if (this.currentLabel != "attack"){ this.gotoAndPlay("attack"); }; target.reduceHealth(((power * attack) / 15)); attackingcounter++; if (attackingcounter == 15){ attackingcounter = 0; status = "closing"; }; }; break; case "thunderbullet": if (attacktimer > 0){ if (!bullet){ bullet = new mc_thunder(); bullet.x = this.x; bullet.y = this.y; sceneContainer.addChild(bullet); bullet.gotoAndPlay(((Math.floor((Math.random() * 3)) * 2) + 1)); }; if (!bulletfx){ bulletfx = new mc_electricsplashfx(); bulletfx.x = this.x; bulletfx.y = this.y; sceneContainer.addChild(bulletfx); bulletfx.gotoAndPlay(((Math.floor((Math.random() * 5)) * 2) + 1)); }; bullet.rotation = 0; bullet.width = (getDistance(target) + 10); bullet.rotation = (180 - getAngle(target)); bulletfx.x = target.x; bulletfx.y = target.y; bulletfx.width = target.width; bulletfx.height = target.width; target.reduceHealth(((power * attack) * 0.05)); attacktimer--; if ((((((((attacktimer == 0)) || (!(target)))) || ((target.status == "destroyed")))) || ((target.health == 0)))){ attacktimer = 0; status = "closing"; }; } else { attacktimer = 0; status = "closing"; }; if (((((((!(target)) || ((getDistance(target) > range)))) || ((target.status == "destroyed")))) || ((target.health == 0)))){ attacktimer = attackrate; }; break; default: break; }; } private function getClosestPawn2(_arg1="player"):MovieClip{ var _local2:*; var _local3:*; var _local4:*; var _local5:*; var _local6:*; if (_arg1 == "player"){ _local6 = myParent.unitArray; } else { _local6 = myParent.enemyArray; }; if (_local6.length > 0){ _local5 = _local6[0]; _local4 = getDistance(_local5); _local2 = 0; while (_local2 < _local6.length) { _local3 = getDistance(_local6[_local2]); if (_local3 < _local4){ _local5 = _local6[_local2]; _local4 = _local3; }; _local2++; }; } else { _local5 = null; }; return (_local5); } public function initType(_arg1, _arg2, _arg3){ myParent = _arg1; sceneContainer = myParent.sceneContainer; attacktimer = 0; bullet = null; createtime = getTimer(); if (_arg2 != "castle"){ castle = myParent.castle; } else { castle = null; }; switch (_arg2){ case "castle": side = "player"; type = "castle"; weapontype = "icebullet"; cost = 0; speed = 0; health = _arg3.castleHealth; power = _arg3.castlePower; attack = _arg3.castleAttack; defense = _arg3.castleDefense; range = _arg3.castleRange; attackrate = 30; flipable = false; stopX = this.x; stopY = this.y; break; case "iceturret": side = "player"; type = "turret"; typeInt = 0; weapontype = "frozenbullet"; cost = 0; speed = 0; health = _arg3.turretsHealth[0]; power = _arg3.turretsPower[0]; attack = _arg3.turretsAttack[0]; defense = _arg3.turretsDefense[0]; range = _arg3.turretsRange[0]; attackrate = 30; flipable = false; stopX = this.x; stopY = this.y; break; case "fireturret": side = "player"; type = "turret"; typeInt = 1; weapontype = "firebullet"; cost = 0; speed = 0; health = _arg3.turretsHealth[1]; power = _arg3.turretsPower[1]; attack = _arg3.turretsAttack[1]; defense = _arg3.turretsDefense[1]; range = _arg3.turretsRange[1]; attackrate = 30; flipable = false; stopX = this.x; stopY = this.y; break; case "thunderturret": side = "player"; type = "turret"; typeInt = 2; attacktype = "meelee"; weapontype = "thunderbullet"; cost = 0; speed = 0; health = _arg3.turretsHealth[2]; power = _arg3.turretsPower[2]; attack = _arg3.turretsAttack[2]; defense = _arg3.turretsDefense[2]; range = _arg3.turretsRange[2]; attackrate = 30; flipable = false; stopX = this.x; stopY = this.y; break; case "dragon": side = "player"; type = "dragon"; typeInt = 4; weapontype = "icebullet"; cost = 0; speed = 2; health = _arg3.unitsHealth[4]; power = _arg3.unitsPower[4]; attack = _arg3.unitsAttack[4]; defense = _arg3.unitsDefense[4]; range = _arg3.unitsRange[4]; attackrate = 30; flipable = false; break; case "panzer": side = "player"; type = "panzer"; typeInt = 3; weapontype = "cannonbullet"; cost = 0; speed = 2; health = _arg3.unitsHealth[3]; power = _arg3.unitsPower[3]; attack = _arg3.unitsAttack[3]; defense = _arg3.unitsDefense[3]; range = _arg3.unitsRange[3]; attackrate = 30; flipable = false; break; case "eagle": side = "player"; type = "eagle"; typeInt = 2; weapontype = "icebullet"; cost = 0; speed = 2; health = _arg3.unitsHealth[2]; power = _arg3.unitsPower[2]; attack = _arg3.unitsAttack[2]; defense = _arg3.unitsDefense[2]; range = _arg3.unitsRange[2]; attackrate = 30; flipable = false; break; case "copter": side = "player"; type = "copter"; typeInt = 1; weapontype = "cannonbullet"; cost = 0; speed = 2; health = _arg3.unitsHealth[1]; power = _arg3.unitsPower[1]; attack = _arg3.unitsAttack[1]; defense = _arg3.unitsDefense[1]; range = _arg3.unitsRange[1]; attackrate = 30; flipable = false; break; case "rider": side = "player"; type = "rider"; typeInt = 0; weapontype = "icebullet"; cost = 0; speed = 2; health = _arg3.unitsHealth[0]; power = _arg3.unitsPower[0]; attack = _arg3.unitsAttack[0]; defense = _arg3.unitsDefense[0]; range = _arg3.unitsRange[0]; attackrate = 30; flipable = false; break; case "evilultimate": side = "enemy"; type = "evilultimate"; typeInt = 6; weapontype = "firebullet"; cost = _arg3.enemyCost[6]; speed = 3; health = _arg3.enemyHealth[6]; power = _arg3.enemyPower[6]; attack = _arg3.enemyAttack[6]; defense = _arg3.enemyDefense[6]; range = _arg3.enemyRange[6]; attackrate = 30; flipable = true; break; case "evildragon": side = "enemy"; type = "evildragon"; typeInt = 5; weapontype = "firebullet"; cost = _arg3.enemyCost[5]; speed = 3; health = _arg3.enemyHealth[5]; power = _arg3.enemyPower[5]; attack = _arg3.enemyAttack[5]; defense = _arg3.enemyDefense[5]; range = _arg3.enemyRange[5]; attackrate = 30; flipable = true; break; case "evilknight": side = "enemy"; type = "evilknight"; typeInt = 4; attacktype = "meelee"; weapontype = "sword"; cost = _arg3.enemyCost[4]; speed = 3; health = _arg3.enemyHealth[4]; power = _arg3.enemyPower[4]; attack = _arg3.enemyAttack[4]; defense = _arg3.enemyDefense[4]; range = _arg3.enemyRange[4]; attackrate = 60; attackingspeed = 15; flipable = false; break; case "evilpanzer": side = "enemy"; type = "evilpanzer"; typeInt = 3; weapontype = "cannonbullet"; cost = _arg3.enemyCost[3]; speed = 3; health = _arg3.enemyHealth[3]; power = _arg3.enemyPower[3]; attack = _arg3.enemyAttack[3]; defense = _arg3.enemyDefense[3]; range = _arg3.enemyRange[3]; attackrate = 30; flipable = true; break; case "bigbat": side = "enemy"; type = "bigbat"; typeInt = 2; weapontype = "firebullet"; cost = _arg3.enemyCost[2]; speed = 2.5; health = _arg3.enemyHealth[2]; power = _arg3.enemyPower[2]; attack = _arg3.enemyAttack[2]; defense = _arg3.enemyDefense[2]; range = _arg3.enemyRange[2]; attackrate = 30; flipable = false; break; case "evilcopter": side = "enemy"; type = "evilcopter"; typeInt = 1; weapontype = "cannonbullet"; cost = _arg3.enemyCost[1]; speed = 2.5; health = _arg3.enemyHealth[1]; power = _arg3.enemyPower[1]; attack = _arg3.enemyAttack[1]; defense = _arg3.enemyDefense[1]; range = _arg3.enemyRange[1]; attackrate = 30; flipable = true; break; case "smallbat": default: side = "enemy"; type = "smallbat"; typeInt = 0; weapontype = "icebullet"; cost = _arg3.enemyCost[0]; speed = 2; health = _arg3.enemyHealth[0]; power = _arg3.enemyPower[0]; attack = _arg3.enemyAttack[0]; defense = _arg3.enemyDefense[0]; range = _arg3.enemyRange[0]; attackrate = 30; flipable = false; break; }; maxhealth = health; selectedSign = new mc_selected(); selectedSign.x = 0; selectedSign.y = 0; selectedSign.width = this.width; selectedSign.height = this.width; selectedSign.visible = false; this.addChild(selectedSign); splashSign = new mc_splashfx(); splashSign.x = 0; splashSign.x = 0; splashSign.y = 0; splashSign.width = this.width; splashSign.height = this.width; healthbar = new mc_healthbar(); healthbar.x = 0; switch (type){ case "turret": case "castle": healthbar.y = 30; break; default: healthbar.y = 10; break; }; healthbar.gotoAndStop(Math.floor(((health / maxhealth) * 100))); if (type != "castle"){ this.addChild(splashSign); this.addChild(healthbar); }; if (side == "enemy"){ detectAllyHit(); if (this.x < 275){ this.scaleX = (this.scaleX * -1); }; target = getClosestPawn("player"); if (target){ status = "closing"; } else { status = "idle"; }; } else { if (speed > 0){ detectAllyHit(); if (this.x < 275){ this.scaleX = (this.scaleX * -1); }; target = getClosestPawn("enemy"); if (target){ status = "closing"; } else { status = "idle"; }; }; }; this.addEventListener(MouseEvent.CLICK, selectionHandler); } public function resetHealth(){ health = maxhealth; healthbar.gotoAndStop(Math.floor(((health / maxhealth) * 100))); } public function setTarget(_arg1){ if (status != "destroyed"){ if (getDistance(_arg1) <= range){ target = _arg1; status = "attacking"; if (bullet){ sceneContainer.removeChild(bullet); }; bullet = null; if (bulletfx){ sceneContainer.removeChild(bulletfx); }; bulletfx = null; }; }; } public function moveClip(){ var _local1:*; if (bullet){ sceneContainer.removeChild(bullet); }; bullet = null; if (bulletfx){ sceneContainer.removeChild(bulletfx); }; bulletfx = null; if (((!((status == "destroyed"))) && (this.visible))){ if (((((!(target)) || ((getDistance(target) > (range * 1.5))))) || ((target.status == "destroyed")))){ findTarget(); }; } else { target = null; }; if (target){ setSkin(); if (getDistance(target) < range){ if (attacktype == "meelee"){ if (status != "attackmove"){ status = "attackmove"; attackingcounter = 0; attacktimer = attackrate; }; } else { status = "attacking"; }; } else { if (getDistance(target) <= (1.5 * range)){ status = "closing"; } else { if (side == "player"){ status = "idle"; } else { status = "closing"; }; }; }; } else { if (((!((status == "destroyed"))) && (this.visible))){ status = "idle"; }; }; switch (status){ case "destroyed": moveDown(); break; case "idle": idleMove(); break; case "attacking": attackTarget(); break; case "attackmove": attackMove(); break; case "fallback": closeCastle(); break; case "closing": default: closeTarget(); break; }; detectAllyHit(); } private function findTarget(){ var _local1:*; if (side == "player"){ if (((((myParent.selectedObject) && ((myParent.selectedObject.side == "enemy")))) && ((getDistance(myParent.selectedObject) <= range)))){ target = myParent.selectedObject; } else { _local1 = getClosestPawn("enemy"); if (_local1){ status = "closing"; target = _local1; } else { status = "idle"; }; }; } else { _local1 = getClosestPawn("player"); if (_local1){ status = "closing"; target = _local1; } else { status = "idle"; }; }; } private function setSkin(){ if (speed > 0){ if (this.scaleX > 0){ if (target.x > this.x){ this.scaleX = (this.scaleX * -1); }; } else { if (target.x < this.x){ this.scaleX = (this.scaleX * -1); }; }; if (flipable){ if (target.y < this.y){ if (this.currentLabel != "faceup"){ this.gotoAndPlay("faceup"); }; } else { if (this.currentLabel != "facedown"){ this.gotoAndPlay("facedown"); }; }; }; }; } private function closeCastle(){ var _local1:*; var _local2:*; _local1 = getTimer(); if (((castle) && ((speed > 0)))){ if ((dy * dy) > ((dx * dx) / 8)){ if (this.y > castle.y){ this.y = (this.y - speed); } else { if (this.y < castle.y){ this.y = (this.y + speed); }; }; } else { if (this.x > castle.x){ this.x = (this.x - speed); } else { if (this.x < castle.x){ this.x = (this.x + speed); }; }; }; }; detectOutScreen(); } public function getAngle(_arg1):Number{ dx = (this.x - _arg1.x); dy = (_arg1.y - this.y); return (((Math.atan2(dy, dx) * 180) / Math.PI)); } private function getClosestPawn(_arg1="player"):MovieClip{ var _local2:*; var _local3:*; var _local4:*; var _local5:*; var _local6:*; _local3 = null; _local5 = null; _local2 = 0; while (_local2 < sceneContainer.numChildren) { _local3 = sceneContainer.getChildAt(_local2); if (((((((!((_local3 == this))) && (!((_local3.type == "bullet"))))) && (!((_local3.status == "destroyed"))))) && (_local3.visible))){ if (_local3.side == _arg1){ if (!_local5){ _local5 = _local3; _local6 = getDistance(_local5); } else { _local4 = getDistance(_local3); if (_local6 > _local4){ _local5 = _local3; _local6 = _local4; }; }; }; }; _local2++; }; return (_local5); } private function detectAllyHit(){ var _local1:*; _local1 = getClosestPawn(side); if (((_local1) && (_local1.hitTestObject(this)))){ if ((((_local1.type == "castle")) || ((_local1.type == "turret")))){ (_local1 == null); }; } else { _local1 = null; }; if (_local1){ if (side == "enemy"){ if (this.y < _local1.y){ this.y = (this.y - speed); }; } else { if (this.y > _local1.y){ this.y = (this.y + speed); }; }; if (this.x > _local1.x){ this.x = (this.x + (speed / 2)); } else { this.x = (this.x - (speed / 2)); }; detectOutScreen(); }; } public function reduceHealth(_arg1){ var _local2:*; _local2 = (((_arg1 * power) * defense) / 200); if (_local2 >= (_arg1 * 0.9)){ health = (health - (_arg1 / 10)); } else { health = (health - (_arg1 - _local2)); }; healthbar.gotoAndStop(Math.floor(((health / maxhealth) * 100))); if (type == "castle"){ myParent.showHealth(); myParent.setDistortTimer(Math.ceil((_arg1 / 8))); }; if (health <= 0){ health = 0; status = "destroyed"; if (bullet){ sceneContainer.removeChild(bullet); bullet = null; if (bulletfx){ sceneContainer.removeChild(bulletfx); }; bulletfx = null; }; if (type == "castle"){ myParent.gameState = "gameover"; this.gotoAndPlay((this.currentFrame + 3)); }; }; } private function getDistance(_arg1):Number{ if (_arg1){ dx = (this.x - _arg1.x); dy = (_arg1.y - this.y); return (Math.sqrt(((dx * dx) + (dy * dy)))); }; return (0); } private function closeTarget(){ var _local1:*; var _local2:*; _local1 = getTimer(); if (bullet){ attacktimer = 0; status = "closing"; sceneContainer.removeChild(bullet); bullet = null; }; if (speed > 0){ if (side == "enemy"){ if ((dy * dy) > ((dx * dx) / 8)){ if (this.y > target.y){ this.y = (this.y - speed); } else { if (this.y < target.y){ this.y = (this.y + speed); }; }; } else { if (this.x > target.x){ this.x = (this.x - speed); } else { if (this.x < target.x){ this.x = (this.x + speed); }; }; }; } else { if (getDistance(target) > (range - 20)){ if ((dy * dy) > ((dx * dx) / 8)){ if (this.y > target.y){ this.y = (this.y - speed); } else { if (this.y < target.y){ this.y = (this.y + speed); }; }; } else { if (this.x > target.x){ this.x = (this.x - speed); } else { if (this.x < target.x){ this.x = (this.x + speed); }; }; }; }; }; detectOutScreen(); } else { this.y = (stopY + (Math.sin((((_local1 - createtime) / 3000) * Math.PI)) * 5)); }; } private function idleMove(){ var _local1:*; var _local2:*; _local1 = getTimer(); if (bullet){ attacktimer = 0; status = "closing"; sceneContainer.removeChild(bullet); bullet = null; }; if (speed == 0){ this.y = (stopY + (Math.sin((((_local1 - createtime) / 3000) * Math.PI)) * 5)); } else { if (side == "player"){ if (this.y > (myParent.castle.y + 25)){ this.y = (this.y - speed); } else { (this.y < (myParent.castle.y - 25)); }; this.y = (this.y + speed); } else { this.y = (this.y + (Math.sin((((_local1 - createtime) / 3000) * Math.PI)) / 10)); }; }; } private function attackTarget(){ var _local1:*; var _local2:*; var _local3:*; _local2 = getTimer(); _local3 = getDistance(target); if (speed > 0){ if (_local3 < (range / 2)){ if (this.x > target.x){ this.x = (this.x + speed); } else { this.x = (this.x - speed); }; if (this.y > target.y){ this.y = (this.y + speed); } else { this.y = (this.y - speed); }; }; detectOutScreen(); } else { this.y = (stopY + (Math.sin((((_local2 - createtime) / 3000) * Math.PI)) * 5)); }; if (((((target) && ((_local3 <= range)))) && (!((this.status == "destroyed"))))){ if (attacktimer == 0){ attacktimer = attackrate; switch (type){ case "castle": if (target.x > 275){ myParent.createBullet(new Point((this.x + 50), (this.y - 60)), target, side, weapontype, (power * attack)); } else { myParent.createBullet(new Point((this.x - 50), (this.y - 60)), target, side, weapontype, (power * attack)); }; break; default: myParent.createBullet(this, target, side, weapontype, (power * attack)); break; }; } else { attacktimer--; }; }; } private function detectOutScreen(){ if (this.y < 0){ this.y = (this.y + speed); }; if (this.y > 700){ this.y = (this.y - speed); }; if (this.x < 0){ this.x = (this.x + speed); }; if (this.x > 550){ this.x = (this.x - speed); }; } } }//package
Section 66
//BaseBulletClip (BaseBulletClip) package { import flash.display.*; public class BaseBulletClip extends MovieClip { private var distance; private var startX; private var startY; public var side; public var destroyable; public var speed; private var sceneContainer; private var myParent; public var damage; public var type; private var dr; public var subtype; private var dx; private var dy; public function destroy(){ } public function initType(_arg1, _arg2, _arg3, _arg4, _arg5=0){ myParent = _arg1; sceneContainer = myParent.sceneContainer; subtype = _arg3; type = "bullet"; side = _arg2; distance = _arg5; startX = this.x; startY = this.y; switch (_arg3){ default: damage = _arg4; speed = 10; destroyable = true; break; }; if (_arg5 > 0){ if (Math.abs(this.rotation) < 90){ this.rotation = (this.rotation - 45); dr = (((-45 * speed) / distance) * 2); } else { this.rotation = (this.rotation + 45); dr = (((45 * speed) / distance) * 2); }; }; dx = (speed * Math.cos(((this.rotation / 180) * Math.PI))); dy = (speed * Math.sin(((this.rotation / 180) * Math.PI))); } private function getDistance():Number{ var _local1:*; var _local2:*; _local1 = (this.x - startX); _local2 = (startY - this.y); return (Math.sqrt(((_local1 * _local1) + (_local2 * _local2)))); } public function moveClip(){ if (distance > 0){ if ((((dy > 0)) && ((Math.abs(dx) < 2)))){ dx = 0; dy = speed; } else { this.rotation = (this.rotation - dr); dx = (speed * Math.cos(((this.rotation / 180) * Math.PI))); dy = (speed * Math.sin(((this.rotation / 180) * Math.PI))); }; }; this.x = (this.x - dx); this.y = (this.y + dy); } } }//package
Section 67
//BaseSound (BaseSound) package { import flash.events.*; import flash.utils.*; import flash.media.*; public class BaseSound extends Sound { private var sndTransform:SoundTransform; private var sndFadeOut:Boolean; private var sndFadeIn:Boolean; private var sndPosTime:Number; private var loop:Boolean; private var sndObj:Sound; private var sndChannel:SoundChannel; private var sndTimer:Timer; private var sndVolume:Number; private var sndPan:Number; public function BaseSound(){ sndObj = this; sndChannel = null; sndTransform = null; sndVolume = 1; sndPan = 0; sndPosTime = 0; sndFadeIn = false; sndFadeOut = false; loop = false; sndTimer = new Timer(50); sndTimer.addEventListener(TimerEvent.TIMER, sndTimerHandler); sndTimer.start(); } public function setVolume(_arg1:Number):void{ var _local2:SoundTransform; sndVolume = _arg1; if (sndChannel){ _local2 = sndChannel.soundTransform; _local2.volume = sndVolume; sndChannel.soundTransform = _local2; }; } public function stopSound():void{ if (sndChannel){ sndChannel.stop(); sndChannel.removeEventListener(Event.SOUND_COMPLETE, sound_loop); loop = false; }; } public function fadeOut(_arg1:Boolean):void{ sndFadeOut = true; sndFadeIn = false; if (_arg1){ setVolume(1); }; } public function pauseSound():void{ if (sndChannel){ sndPosTime = sndChannel.position; sndChannel.stop(); sndChannel.removeEventListener(Event.SOUND_COMPLETE, sound_loop); }; } public function playSound():void{ stopSound(); sndChannel = sndObj.play(); setVolume(sndVolume); setPan(sndPan); } public function fadeIn(_arg1:Boolean):void{ sndFadeIn = true; sndFadeOut = false; if (_arg1){ setVolume(0); }; } private function sndTimerHandler(_arg1:TimerEvent):void{ if (((sndFadeIn) && (sndFadeOut))){ sndFadeIn = false; sndFadeOut = false; setVolume(1); }; if (sndFadeIn){ sndVolume = (sndVolume + 0.01); if (sndVolume > 1){ setVolume(1); sndFadeIn = false; } else { setVolume(sndVolume); }; }; if (sndFadeOut){ sndVolume = (sndVolume - 0.01); if (sndVolume < 0){ setVolume(0); sndFadeOut = false; } else { setVolume(sndVolume); }; }; } public function setPan(_arg1:Number):void{ var _local2:SoundTransform; sndPan = _arg1; if (sndChannel){ _local2 = sndChannel.soundTransform; _local2.pan = sndPan; sndChannel.soundTransform = _local2; }; } public function resumeSound():void{ stopSound(); sndChannel = sndObj.play(sndPosTime); if (loop){ sndChannel.addEventListener(Event.SOUND_COMPLETE, sound_loop); }; setVolume(sndVolume); setPan(sndPan); } private function sound_loop(_arg1:Event){ sndChannel = sndObj.play(); setVolume(sndVolume); setPan(sndPan); sndChannel.addEventListener(Event.SOUND_COMPLETE, sound_loop); } public function playSoundLoop():void{ stopSound(); sndChannel = sndObj.play(); sndChannel.addEventListener(Event.SOUND_COMPLETE, sound_loop); setVolume(sndVolume); setPan(sndPan); loop = true; } } }//package
Section 68
//bgmcover (bgmcover) package { public dynamic class bgmcover extends BaseSound { } }//package
Section 69
//bgmintro (bgmintro) package { public dynamic class bgmintro extends BaseSound { } }//package
Section 70
//bgmstage (bgmstage) package { public dynamic class bgmstage extends BaseSound { } }//package
Section 71
//btno (btno) package { import flash.display.*; public dynamic class btno extends SimpleButton { } }//package
Section 72
//EffectContainer (EffectContainer) package { import flash.display.*; public class EffectContainer extends Sprite { private var particlesArray:Array; public function EffectContainer(){ particlesArray = new Array(); super(); } public function createParticle(_arg1, _arg2, _arg3){ var _local4:*; var _local5:*; _local5 = Math.random(); switch (_arg3){ case "specialattack": _local4 = new mc_specialfx(); break; case "cannonbullet": if (_local5 < 0.4){ _local4 = new mc_cannonblow1(); } else { if (_local5 < 0.7){ _local4 = new mc_cannonblow2(); } else { _local4 = new mc_cannonblow3(); }; }; break; case "firebullet": _local4 = new mc_redsplashfx(); break; case "icebullet": default: _local4 = new mc_bluesplashfx(); break; }; _local4.x = _arg1; _local4.y = _arg2; this.addChild(_local4); particlesArray.push(_local4); } public function moveClip(){ var _local1:*; _local1 = (particlesArray.length - 1); while (_local1 >= 0) { if (particlesArray[_local1].currentFrame == particlesArray[_local1].totalFrames){ this.removeChild(particlesArray[_local1]); particlesArray.splice(_local1, 1); } else { particlesArray[_local1].play(); }; _local1--; }; } } }//package
Section 73
//focusRectSkin (focusRectSkin) package { import flash.display.*; public dynamic class focusRectSkin extends MovieClip { } }//package
Section 74
//GameData (GameData) package { import com.kongregate.as3.client.events.*; import com.kongregate.as3.client.*; import flash.net.*; public class GameData { public var enemyInitialRange:Array; public var enemyInitialAttack:Array; public var enemyInitialDefense:Array; public var levelExperience:Number;// = 0 public var levelUnitsLost:Array; public var experienceTotal:Number;// = 0 public var maxManaCount:Number;// = 0 public var enemyInitialHealth:Array; public var levelEnemyKilled:Array; public var manaBankLevel;// = 1 public var initialManaCount:Number;// = 0 public var enemyKilled:Array; public var enemyHealth:Array; public var castleDefense:Number;// = 0 public var levelManaGained:Number;// = 0 public var experienceSpent:Number;// = 0 private var GAME_COMPLETED;// = 0 public var energyRegeneration:Number;// = 0.0277777777777778 private var BEST_MANA_EARN;// = 0 public var levelManaSpent:Number;// = 0 public var initialTurretsCreationTimer:int;// = 150 public var unlockedUnits:Array; public var unitsBuilt:Array; public var enemyStartTimerScenario:Array; public var enemyPower:Array; public var levelTurretsBuilt:Array; public var unlockedLevel:Array; public var unlockedEnemy:Array; public var turretsCreationTimerLevel:int;// = 1 public var unitsCreationTimer:Array; public var gameCompleted;// = 0 public var enemyLevelScenario:Array; public var castleInitialAttack:Number;// = 7 public var enemyRange:Array; public var unitsAttack:Array; public var castleInitialHealth:Number;// = 750 public var unitsHealth:Array; public var turretsBuilt:Array; public var turretsInitialDefense:Array; public var initialManaRegeneration:Number;// = 0.0166666666666667 public var initialUnitsCreationTimer:Array; public var enemyLevel:Array; public var unitsPower:Array; public var turretsCreationTimer:int;// = 0 public var turretsTimerPrice:Array; public var castlePower:Number;// = 0 public var levelUnitsBuilt:Array; public var manaRegenerationPrice:Array; public var enemyCreationTimer:Array; private var kongregateServiceLoaded:Boolean;// = false private var BEST_EXP_EARN;// = 0 public var unitsLevelFactor:Array; public var manaCount:Number;// = 0 public var unitsRange:Array; private var BEST_ENEMY_KILL;// = 0 public var unlockedEnemyScenario:Array; public var unitsPrice:Array; public var unlockedTurrets:Array; public var manaCountPrice:Array; public var levelTurretsLost:Array; public var castleRange:Number;// = 0 public var gameLengthScenario:Array; public var unitsInitialPower:Array; public var castlePrice:Array; public var manaRegenerationLevel:int;// = 1 public var unitsLost:Array; public var castleInitialPower:Number;// = 4 public var turretsDefense:Array; public var turretsPower:Array; public var turretsInitialPower:Array; public var turretsLost:Array; public var unitsCreationTimerLevel:int;// = 1 public var enemyTimerScenario:Array; public var unitsLevel:Array; public var tutorialShowed;// = false public var manaCountLevel:int;// = 1 public var castleAttack:Number;// = 0 public var energyCount:Number;// = 0 public var unitsInitialRange:Array; public var experience:Number;// = 0 public var castleLevel:int;// = 1 public var manaSpent:Number;// = 0 public var initialMaxManaCount:Number;// = 20 public var castleInitialRange:Number;// = 300 public var manaRegeneration:Number;// = 0 public var castleInitialDefense:Number;// = 6 public var enemyCost:Array; private var saveLabel;// = "WindKingdomTrial" public var turretsRange:Array; public var castleHealth:Number;// = 0 public var turretsInitialRange:Array; public var unitsInitialAttack:Array; private var BEST_TURRETS_BUILT;// = 0 public var turretsPrice:Array; public var manaGained:Number;// = 0 public var unitsInitialHealth:Array; private var BEST_UNITS_BUILT;// = 0 public var enemyDefense:Array; public var castleRepairTimer;// = 10 public var selectedLevel:int;// = 1 public var unitsInitialDefense:Array; public var turretsAttack:Array; public var turretsLevel:Array; public var enemyInitialPower:Array; public var unitsDefense:Array; public var unitsTimerPrice:Array; public var levelExperienceTotal:Array; public var turretsHealth:Array; private var kongregate:KongregateAPI; public var unitsCost:Array; public var turretsInitialAttack:Array; public var turretsCost:Array; public var enemyAttack:Array; public var turretsInitialHealth:Array; public function GameData(_arg1, _arg2=1){ saveLabel = "WindKingdomTrial"; unlockedLevel = new Array(true, false, false, false, false, false, false, false); experience = 0; manaRegenerationLevel = 1; manaCountLevel = 1; manaBankLevel = 1; initialManaRegeneration = (1 / 60); initialMaxManaCount = 20; initialManaCount = 0; unitsCreationTimerLevel = 1; initialUnitsCreationTimer = new Array(90, 150, 210, 270, 330); turretsCreationTimerLevel = 1; initialTurretsCreationTimer = 150; castleLevel = 1; castleRepairTimer = 10; castleInitialRange = 300; castleInitialHealth = 750; castleInitialPower = 4; castleInitialAttack = 7; castleInitialDefense = 6; unlockedTurrets = new Array(false, false, false); turretsLevel = new Array(0, 0, 0); turretsCost = new Array(150, 200, 250); turretsInitialRange = new Array(250, 300, 250); turretsInitialHealth = new Array(600, 900, 1200); turretsInitialPower = new Array(5, 6, 7); turretsInitialAttack = new Array(4, 4, 4); turretsInitialDefense = new Array(9, 9, 9); unlockedUnits = new Array(true, true, false, false, false); unitsLevel = new Array(1, 1, 0, 0, 0); unitsCost = new Array(5, 25, 50, 100, 250); unitsInitialRange = new Array(200, 200, 200, 200, 200); unitsInitialHealth = new Array(100, 300, 500, 800, 1200); unitsInitialPower = new Array(2, 5, 7, 10, 13); unitsInitialAttack = new Array(7, 7, 6, 5, 5); unitsInitialDefense = new Array(5, 5, 6, 7, 7); unlockedEnemy = new Array(true, true, true, false, false, false, false); enemyLevel = new Array(1, 1, 1, 1, 1, 1, 1); enemyCost = new Array(5, 25, 50, 200, 400, 700, 1000); enemyInitialRange = new Array(200, 200, 200, 200, 50, 200, 200); enemyInitialHealth = new Array(100, 200, 400, 700, 1000, 1400, 1800); enemyInitialPower = new Array(1, 3, 6, 9, 11, 13, 14); enemyInitialAttack = new Array(7, 7, 6, 5, 5, 7, 9); enemyInitialDefense = new Array(5, 5, 6, 7, 7, 8, 9); energyRegeneration = ((100 / 120) / 30); energyCount = 0; maxManaCount = 0; manaCount = 0; manaRegeneration = 0; selectedLevel = 1; castleRange = 0; castleHealth = 0; castlePower = 0; castleAttack = 0; castleDefense = 0; turretsCreationTimer = 0; turretsRange = new Array(0, 0, 0); turretsHealth = new Array(0, 0, 0); turretsPower = new Array(0, 0, 0); turretsAttack = new Array(0, 0, 0); turretsDefense = new Array(0, 0, 0); unitsLevelFactor = new Array(0, 0, 0, 0, 0); unitsCreationTimer = new Array(0, 0, 0, 0, 0); unitsRange = new Array(0, 0, 0, 0, 0); unitsHealth = new Array(0, 0, 0, 0, 0); unitsPower = new Array(0, 0, 0, 0, 0); unitsAttack = new Array(0, 0, 0, 0, 0); unitsDefense = new Array(0, 0, 0, 0, 0); enemyCreationTimer = new Array(0, 0, 0, 0, 0, 0, 0); enemyRange = new Array(0, 0, 0, 0, 0, 0, 0); enemyHealth = new Array(0, 0, 0, 0, 0, 0, 0); enemyPower = new Array(0, 0, 0, 0, 0, 0, 0); enemyAttack = new Array(0, 0, 0, 0, 0, 0, 0); enemyDefense = new Array(0, 0, 0, 0, 0, 0, 0); gameLengthScenario = new Array(180000, 240000, 300000, 360000, 420000, 480000, 540000, 600000); unlockedEnemyScenario = new Array([true, true, false, false, false, false, false], [true, true, true, false, false, false, false], [true, true, true, true, false, false, false], [true, true, true, true, true, false, false], [true, true, true, true, true, false, false], [true, true, true, true, true, true, false], [true, true, true, true, true, true, false], [true, true, true, true, true, true, true]); enemyStartTimerScenario = new Array([15, 2400, 99999, 99999, 99999, 99999, 99999], [15, 2400, 3600, 99999, 99999, 99999, 99999], [0, 1200, 2400, 3600, 99999, 99999, 99999], [0, 1200, 2400, 3600, 4800, 99999, 99999], [0, 600, 1200, 3600, 4800, 7200, 99999], [0, 600, 1200, 3600, 4800, 5400, 99999], [0, 300, 600, 1200, 3000, 4800, 99999], [0, 300, 600, 1200, 3000, 4800, 7200]); enemyTimerScenario = new Array([210, 365, 9999, 9999, 9999, 9999, 9999], [150, 245, 365, 9999, 9999, 9999, 9999], [300, 365, 455, 755, 9999, 9999, 9999], [300, 365, 455, 755, 815, 9999, 9999], [300, 365, 455, 755, 815, 9999, 9999], [300, 365, 455, 545, 755, 815, 9999], [300, 365, 455, 545, 755, 815, 9999], [300, 365, 455, 545, 755, 815, 905]); enemyLevelScenario = new Array([1, 1, 1, 1, 1, 1, 1], [2, 1, 1, 1, 1, 1, 1], [3, 2, 1, 1, 1, 1, 1], [3, 3, 2, 1, 1, 1, 1], [3, 3, 3, 2, 1, 1, 1], [3, 3, 3, 3, 2, 1, 1], [3, 3, 3, 3, 3, 2, 1], [3, 3, 3, 3, 3, 3, 1]); castlePrice = new Array(0, 100, 500); unitsPrice = new Array([0, 25, 50], [0, 50, 75], [50, 75, 100], [75, 150, 200], [250, 400, 600]); turretsPrice = new Array([25, 100, 250], [50, 125, 300], [75, 175, 400]); manaRegenerationPrice = new Array(25, 50, 100, 500); manaCountPrice = new Array(50, 125, 200, 350); unitsTimerPrice = new Array(25, 50, 100, 175); turretsTimerPrice = new Array(25, 50, 100, 175); levelExperience = 0; levelEnemyKilled = new Array(0, 0, 0, 0, 0, 0, 0); levelUnitsBuilt = new Array(0, 0, 0, 0, 0); levelUnitsLost = new Array(0, 0, 0, 0, 0); levelTurretsBuilt = new Array(0, 0, 0); levelTurretsLost = new Array(0, 0, 0); levelManaGained = 0; levelManaSpent = 0; levelExperienceTotal = new Array(0, 0, 0, 0, 0, 0, 0, 0); experienceTotal = 0; experienceSpent = 0; enemyKilled = new Array(0, 0, 0, 0, 0, 0, 0); unitsBuilt = new Array(0, 0, 0, 0, 0); unitsLost = new Array(0, 0, 0, 0, 0); turretsBuilt = new Array(0, 0, 0); turretsLost = new Array(0, 0, 0); manaGained = 0; manaSpent = 0; gameCompleted = 0; tutorialShowed = false; kongregateServiceLoaded = false; BEST_ENEMY_KILL = 0; BEST_UNITS_BUILT = 0; BEST_TURRETS_BUILT = 0; BEST_EXP_EARN = 0; BEST_MANA_EARN = 0; GAME_COMPLETED = 0; super(); initKongregateAPI(_arg1); selectedLevel = 1; recalculateManaCount(); recalculateManaRegeneration(); recalculateTurretsCreationTimer(); recalculateUnitsCreationTimer(); recalculateCastleData(); recalculateTurretsData(); recalculateUnitsData(); recalculateEnemyData(); } public function addTurretsBuilt(_arg1){ var _local2 = levelTurretsBuilt; var _local3 = _arg1; var _local4 = (_local2[_local3] + 1); _local2[_local3] = _local4; levelExperience = (levelExperience + (_arg1 + 2)); } public function decreaseMana(_arg1){ manaCount = (manaCount - _arg1); if (manaCount < 0){ manaCount = 0; }; levelManaSpent = (levelManaSpent + _arg1); } public function isDragonCreatable():Boolean{ return (((unlockedUnits[4]) && ((manaCount >= unitsCost[4])))); } private function recalculateTurretsCreationTimer(){ turretsCreationTimer = (initialTurretsCreationTimer - (10 * turretsCreationTimerLevel)); } public function isHealingEnable():Boolean{ return ((manaCount >= (maxManaCount / 2))); } public function increaseManaRegenerationLevel(){ if (manaRegenerationLevel < 5){ experienceTotal = (experienceTotal - manaRegenerationPrice[(manaRegenerationLevel - 1)]); experienceSpent = (experienceSpent + manaRegenerationPrice[(manaRegenerationLevel - 1)]); manaRegenerationLevel++; recalculateManaRegeneration(); }; } public function getSpecialAttackDamage():Number{ return ((castleLevel * 100)); } private function recalculateManaRegeneration(){ var _local1:*; var _local2:*; manaRegeneration = initialManaRegeneration; _local2 = 1; _local1 = 2; while (_local1 <= manaRegenerationLevel) { _local2 = (_local2 * 2); _local1++; }; manaRegeneration = (manaRegeneration * _local2); _local2 = 1; _local1 = 2; while (_local1 <= manaBankLevel) { _local2 = (_local2 * 1.4); _local1++; }; manaRegeneration = (manaRegeneration * _local2); } public function increaseUnitsPowerFactor(){ if (unitsLevelFactor[2] < 4){ manaCount = (manaCount - (20 * Math.pow((unitsLevelFactor[2] + 1), 3))); var _local1 = unitsLevelFactor; var _local2 = 2; var _local3 = (_local1[_local2] + 1); _local1[_local2] = _local3; recalculateUnitsData(); }; } public function isManaCountLevelUpgradable():Boolean{ var _local1:*; _local1 = false; if (manaCountLevel < 5){ _local1 = (experienceTotal >= manaCountPrice[(manaCountLevel - 1)]); } else { _local1 = false; }; return (_local1); } private function recalculateMaxManaCount(){ var _local1:*; var _local2:*; maxManaCount = initialMaxManaCount; _local2 = 1; _local1 = 2; while (_local1 <= manaCountLevel) { _local2 = (_local2 * 3); _local1++; }; maxManaCount = (initialMaxManaCount * _local2); _local2 = 1; _local1 = 2; while (_local1 <= manaBankLevel) { _local2 = (_local2 * 2); _local1++; }; maxManaCount = (maxManaCount * _local2); if (maxManaCount > 9999){ maxManaCount = 9999; }; } public function increaseManaCountLevel(){ if (manaCountLevel < 5){ experienceTotal = (experienceTotal - manaCountPrice[(manaCountLevel - 1)]); experienceSpent = (experienceSpent + manaCountPrice[(manaCountLevel - 1)]); manaCountLevel++; recalculateMaxManaCount(); }; } public function increaseTurretsCreationTimerLevel(){ if (turretsCreationTimerLevel < 5){ experienceTotal = (experienceTotal - turretsTimerPrice[(turretsCreationTimerLevel - 1)]); experienceSpent = (experienceSpent + turretsTimerPrice[(turretsCreationTimerLevel - 1)]); turretsCreationTimerLevel++; recalculateTurretsCreationTimer(); }; } public function isIceTurretsCreatable():Boolean{ return (((unlockedTurrets[0]) && ((manaCount >= turretsCost[0])))); } public function isTurretsCreationTimerLevelUpgradable():Boolean{ var _local1:*; _local1 = false; if (turretsCreationTimerLevel < 5){ _local1 = (experienceTotal >= turretsTimerPrice[(turretsCreationTimerLevel - 1)]); } else { _local1 = false; }; return (_local1); } public function increaseUnitsDefenseFactor(){ if (unitsLevelFactor[4] < 4){ manaCount = (manaCount - (15 * Math.pow((unitsLevelFactor[4] + 1), 3))); var _local1 = unitsLevelFactor; var _local2 = 4; var _local3 = (_local1[_local2] + 1); _local1[_local2] = _local3; recalculateUnitsData(); }; } public function increaseUnitsRangeFactor(){ if (unitsLevelFactor[0] < 4){ manaCount = (manaCount - (10 * Math.pow((unitsLevelFactor[0] + 1), 3))); var _local1 = unitsLevelFactor; var _local2:int; var _local3 = (_local1[_local2] + 1); _local1[_local2] = _local3; recalculateUnitsData(); }; } public function isTurretsCreatable(_arg1):Boolean{ return (((unlockedTurrets[_arg1]) && ((manaCount >= turretsCost[_arg1])))); } private function recalculateUnitsData(){ var _local1:*; var _local2:Number; var _local3:Number; _local2 = 1; _local3 = 1; _local1 = 0; while (_local1 < 5) { switch (unitsLevel[_local1]){ case 3: _local3 = (1.05 * 1.05); _local2 = (1.1 * 1.1); break; case 2: _local3 = 1.05; _local2 = 1.1; break; case 1: default: _local3 = 1; _local2 = 1; break; }; unitsRange[_local1] = ((unitsInitialRange[_local1] * _local2) + (unitsLevelFactor[0] * 5)); unitsHealth[_local1] = ((unitsInitialHealth[_local1] * _local2) + (unitsLevelFactor[1] * 100)); unitsPower[_local1] = ((unitsInitialPower[_local1] * _local3) + unitsLevelFactor[2]); unitsAttack[_local1] = ((unitsInitialAttack[_local1] * _local2) + unitsLevelFactor[3]); unitsDefense[_local1] = ((unitsInitialDefense[_local1] * _local2) + unitsLevelFactor[4]); _local1++; }; } public function isUnitsCreatable(_arg1):Boolean{ return (((unlockedUnits[_arg1]) && ((manaCount >= unitsCost[_arg1])))); } private function recalculateUnitsCreationTimer(){ var _local1:*; _local1 = 0; while (_local1 < 5) { unitsCreationTimer[_local1] = (initialUnitsCreationTimer[_local1] - (10 * unitsCreationTimerLevel)); _local1++; }; } public function isManaRegenerationLevelUpgradable():Boolean{ var _local1:*; _local1 = false; if (manaRegenerationLevel < 5){ _local1 = (experienceTotal >= manaRegenerationPrice[(manaRegenerationLevel - 1)]); } else { _local1 = false; }; return (_local1); } public function isManaBankUpgradable():Boolean{ if (maxManaCount < 9999){ return ((manaCount >= (maxManaCount / 2))); }; return (false); } public function submitStat(){ BEST_ENEMY_KILL = Math.floor(countEnemyKilled()); BEST_UNITS_BUILT = Math.floor(countUnitsBuilt()); BEST_TURRETS_BUILT = Math.floor(countTurretsBuilt()); BEST_EXP_EARN = Math.floor((experienceTotal + experienceSpent)); BEST_MANA_EARN = Math.floor(manaGained); GAME_COMPLETED = Math.floor(gameCompleted); if (((kongregate) && (kongregateServiceLoaded))){ kongregate.stats.submit("BEST_ENEMY_KILL", BEST_ENEMY_KILL); kongregate.stats.submit("BEST_UNITS_BUILT", BEST_UNITS_BUILT); kongregate.stats.submit("BEST_TURRETS_BUILT", BEST_TURRETS_BUILT); kongregate.stats.submit("BEST_EXP_EARN", BEST_EXP_EARN); kongregate.stats.submit("BEST_MANA_EARN", BEST_MANA_EARN); kongregate.stats.submit("GAME_COMPLETED", GAME_COMPLETED); }; } public function isDefenseUpgradable():Boolean{ return ((((manaCount >= (15 * Math.pow((unitsLevelFactor[4] + 1), 3)))) && ((unitsLevelFactor[4] < 3)))); } public function increaseUnitsAttackFactor(){ if (unitsLevelFactor[3] < 4){ manaCount = (manaCount - (15 * Math.pow((unitsLevelFactor[3] + 1), 3))); var _local1 = unitsLevelFactor; var _local2 = 3; var _local3 = (_local1[_local2] + 1); _local1[_local2] = _local3; recalculateUnitsData(); }; } public function isPowerUpgradable():Boolean{ return ((((manaCount >= (20 * Math.pow((unitsLevelFactor[2] + 1), 3)))) && ((unitsLevelFactor[2] < 3)))); } public function isTutorialOn():Boolean{ if ((((selectedLevel == 1)) && ((enemyKilled[0] == 0)))){ return (true); }; return (false); } public function isTurretsLevelUpgradable(_arg1="iceturrets"):Boolean{ var _local2:*; var _local3:*; _local3 = false; switch (_arg1){ case "thunderturret": _local2 = 2; break; case "fireturret": _local2 = 1; break; case "iceturret": default: _local2 = 0; break; }; if (turretsLevel[_local2] < 3){ _local3 = (experienceTotal >= turretsPrice[_local2][turretsLevel[_local2]]); } else { _local3 = false; }; return (_local3); } public function increaseUnitsCreationTimerLevel(){ if (unitsCreationTimerLevel < 5){ experienceTotal = (experienceTotal - unitsTimerPrice[(unitsCreationTimerLevel - 1)]); experienceSpent = (experienceSpent + unitsTimerPrice[(unitsCreationTimerLevel - 1)]); unitsCreationTimerLevel++; recalculateUnitsCreationTimer(); }; } public function addEnemyKilled(_arg1){ var _local2 = levelEnemyKilled; var _local3 = _arg1; var _local4 = (_local2[_local3] + 1); _local2[_local3] = _local4; levelExperience = (levelExperience + (_arg1 + 1)); } public function countUnitsBuilt():Number{ var _local1:*; var _local2:*; _local1 = 0; _local2 = 0; while (_local2 < 5) { _local1 = (_local1 + unitsBuilt[_local2]); _local2++; }; return (_local1); } public function resetLevelExperience(){ levelExperience = (levelExperience / 2); } public function saveData(){ var _local1:SharedObject; _local1 = SharedObject.getLocal(saveLabel); _local1.data.unlockedLevel = unlockedLevel; _local1.data.selectedLevel = selectedLevel; _local1.data.experience = experience; _local1.data.manaRegenerationLevel = manaRegenerationLevel; _local1.data.manaCountLevel = manaCountLevel; _local1.data.unitsCreationTimerLevel = unitsCreationTimerLevel; _local1.data.turretsCreationTimerLevel = turretsCreationTimerLevel; _local1.data.castleLevel = castleLevel; _local1.data.unlockedTurrets = unlockedTurrets; _local1.data.turretsLevel = turretsLevel; _local1.data.unlockedUnits = unlockedUnits; _local1.data.unitsLevel = unitsLevel; _local1.data.levelExperienceTotal = levelExperienceTotal; _local1.data.experienceTotal = experienceTotal; _local1.data.experienceSpent = experienceSpent; _local1.data.enemyKilled = enemyKilled; _local1.data.unitsBuilt = unitsBuilt; _local1.data.unitsLost = unitsLost; _local1.data.turretsBuilt = turretsBuilt; _local1.data.turretsLost = turretsLost; _local1.data.manaGained = manaGained; _local1.data.manaSpent = manaSpent; _local1.data.gameCompleted = gameCompleted; _local1.data.tutorialShowed = tutorialShowed; _local1.flush(); } public function checkData():Boolean{ var _local1:SharedObject; _local1 = SharedObject.getLocal(saveLabel); if (_local1.size == 0){ return (false); }; return (true); } public function countTurretsLost():Number{ var _local1:*; var _local2:*; _local1 = 0; _local2 = 0; while (_local2 < 3) { _local1 = (_local1 + turretsLost[_local2]); _local2++; }; return (_local1); } private function resetLevelData(){ var _local1:*; energyCount = 0; manaBankLevel = 1; levelExperience = 0; levelManaGained = 0; levelManaSpent = 0; _local1 = 0; while (_local1 < levelEnemyKilled.length) { levelEnemyKilled[_local1] = 0; _local1++; }; _local1 = 0; while (_local1 < levelUnitsBuilt.length) { levelUnitsBuilt[_local1] = 0; levelUnitsLost[_local1] = 0; _local1++; }; _local1 = 0; while (_local1 < levelTurretsBuilt.length) { levelTurretsBuilt[_local1] = 0; levelTurretsLost[_local1] = 0; _local1++; }; _local1 = 0; while (_local1 < 5) { unitsLevelFactor[_local1] = 0; _local1++; }; } public function isRangeUpgradable():Boolean{ return ((((manaCount >= (10 * Math.pow((unitsLevelFactor[0] + 1), 3)))) && ((unitsLevelFactor[0] < 3)))); } public function changeGameLevel(_arg1=1){ selectedLevel = _arg1; resetLevelData(); recalculateEnemyData(); recalculateManaRegeneration(); recalculateMaxManaCount(); recalculateManaCount(); recalculateTurretsCreationTimer(); recalculateUnitsCreationTimer(); recalculateCastleData(); recalculateTurretsData(); recalculateUnitsData(); recalculateEnemyData(); } public function countUnitsLost():Number{ var _local1:*; var _local2:*; _local1 = 0; _local2 = 0; while (_local2 < 5) { _local1 = (_local1 + unitsLost[_local2]); _local2++; }; return (_local1); } public function isHealthUpgradable():Boolean{ return ((((manaCount >= (20 * Math.pow((unitsLevelFactor[1] + 1), 3)))) && ((unitsLevelFactor[1] < 3)))); } public function isPanzerCreatable():Boolean{ return (((unlockedUnits[3]) && ((manaCount >= unitsCost[3])))); } private function initKongregateAPI(_arg1){ kongregate = new KongregateAPI(); _arg1.addChild(kongregate); kongregate.addEventListener(KongregateEvent.COMPLETE, serviceLoaded); } private function serviceLoaded(_arg1:KongregateEvent):void{ kongregate.services.connect(); kongregateServiceLoaded = true; } public function isRepairable(_arg1, _arg2):Boolean{ return ((((manaCount >= 1)) && ((_arg1 < _arg2)))); } private function recalculateTurretsData(){ var _local1:*; var _local2:Number; var _local3:Number; var _local4:Number; _local2 = 1; _local3 = 1; _local4 = 1; _local1 = 0; while (_local1 < 3) { switch (turretsLevel[_local1]){ case 3: _local4 = ((1 * 1.75) * 1.75); _local3 = (1.75 * 1.75); _local2 = (1.2 * 1.2); break; case 2: _local4 = (1 * 1.75); _local3 = 1.75; _local2 = 1.2; break; case 1: default: _local4 = 1; _local3 = 1; _local2 = 1; break; }; turretsRange[_local1] = (turretsInitialRange[_local1] * _local2); turretsHealth[_local1] = (turretsInitialHealth[_local1] * _local4); turretsPower[_local1] = (turretsInitialPower[_local1] * _local3); turretsAttack[_local1] = (turretsInitialAttack[_local1] * _local2); turretsDefense[_local1] = (turretsInitialDefense[_local1] * _local2); _local1++; }; } public function increaseTurretsLevel(_arg1="iceturret"){ var _local2:*; switch (_arg1){ case "thunderturret": _local2 = 2; break; case "fireturret": _local2 = 1; break; case "iceturret": default: _local2 = 0; break; }; experienceTotal = (experienceTotal - turretsPrice[_local2][turretsLevel[_local2]]); experienceSpent = (experienceSpent + turretsPrice[_local2][turretsLevel[_local2]]); unlockedTurrets[_local2] = true; if (turretsLevel[_local2] < 3){ var _local3 = turretsLevel; var _local4 = _local2; var _local5 = (_local3[_local4] + 1); _local3[_local4] = _local5; }; recalculateTurretsData(); } public function isCopterCreatable():Boolean{ return (((unlockedUnits[1]) && ((manaCount >= unitsCost[1])))); } public function increaseUnitsLevel(_arg1="rider"){ var _local2:*; switch (_arg1){ case "dragon": _local2 = 4; break; case "panzer": _local2 = 3; break; case "eagle": _local2 = 2; break; case "copter": _local2 = 1; break; case "rider": default: _local2 = 0; break; }; experienceTotal = (experienceTotal - unitsPrice[_local2][unitsLevel[_local2]]); experienceSpent = (experienceSpent + unitsPrice[_local2][unitsLevel[_local2]]); unlockedUnits[_local2] = true; if (unitsLevel[_local2] < 3){ var _local3 = unitsLevel; var _local4 = _local2; var _local5 = (_local3[_local4] + 1); _local3[_local4] = _local5; }; recalculateUnitsData(); } public function isUnitsCreationTimerLevelUpgradable():Boolean{ var _local1:*; _local1 = false; if (unitsCreationTimerLevel < 5){ _local1 = (experienceTotal >= unitsTimerPrice[(unitsCreationTimerLevel - 1)]); } else { _local1 = false; }; return (_local1); } public function countTurretsBuilt():Number{ var _local1:*; var _local2:*; _local1 = 0; _local2 = 0; while (_local2 < 3) { _local1 = (_local1 + turretsBuilt[_local2]); _local2++; }; return (_local1); } public function isEagleCreatable():Boolean{ return (((unlockedUnits[2]) && ((manaCount >= unitsCost[2])))); } public function increaseManaBank(){ if (manaCount >= (maxManaCount / 2)){ manaCount = (manaCount - (maxManaCount / 2)); manaBankLevel++; recalculateMaxManaCount(); recalculateManaRegeneration(); }; } public function countEnemyKilled():Number{ var _local1:*; var _local2:*; _local1 = 0; _local2 = 0; while (_local2 < 7) { _local1 = (_local1 + enemyKilled[_local2]); _local2++; }; return (_local1); } public function addUnitsLost(_arg1){ var _local2 = levelUnitsLost; var _local3 = _arg1; var _local4 = (_local2[_local3] + 1); _local2[_local3] = _local4; } public function isThunderTurretsCreatable():Boolean{ return (((unlockedTurrets[2]) && ((manaCount >= turretsCost[2])))); } public function resetData(){ levelExperience = 0; levelEnemyKilled = new Array(0, 0, 0, 0, 0, 0, 0); levelUnitsBuilt = new Array(0, 0, 0, 0, 0); levelUnitsLost = new Array(0, 0, 0, 0, 0); levelTurretsBuilt = new Array(0, 0, 0); levelTurretsLost = new Array(0, 0, 0); levelManaGained = 0; levelManaSpent = 0; unlockedLevel = null; unlockedTurrets = null; turretsLevel = null; unlockedUnits = null; unitsLevel = null; levelExperienceTotal = null; enemyKilled = null; unitsBuilt = null; unitsLost = null; turretsBuilt = null; turretsLost = null; unlockedLevel = new Array(true, false, false, false, false, false, false, false); selectedLevel = 1; experience = 0; manaRegenerationLevel = 1; manaCountLevel = 1; unitsCreationTimerLevel = 1; turretsCreationTimerLevel = 1; castleLevel = 1; unlockedTurrets = new Array(false, false, false); turretsLevel = new Array(0, 0, 0); unlockedUnits = new Array(true, true, false, false, false); unitsLevel = new Array(1, 1, 0, 0, 0); levelExperienceTotal = new Array(0, 0, 0, 0, 0, 0, 0, 0); experienceTotal = 0; experienceSpent = 0; enemyKilled = new Array(0, 0, 0, 0, 0, 0, 0); unitsBuilt = new Array(0, 0, 0, 0, 0); unitsLost = new Array(0, 0, 0, 0, 0); turretsBuilt = new Array(0, 0, 0); turretsLost = new Array(0, 0, 0); manaGained = 0; manaSpent = 0; gameCompleted = 0; tutorialShowed = false; } public function increaseMana(_arg1){ manaCount = (manaCount + _arg1); if (manaCount > maxManaCount){ manaCount = maxManaCount; }; levelManaGained = (levelManaGained + _arg1); } private function recalculateManaCount(){ manaCount = (maxManaCount / 2); } public function loadData():Boolean{ var _local1:SharedObject; _local1 = SharedObject.getLocal(saveLabel); if (_local1.size == 0){ _local1.data.unlockedLevel = unlockedLevel; _local1.data.selectedLevel = selectedLevel; _local1.data.experience = experience; _local1.data.manaRegenerationLevel = manaRegenerationLevel; _local1.data.manaCountLevel = manaCountLevel; _local1.data.unitsCreationTimerLevel = unitsCreationTimerLevel; _local1.data.turretsCreationTimerLevel = turretsCreationTimerLevel; _local1.data.castleLevel = castleLevel; _local1.data.unlockedTurrets = unlockedTurrets; _local1.data.turretsLevel = turretsLevel; _local1.data.unlockedUnits = unlockedUnits; _local1.data.unitsLevel = unitsLevel; _local1.data.levelExperienceTotal = levelExperienceTotal; _local1.data.experienceTotal = experienceTotal; _local1.data.experienceSpent = experienceSpent; _local1.data.enemyKilled = enemyKilled; _local1.data.unitsBuilt = unitsBuilt; _local1.data.unitsLost = unitsLost; _local1.data.turretsBuilt = turretsBuilt; _local1.data.turretsLost = turretsLost; _local1.data.manaGained = manaGained; _local1.data.manaSpent = manaSpent; _local1.data.gameCompleted = gameCompleted; _local1.data.tutorialShowed = tutorialShowed; _local1.flush(); }; if (_local1.data.unlockedLevel){ resetData(); unlockedLevel = _local1.data.unlockedLevel; selectedLevel = _local1.data.selectedLevel; experience = _local1.data.experience; manaRegenerationLevel = _local1.data.manaRegenerationLevel; manaCountLevel = _local1.data.manaCountLevel; unitsCreationTimerLevel = _local1.data.unitsCreationTimerLevel; turretsCreationTimerLevel = _local1.data.turretsCreationTimerLevel; castleLevel = _local1.data.castleLevel; unlockedTurrets = _local1.data.unlockedTurrets; turretsLevel = _local1.data.turretsLevel; unlockedUnits = _local1.data.unlockedUnits; unitsLevel = _local1.data.unitsLevel; levelExperienceTotal = _local1.data.levelExperienceTotal; experienceTotal = _local1.data.experienceTotal; experienceSpent = _local1.data.experienceSpent; enemyKilled = _local1.data.enemyKilled; unitsBuilt = _local1.data.unitsBuilt; unitsLost = _local1.data.unitsLost; turretsBuilt = _local1.data.turretsBuilt; turretsLost = _local1.data.turretsLost; manaGained = _local1.data.manaGained; manaSpent = _local1.data.manaSpent; gameCompleted = _local1.data.gameCompleted; tutorialShowed = _local1.data.tutorialShowed; }; if (enemyKilled[0] > 0){ return (true); }; return (false); } public function isSpecialAttackEnable():Boolean{ return ((energyCount >= 100)); } private function recalculateCastleData(){ var _local1:*; var _local2:Number; var _local3:Number; var _local4:Number; _local2 = 1; _local3 = 1; _local4 = 1; switch (castleLevel){ case 3: _local4 = ((1 * 2) * 2); _local3 = (1.75 * 1.75); _local2 = (1.2 * 1.2); break; case 2: _local4 = (1 * 2); _local3 = 1.75; _local2 = 1.2; break; case 1: default: _local4 = 1; _local3 = 1; _local2 = 1; break; }; castleRange = (castleInitialRange * _local2); castleHealth = (castleInitialHealth * _local2); castlePower = (castleInitialPower * _local3); castleAttack = (castleInitialAttack * _local2); castleDefense = (castleInitialDefense * _local2); } public function isFireTurretsCreatable():Boolean{ return (((unlockedTurrets[1]) && ((manaCount >= turretsCost[1])))); } public function isUnitsLevelUpgradable(_arg1="rider"):Boolean{ var _local2:*; var _local3:*; _local3 = false; switch (_arg1){ case "dragon": _local2 = 4; break; case "panzer": _local2 = 3; break; case "eagle": _local2 = 2; break; case "copter": _local2 = 1; break; case "rider": default: _local2 = 0; break; }; if (unitsLevel[_local2] < 3){ _local3 = (experienceTotal >= unitsPrice[_local2][unitsLevel[_local2]]); } else { _local3 = false; }; return (_local3); } public function isSkillTutorial():Boolean{ if ((((((selectedLevel == 2)) && ((enemyKilled[2] == 0)))) && (!(tutorialShowed)))){ tutorialShowed = true; return (true); }; return (false); } public function increaseUnitsHealthFactor(){ if (unitsLevelFactor[1] < 4){ manaCount = (manaCount - (20 * Math.pow((unitsLevelFactor[1] + 1), 3))); var _local1 = unitsLevelFactor; var _local2 = 1; var _local3 = (_local1[_local2] + 1); _local1[_local2] = _local3; recalculateUnitsData(); }; } public function increaseCastleLevel(){ if (castleLevel < 3){ experienceTotal = (experienceTotal - castlePrice[castleLevel]); experienceSpent = (experienceSpent + castlePrice[castleLevel]); castleLevel++; recalculateCastleData(); }; } public function isCastleLevelUpgradable():Boolean{ var _local1:*; _local1 = false; if (castleLevel < 3){ _local1 = (experienceTotal >= castlePrice[castleLevel]); } else { _local1 = false; }; return (_local1); } public function getExperiencePrice(_arg1=0):Number{ switch (_arg1){ case 12: return (manaCountPrice[(manaCountLevel - 1)]); case 11: return (manaRegenerationPrice[(manaRegenerationLevel - 1)]); case 10: return (turretsTimerPrice[(turretsCreationTimerLevel - 1)]); case 9: return (unitsTimerPrice[(unitsCreationTimerLevel - 1)]); case 8: return (unitsPrice[4][unitsLevel[4]]); case 7: return (unitsPrice[3][unitsLevel[3]]); case 6: return (unitsPrice[2][unitsLevel[2]]); case 5: return (unitsPrice[1][unitsLevel[1]]); case 4: return (unitsPrice[0][unitsLevel[0]]); case 3: return (turretsPrice[2][turretsLevel[2]]); case 2: return (turretsPrice[1][turretsLevel[1]]); case 1: return (turretsPrice[0][turretsLevel[0]]); case 0: default: return (castlePrice[castleLevel]); }; } public function commitLevelData(){ var _local1:*; experienceTotal = (experienceTotal + levelExperience); manaGained = (manaGained + levelManaGained); manaSpent = (manaSpent + levelManaSpent); _local1 = 0; while (_local1 < enemyKilled.length) { enemyKilled[_local1] = (enemyKilled[_local1] + levelEnemyKilled[_local1]); _local1++; }; _local1 = 0; while (_local1 < unitsBuilt.length) { unitsBuilt[_local1] = (unitsBuilt[_local1] + levelUnitsBuilt[_local1]); unitsLost[_local1] = (unitsLost[_local1] + levelUnitsLost[_local1]); _local1++; }; _local1 = 0; while (_local1 < turretsBuilt.length) { turretsBuilt[_local1] = (turretsBuilt[_local1] + levelTurretsBuilt[_local1]); turretsLost[_local1] = (turretsLost[_local1] + levelTurretsLost[_local1]); _local1++; }; } public function addUnitsBuilt(_arg1){ var _local2 = levelUnitsBuilt; var _local3 = _arg1; var _local4 = (_local2[_local3] + 1); _local2[_local3] = _local4; levelExperience = (levelExperience + ((_arg1 + 1) / 2)); } public function isRiderCreatable():Boolean{ return (((unlockedUnits[0]) && ((manaCount >= unitsCost[0])))); } public function addTurretsLost(_arg1){ var _local2 = levelTurretsLost; var _local3 = _arg1; var _local4 = (_local2[_local3] + 1); _local2[_local3] = _local4; levelExperience = (levelExperience + ((_arg1 + 1) / 4)); } public function isAttackUpgradable():Boolean{ return ((((manaCount >= (15 * Math.pow((unitsLevelFactor[3] + 1), 3)))) && ((unitsLevelFactor[3] < 3)))); } private function recalculateEnemyData(){ var _local1:*; var _local2:Number; var _local3:Number; _local2 = 1; _local3 = 1; _local1 = 0; while (_local1 < 7) { enemyLevel[_local1] = enemyLevelScenario[(selectedLevel - 1)][_local1]; enemyCreationTimer[_local1] = enemyTimerScenario[(selectedLevel - 1)][_local1]; unlockedEnemy[_local1] = unlockedEnemyScenario[(selectedLevel - 1)][_local1]; _local1++; }; _local1 = 0; while (_local1 < 7) { switch (enemyLevel[_local1]){ case 3: _local3 = (1.1 * 1.1); _local2 = (1.1 * 1.1); break; case 2: _local3 = 1.1; _local2 = 1.1; break; case 1: default: _local3 = 1; _local2 = 1; break; }; enemyRange[_local1] = (enemyInitialRange[_local1] * _local2); enemyHealth[_local1] = (enemyInitialHealth[_local1] * _local2); enemyPower[_local1] = (enemyInitialPower[_local1] * _local3); enemyAttack[_local1] = (enemyInitialAttack[_local1] * _local2); enemyDefense[_local1] = (enemyInitialDefense[_local1] * _local2); _local1++; }; } } }//package
Section 75
//GameManager (GameManager) package { import flash.events.*; import flash.display.*; import flash.utils.*; import flash.net.*; import flash.ui.*; public class GameManager { private var unitCreator;// = null private var panelNote; private var panelConfirm; private var turretBuildTimerInit; private var scrollingDown;// = false private var scroller;// = null private var rightPower; private var creatingEnemy;// = true private var turretCreateProgress; private var timecount; private var unitQueueArray; public var bulletArray; public var gameStartTime; private var turretBuildTimer; private var unitQueueTimerInit:int;// = 0 public var soundMgr; private var coverContainer; private var bg1;// = null private var repairingCastle;// = false private var creatorPos;// = 0 private var enemyTimer; public var gamePausedTime; public var gameData; private var levelPanel; private var createContainer; private var maxUnitQueue:int;// = 6 public var castle;// = null private var stageRoot; private var moreGameURL:URLRequest; private var turretCreator;// = null public var startPausedTime; public var unitArray; private var repairingTimer;// = 0 private var leftPower; private var distortingValue:Number;// = 0 public var turretArray; public var sceneContainer; private var unitQueueTimer; private var specialAttackTimer;// = 0 private var scrollerContainer; private var scrollingUp;// = false private var panelTutorial; private var maxDistort;// = 10 private var tparser; private var panelOption; private var rightEnemyPower; private var unitCreatorEnable; public var enemyArray; public var selectedObject;// = null private var bgContainer; public var gameState; private var framecount; private var turretCreatorEnable; private var fxContainer; private var leftEnemyPower; private var menuContainer; private var unitCreateProgress; public function GameManager(_arg1, _arg2, _arg3){ tparser = new TimeParser(); sceneContainer = new Sprite(); fxContainer = new EffectContainer(); bgContainer = new Sprite(); createContainer = new mc_turretlayer(); scrollerContainer = new Sprite(); menuContainer = new Sprite(); coverContainer = new mc_cover(); bg1 = null; scroller = null; levelPanel = new mc_levelpanel(); panelOption = new paneloption(); panelConfirm = new panelconfirm(); panelNote = new mc_levelnote(); panelTutorial = new mc_tutorial(); unitCreateProgress = new mc_progress(); turretCreateProgress = new Array(new mc_progress(), new mc_progress(), new mc_progress(), new mc_progress()); moreGameURL = new URLRequest("http://www.armorgames.com/?gamereferral=kingdomofthewind"); unitCreator = null; turretCreator = null; castle = null; enemyArray = new Array(); bulletArray = new Array(); unitArray = new Array(); turretArray = new Array(null, null, null, null); selectedObject = null; maxUnitQueue = 6; unitQueueArray = new Array(); unitQueueTimer = new Array(); unitQueueTimerInit = 0; unitCreatorEnable = new Array(true, true, true, true, true); turretBuildTimer = new Array(0, 0, 0, 0); turretBuildTimerInit = new Array(0, 0, 0, 0); turretCreatorEnable = new Array(true, true, true); creatorPos = 0; specialAttackTimer = 0; scrollingUp = false; scrollingDown = false; repairingCastle = false; repairingTimer = 0; creatingEnemy = true; enemyTimer = new Array(30, 0, 0, 0, 0, 0, 0); distortingValue = 0; maxDistort = 10; super(); gameData = _arg2; soundMgr = _arg3; stageRoot = _arg1; stageRoot.addChild(bgContainer); stageRoot.addChild(sceneContainer); stageRoot.addChild(fxContainer); stageRoot.addChild(scrollerContainer); stageRoot.addChild(createContainer); stageRoot.addChild(menuContainer); stageRoot.addChild(coverContainer); bgContainer.scaleX = 1; bgContainer.scaleY = 1; sceneContainer.scaleX = 0.955; sceneContainer.scaleY = 0.955; fxContainer.scaleX = 0.955; fxContainer.scaleY = 0.955; createContainer.scaleX = 0.955; createContainer.scaleY = 0.955; scrollerContainer.scaleX = 0.955; scrollerContainer.scaleY = 0.955; menuContainer.scaleX = 0.955; menuContainer.scaleY = 0.955; menuContainer.addChild(levelPanel); menuContainer.addChild(panelOption); menuContainer.addChild(panelConfirm); menuContainer.addChild(panelNote); menuContainer.addChild(panelTutorial); panelOption.Init(274, 335, 274, 845); panelConfirm.Init(265, 225, 265, -275); panelNote.Init(2, 462, 2, 900); if (gameData.isTutorialOn()){ panelTutorial.gotoAndStop(2); }; createBackground(); createUnitCreator(); createTurretCreator(); createScroller(); createProgress(); startGame(); } private function startUpgradeRange(_arg1=null){ if (gameData.isRangeUpgradable()){ gameData.increaseUnitsRangeFactor(); }; showNote(9); } private function stopUpgradePowerNote(_arg1=null){ hideNote(); } public function decreaseMana(_arg1){ gameData.decreaseMana(_arg1); levelPanel.manalevel.gotoAndStop(Math.floor(((gameData.manaCount / gameData.maxManaCount) * 100))); levelPanel.manapoint.text = ((Math.floor(gameData.manaCount) + "/") + Math.floor(gameData.maxManaCount)); } private function endCurrentLevel(_arg1=null){ if (panelConfirm.panelShow){ hideConfirmPanel(); }; if (panelOption.panelShow){ hideOptionPanel(); }; gameState = "stopbyrequest"; stopGame(); } private function startCopterCreator(_arg1=null){ if ((((levelPanel.iconcopter.currentFrame == 1)) && (unitCreatorEnable[1]))){ startUnitCreator(2); }; } private function stopSpecialAttackNote(_arg1=null){ hideNote(); } private function startThunderTurretCreator(_arg1=null){ if ((((levelPanel.iconthunderturret.currentFrame == 1)) && (turretCreatorEnable[2]))){ startTurretCreator(3); }; } private function destroyTurrets(){ var _local1:*; var _local2:*; _local1 = 0; while (_local1 < turretArray.length) { _local2 = turretArray[_local1]; if (_local2){ if (sceneContainer.contains(_local2)){ sceneContainer.removeChild(_local2); }; _local2.destroy(); turretArray[_local1] = null; turretBuildTimer[_local1] = 0; _local2 = null; }; _local1++; }; } private function toggleGamePause(_arg1=null){ var _local2:*; if (gameState == "pause"){ hideOptionPanel(); gameState = "play"; _local2 = 0; while (_local2 < bulletArray.length) { bulletArray[_local2].play(); _local2++; }; gamePausedTime = (gamePausedTime + (getTimer() - startPausedTime)); } else { if (gameState == "play"){ showOptionPanel(); gameState = "pause"; _local2 = 0; while (_local2 < bulletArray.length) { bulletArray[_local2].stop(); _local2++; }; startPausedTime = getTimer(); } else { if (panelOption.panelShow){ hideOptionPanel(); _local2 = 0; while (_local2 < bulletArray.length) { bulletArray[_local2].play(); _local2++; }; } else { showOptionPanel(); _local2 = 0; while (_local2 < bulletArray.length) { bulletArray[_local2].stop(); _local2++; }; }; }; }; } private function stopEagleNote(_arg1=null){ hideNote(); } private function queueUnit(_arg1, _arg2, _arg3){ var _local4:*; var _local5:*; switch (_arg1){ case "dragon": _local4 = new mc_dragon(); _local5 = 4; break; case "panzer": _local4 = new mc_panzer(); _local5 = 3; break; case "eagle": _local4 = new mc_eagle(); _local5 = 2; break; case "copter": _local4 = new mc_copter(); _local5 = 1; break; case "rider": default: _local4 = new mc_rider(); _local5 = 0; break; }; if (gameData.isUnitsCreatable(_local5)){ _local4.x = _arg2; _local4.y = _arg3; _local4.initType(this, _arg1, gameData); unitQueueArray.push(_local4); unitQueueTimer.push(gameData.unitsCreationTimer[_local5]); decreaseMana(gameData.unitsCost[_local5]); gameData.addUnitsBuilt(_local5); }; if (gameData.isTutorialOn()){ if (panelTutorial.currentFrame == 3){ panelTutorial.gotoAndPlay(4); }; }; } private function stopUpgradeRangeNote(_arg1=null){ hideNote(); } private function startUpgradeAttack(_arg1=null){ if (gameData.isAttackUpgradable()){ gameData.increaseUnitsAttackFactor(); }; showNote(12); } private function startFireTurretCreator(_arg1=null){ if ((((levelPanel.iconfireturret.currentFrame == 1)) && (turretCreatorEnable[1]))){ startTurretCreator(2); }; } private function startUnitCreator(_arg1=1){ if (unitCreator){ if (unitQueueArray.length < maxUnitQueue){ creatorPos = 0; unitCreator.visible = true; unitCreator.gotoAndStop(_arg1); unitCreator.x = scroller.btcreateunitleft.x; unitCreator.y = scroller.btcreateunitleft.y; scroller.btcreateunitleft.visible = true; scroller.btcreateunitright.visible = true; scroller.btcreateunitleft.addEventListener(MouseEvent.CLICK, createUnitLeft); scroller.btcreateunitright.addEventListener(MouseEvent.CLICK, createUnitRight); stageRoot.addEventListener(MouseEvent.MOUSE_MOVE, moveUnitCreator); }; }; if (turretCreator.visible){ stopTurretCreator(); }; if (gameData.isTutorialOn()){ if (panelTutorial.currentFrame == 2){ panelTutorial.gotoAndStop(3); }; }; } private function stopDragonNote(_arg1=null){ hideNote(); } private function startHealerNote(_arg1=null){ showNote(16); } private function stopUpgradeDefenseNote(_arg1=null){ hideNote(); } private function stopTurretCreator(){ if (((turretCreator) && (turretCreator.visible))){ if (createContainer.btcreateturret1.visible){ createContainer.btcreateturret1.visible = false; createContainer.btcreateturret1.removeEventListener(MouseEvent.CLICK, createTurret1); }; if (createContainer.btcreateturret2.visible){ createContainer.btcreateturret2.visible = false; createContainer.btcreateturret2.removeEventListener(MouseEvent.CLICK, createTurret2); }; if (createContainer.btcreateturret3.visible){ createContainer.btcreateturret3.visible = false; createContainer.btcreateturret3.removeEventListener(MouseEvent.CLICK, createTurret3); }; if (createContainer.btcreateturret4.visible){ createContainer.btcreateturret4.visible = false; createContainer.btcreateturret4.removeEventListener(MouseEvent.CLICK, createTurret4); }; turretCreator.visible = false; stageRoot.removeEventListener(MouseEvent.MOUSE_MOVE, moveUnitCreator); }; } private function startUpgradeManaNote(_arg1=null){ showNote(14); } private function hideNote(){ levelPanel.rightnote2.visible = false; levelPanel.rightnote.visible = true; } private function startUpgradeHealth(_arg1=null){ if (gameData.isHealthUpgradable()){ gameData.increaseUnitsHealthFactor(); }; showNote(10); } private function destroyBullets(){ var _local1:*; var _local2:*; _local1 = (bulletArray.length - 1); while (_local1 >= 0) { _local2 = bulletArray[_local1]; if (sceneContainer.contains(_local2)){ sceneContainer.removeChild(_local2); }; _local2.destroy(); bulletArray.splice(_local1, 1); _local2 = null; _local1--; }; } private function stopListeners(){ stageRoot.root.removeEventListener(Event.ENTER_FRAME, frameEnterHandler); stageRoot.root.removeEventListener(KeyboardEvent.KEY_DOWN, keyPressHandler); stageRoot.root.removeEventListener(KeyboardEvent.KEY_UP, keyReleaseHandler); scroller.upscroller.removeEventListener(MouseEvent.MOUSE_OVER, setScrollingUp); scroller.upscroller.removeEventListener(MouseEvent.MOUSE_OUT, resetScrollingUp); scroller.downscroller.removeEventListener(MouseEvent.MOUSE_OVER, setScrollingDown); scroller.downscroller.removeEventListener(MouseEvent.MOUSE_OUT, resetScrollingDown); levelPanel.btquitlevel.removeEventListener(MouseEvent.CLICK, endCurrentLevel); levelPanel.btplaymore.removeEventListener(MouseEvent.CLICK, playMoreGames); levelPanel.btoption.removeEventListener(MouseEvent.CLICK, toggleGamePause); levelPanel.iconrider.removeEventListener(MouseEvent.CLICK, startRiderCreator); levelPanel.iconcopter.removeEventListener(MouseEvent.CLICK, startCopterCreator); levelPanel.iconeagle.removeEventListener(MouseEvent.CLICK, startEagleCreator); levelPanel.iconpanzer.removeEventListener(MouseEvent.CLICK, startPanzerCreator); levelPanel.icondragon.removeEventListener(MouseEvent.CLICK, startDragonCreator); levelPanel.iconiceturret.removeEventListener(MouseEvent.CLICK, startIceTurretCreator); levelPanel.iconfireturret.removeEventListener(MouseEvent.CLICK, startFireTurretCreator); levelPanel.iconthunderturret.removeEventListener(MouseEvent.CLICK, startThunderTurretCreator); levelPanel.iconupgraderange.removeEventListener(MouseEvent.CLICK, startUpgradeRange); levelPanel.iconupgradehealth.removeEventListener(MouseEvent.CLICK, startUpgradeHealth); levelPanel.iconupgradepower.removeEventListener(MouseEvent.CLICK, startUpgradePower); levelPanel.iconupgradeattack.removeEventListener(MouseEvent.CLICK, startUpgradeAttack); levelPanel.iconupgradedefense.removeEventListener(MouseEvent.CLICK, startUpgradeDefense); levelPanel.iconupgrademana.removeEventListener(MouseEvent.CLICK, startUpgradeMana); levelPanel.iconrepair.removeEventListener(MouseEvent.CLICK, startRepairer); levelPanel.iconheal.removeEventListener(MouseEvent.CLICK, startHealer); levelPanel.iconspecialattack.removeEventListener(MouseEvent.CLICK, startSpecialAttack); levelPanel.iconrider.removeEventListener(MouseEvent.MOUSE_OVER, startRiderNote); levelPanel.iconcopter.removeEventListener(MouseEvent.MOUSE_OVER, startCopterNote); levelPanel.iconeagle.removeEventListener(MouseEvent.MOUSE_OVER, startEagleNote); levelPanel.iconpanzer.removeEventListener(MouseEvent.MOUSE_OVER, startPanzerNote); levelPanel.icondragon.removeEventListener(MouseEvent.MOUSE_OVER, startDragonNote); levelPanel.iconiceturret.removeEventListener(MouseEvent.MOUSE_OVER, startIceTurretNote); levelPanel.iconfireturret.removeEventListener(MouseEvent.MOUSE_OVER, startFireTurretNote); levelPanel.iconthunderturret.removeEventListener(MouseEvent.MOUSE_OVER, startThunderTurretNote); levelPanel.iconupgraderange.removeEventListener(MouseEvent.MOUSE_OVER, startUpgradeRangeNote); levelPanel.iconupgradehealth.removeEventListener(MouseEvent.MOUSE_OVER, startUpgradeHealthNote); levelPanel.iconupgradepower.removeEventListener(MouseEvent.MOUSE_OVER, startUpgradePowerNote); levelPanel.iconupgradeattack.removeEventListener(MouseEvent.MOUSE_OVER, startUpgradeAttackNote); levelPanel.iconupgradedefense.removeEventListener(MouseEvent.MOUSE_OVER, startUpgradeDefenseNote); levelPanel.iconupgrademana.removeEventListener(MouseEvent.MOUSE_OVER, startUpgradeManaNote); levelPanel.iconrepair.removeEventListener(MouseEvent.MOUSE_OVER, startRepairerNote); levelPanel.iconheal.removeEventListener(MouseEvent.MOUSE_OVER, startHealerNote); levelPanel.iconspecialattack.removeEventListener(MouseEvent.MOUSE_OVER, startSpecialAttackNote); levelPanel.iconrider.removeEventListener(MouseEvent.MOUSE_OUT, stopRiderNote); levelPanel.iconcopter.removeEventListener(MouseEvent.MOUSE_OUT, stopCopterNote); levelPanel.iconeagle.removeEventListener(MouseEvent.MOUSE_OUT, stopEagleNote); levelPanel.iconpanzer.removeEventListener(MouseEvent.MOUSE_OUT, stopPanzerNote); levelPanel.icondragon.removeEventListener(MouseEvent.MOUSE_OUT, stopDragonNote); levelPanel.iconiceturret.removeEventListener(MouseEvent.MOUSE_OUT, stopIceTurretNote); levelPanel.iconfireturret.removeEventListener(MouseEvent.MOUSE_OUT, stopFireTurretNote); levelPanel.iconthunderturret.removeEventListener(MouseEvent.MOUSE_OUT, stopThunderTurretNote); levelPanel.iconupgraderange.removeEventListener(MouseEvent.MOUSE_OUT, stopUpgradeRangeNote); levelPanel.iconupgradehealth.removeEventListener(MouseEvent.MOUSE_OUT, stopUpgradeHealthNote); levelPanel.iconupgradepower.removeEventListener(MouseEvent.MOUSE_OUT, stopUpgradePowerNote); levelPanel.iconupgradeattack.removeEventListener(MouseEvent.MOUSE_OUT, stopUpgradeAttackNote); levelPanel.iconupgradedefense.removeEventListener(MouseEvent.MOUSE_OUT, stopUpgradeDefenseNote); levelPanel.iconupgrademana.removeEventListener(MouseEvent.MOUSE_OUT, stopUpgradeManaNote); levelPanel.iconrepair.removeEventListener(MouseEvent.MOUSE_OUT, stopRepairerNote); levelPanel.iconheal.removeEventListener(MouseEvent.MOUSE_OUT, stopHealerNote); levelPanel.iconspecialattack.removeEventListener(MouseEvent.MOUSE_OUT, stopSpecialAttackNote); } private function startUpgradePowerNote(_arg1=null){ showNote(11); } private function setTurretTimer(){ var _local1:*; _local1 = 0; while (_local1 < 4) { if (turretBuildTimer[_local1] > 0){ if (turretBuildTimerInit[_local1] == 0){ turretBuildTimerInit[_local1] = turretBuildTimer[_local1]; }; var _local2 = turretBuildTimer; var _local3 = _local1; var _local4 = (_local2[_local3] - 1); _local2[_local3] = _local4; turretCreateProgress[_local1].gotoAndStop((101 - Math.floor(((turretBuildTimer[_local1] / turretBuildTimerInit[_local1]) * 100)))); if (turretBuildTimer[_local1] == 0){ if (turretArray[_local1]){ turretBuildTimerInit[_local1] = 0; sceneContainer.addChild(turretArray[_local1]); turretArray[_local1].visible = true; }; }; }; _local1++; }; } private function stopFireTurretNote(_arg1=null){ hideNote(); } private function startUpgradeRangeNote(_arg1=null){ showNote(9); } private function showNote(_arg1=1){ panelNote.gotoAndStop(_arg1); switch (_arg1){ case 17: levelPanel.rightnote2.txt1.text = "Cast\nSpecial Attack"; levelPanel.rightnote2.txt2.text = "shortcut [V]\nFull energy needed"; if (gameData.energyCount >= 100){ levelPanel.rightnote2.txt3.text = "Ready to use"; } else { levelPanel.rightnote2.txt3.text = "Recharging..."; }; levelPanel.rightnote2.gotoAndStop(1); break; case 16: levelPanel.rightnote2.txt1.text = "Heal\nPresent Units"; levelPanel.rightnote2.txt2.text = "shortcut [C]"; levelPanel.rightnote2.txt3.text = (Math.ceil((gameData.maxManaCount / 2)) + " mana"); levelPanel.rightnote2.gotoAndStop(1); break; case 15: levelPanel.rightnote2.txt1.text = "Repair Castle"; levelPanel.rightnote2.txt2.text = "shortcut [X]"; levelPanel.rightnote2.txt3.text = "1 mana for 10"; levelPanel.rightnote2.gotoAndStop(2); break; case 14: levelPanel.rightnote2.txt1.text = "Increase\nMax. Manapool"; levelPanel.rightnote2.txt2.text = "shortcut [Z]"; if (gameData.maxManaCount < 9999){ levelPanel.rightnote2.txt3.text = (Math.ceil((gameData.maxManaCount / 2)) + " mana"); } else { levelPanel.rightnote2.txt3.text = "Max. reached"; }; levelPanel.rightnote2.gotoAndStop(1); break; case 13: levelPanel.rightnote2.txt1.text = "Increase\nUnits Defense"; levelPanel.rightnote2.txt2.text = "shortcut [G]"; levelPanel.rightnote2.txt3.text = (Math.ceil((15 * Math.pow((gameData.unitsLevelFactor[4] + 1), 3))) + " mana"); levelPanel.rightnote2.gotoAndStop(2); break; case 12: levelPanel.rightnote2.txt1.text = "Increase\nUnits Attack"; levelPanel.rightnote2.txt2.text = "shortcut [F]"; levelPanel.rightnote2.txt3.text = (Math.ceil((15 * Math.pow((gameData.unitsLevelFactor[3] + 1), 3))) + " mana"); levelPanel.rightnote2.gotoAndStop(1); break; case 11: levelPanel.rightnote2.txt1.text = "Increase\nUnits Level"; levelPanel.rightnote2.txt2.text = "shortcut [D]"; levelPanel.rightnote2.txt3.text = (Math.ceil((20 * Math.pow((gameData.unitsLevelFactor[2] + 1), 3))) + " mana"); levelPanel.rightnote2.gotoAndStop(1); break; case 10: levelPanel.rightnote2.txt1.text = "Increase\nUnits Health"; levelPanel.rightnote2.txt2.text = "shortcut [S]"; levelPanel.rightnote2.txt3.text = (Math.ceil((20 * Math.pow((gameData.unitsLevelFactor[1] + 1), 3))) + " mana"); levelPanel.rightnote2.gotoAndStop(2); break; case 9: levelPanel.rightnote2.txt1.text = "Increase\nUnits Range"; levelPanel.rightnote2.txt2.text = "shortcut [A]"; levelPanel.rightnote2.txt3.text = (Math.ceil((10 * Math.pow((gameData.unitsLevelFactor[0] + 1), 3))) + " mana"); levelPanel.rightnote2.gotoAndStop(1); break; case 8: levelPanel.rightnote2.txt1.text = "Create\n Thunder Turret"; levelPanel.rightnote2.txt2.text = ((((("shortcut [E]\nlevel:" + gameData.turretsPower[2]) + "\nattack:") + gameData.turretsAttack[2]) + "\ndefense:") + gameData.turretsDefense[2]); levelPanel.rightnote2.txt3.text = (Math.ceil(gameData.turretsCost[2]) + " mana"); levelPanel.rightnote2.gotoAndStop(1); break; case 7: levelPanel.rightnote2.txt1.text = "Create\n Fire Turret"; levelPanel.rightnote2.txt2.text = ((((("shortcut [W]\nlevel:" + gameData.turretsPower[1]) + "\nattack:") + gameData.turretsAttack[1]) + "\ndefense:") + gameData.turretsDefense[1]); levelPanel.rightnote2.txt3.text = (Math.ceil(gameData.turretsCost[1]) + " mana"); levelPanel.rightnote2.gotoAndStop(2); break; case 6: levelPanel.rightnote2.txt1.text = "Create\n Ice Turret"; levelPanel.rightnote2.txt2.text = ((((("shortcut [Q]\nlevel:" + gameData.turretsPower[0]) + "\nattack:") + gameData.turretsAttack[0]) + "\ndefense:") + gameData.turretsDefense[0]); levelPanel.rightnote2.txt3.text = (Math.ceil(gameData.turretsCost[0]) + " mana"); levelPanel.rightnote2.gotoAndStop(1); break; case 5: levelPanel.rightnote2.txt1.text = "Create Dragon"; levelPanel.rightnote2.txt2.text = ((((("shortcut [5]\nlevel:" + gameData.unitsPower[4]) + "\nattack:") + gameData.unitsAttack[4]) + "\ndefense:") + gameData.unitsDefense[4]); levelPanel.rightnote2.txt3.text = (Math.ceil(gameData.unitsCost[4]) + " mana"); levelPanel.rightnote2.gotoAndStop(2); break; case 4: levelPanel.rightnote2.txt1.text = "Create Panzer"; levelPanel.rightnote2.txt2.text = ((((("shortcut [4]\nlevel:" + gameData.unitsPower[3]) + "\nattack:") + gameData.unitsAttack[3]) + "\ndefense:") + gameData.unitsDefense[3]); levelPanel.rightnote2.txt3.text = (Math.ceil(gameData.unitsCost[3]) + " mana"); levelPanel.rightnote2.gotoAndStop(1); break; case 3: levelPanel.rightnote2.txt1.text = "Create Eagle"; levelPanel.rightnote2.txt2.text = ((((("shortcut [3]\nlevel:" + gameData.unitsPower[2]) + "\nattack:") + gameData.unitsAttack[2]) + "\ndefense:") + gameData.unitsDefense[2]); levelPanel.rightnote2.txt3.text = (Math.ceil(gameData.unitsCost[2]) + " mana"); levelPanel.rightnote2.gotoAndStop(1); break; case 2: levelPanel.rightnote2.txt1.text = "Create Copter"; levelPanel.rightnote2.txt2.text = ((((("shortcut [2]\nlevel:" + gameData.unitsPower[1]) + "\nattack:") + gameData.unitsAttack[1]) + "\ndefense:") + gameData.unitsDefense[1]); levelPanel.rightnote2.txt3.text = (Math.ceil(gameData.unitsCost[1]) + " mana"); levelPanel.rightnote2.gotoAndStop(2); break; case 1: default: levelPanel.rightnote2.txt1.text = "Create Rider"; levelPanel.rightnote2.txt2.text = ((((("shortcut [1]\nlevel:" + gameData.unitsPower[0]) + "\nattack:") + gameData.unitsAttack[0]) + "\ndefense:") + gameData.unitsDefense[0]); levelPanel.rightnote2.txt3.text = (Math.ceil(gameData.unitsCost[0]) + " mana"); levelPanel.rightnote2.gotoAndStop(1); break; }; levelPanel.rightnote.visible = false; levelPanel.rightnote2.visible = true; } private function startUpgradeDefenseNote(_arg1=null){ showNote(13); } private function setEnemyTimer(){ var _local1:*; var _local2:*; _local2 = 1; if (gameData.gameCompleted > gameData.selectedLevel){ if (gameData.selectedLevel > 4){ if (unitArray.length > 10){ _local2 = 3; } else { if (unitArray.length > 6){ _local2 = 2; } else { _local2 = 1; }; }; } else { if (unitArray.length > 8){ _local2 = 2; } else { _local2 = 1; }; }; } else { if ((((enemyArray.length < 4)) && ((unitArray.length > 11)))){ enemyTimer[0] = (enemyTimer[0] + gameData.enemyCreationTimer[0]); }; }; _local1 = 0; while (_local1 < 7) { if (enemyArray.length <= (11 + gameData.selectedLevel)){ enemyTimer[_local1] = (enemyTimer[_local1] + _local2); }; _local1++; }; if (((gameData.unlockedEnemy[0]) && ((enemyTimer[0] > gameData.enemyCreationTimer[0])))){ enemyTimer[0] = 0; createEnemy("smallbat"); gameData.enemyCreationTimer[0] = (gameData.enemyCreationTimer[0] * (1 - (gameData.selectedLevel / 1000))); }; if (((gameData.unlockedEnemy[1]) && ((enemyTimer[1] > gameData.enemyCreationTimer[1])))){ enemyTimer[1] = 0; createEnemy("evilcopter"); gameData.enemyCreationTimer[1] = (gameData.enemyCreationTimer[1] * (1 - (gameData.selectedLevel / 1000))); }; if (((gameData.unlockedEnemy[2]) && ((enemyTimer[2] > gameData.enemyCreationTimer[2])))){ enemyTimer[2] = 0; createEnemy("bigbat"); gameData.enemyCreationTimer[2] = (gameData.enemyCreationTimer[2] * (1 - (gameData.selectedLevel / 1000))); }; if (((gameData.unlockedEnemy[3]) && ((enemyTimer[3] > gameData.enemyCreationTimer[3])))){ enemyTimer[3] = 0; createEnemy("evilpanzer"); gameData.enemyCreationTimer[3] = (gameData.enemyCreationTimer[3] * (1 - (gameData.selectedLevel / 1000))); }; if (((gameData.unlockedEnemy[4]) && ((enemyTimer[4] > gameData.enemyCreationTimer[4])))){ enemyTimer[4] = 0; createEnemy("evilknight"); gameData.enemyCreationTimer[4] = (gameData.enemyCreationTimer[4] * (1 - (gameData.selectedLevel / 1000))); }; if (((gameData.unlockedEnemy[5]) && ((enemyTimer[5] > gameData.enemyCreationTimer[5])))){ enemyTimer[5] = 0; createEnemy("evildragon"); gameData.enemyCreationTimer[5] = (gameData.enemyCreationTimer[5] * (1 - (gameData.selectedLevel / 1000))); }; if (((gameData.unlockedEnemy[6]) && ((enemyTimer[6] > gameData.enemyCreationTimer[6])))){ enemyTimer[6] = 0; createEnemy("evilultimate"); gameData.enemyCreationTimer[6] = (gameData.enemyCreationTimer[6] * (1 - (gameData.selectedLevel / 1000))); }; } private function createUnit(){ var _local1:*; switch (unitCreator.currentFrame){ case 5: _local1 = "dragon"; break; case 4: _local1 = "panzer"; break; case 3: _local1 = "eagle"; break; case 2: _local1 = "copter"; break; case 1: default: _local1 = "rider"; break; }; switch (creatorPos){ case 1: queueUnit(_local1, scroller.btcreateunitright.x, scroller.btcreateunitright.y); break; case 0: default: queueUnit(_local1, scroller.btcreateunitleft.x, scroller.btcreateunitleft.y); break; }; stopUnitCreator(); } private function resetScrollingUp(_arg1=null){ scrollingUp = false; } private function showEnergyMeter(){ if (gameData.energyCount < 100){ gameData.energyCount = (gameData.energyCount + gameData.energyRegeneration); levelPanel.iconspecialattack.powermeter.gotoAndStop(Math.floor((gameData.energyCount + 1))); if (gameData.energyCount > 100){ gameData.energyCount = 100; }; }; } private function createTurret1(_arg1){ var _local2:*; switch (turretCreator.currentFrame){ case 3: _local2 = "thunderturret"; break; case 2: _local2 = "fireturret"; break; case 1: default: _local2 = "iceturret"; break; }; buildTurret(0, _local2, createContainer.btcreateturret1.x, createContainer.btcreateturret1.y); stopTurretCreator(); } private function createTurret2(_arg1){ var _local2:*; switch (turretCreator.currentFrame){ case 3: _local2 = "thunderturret"; break; case 2: _local2 = "fireturret"; break; case 1: default: _local2 = "iceturret"; break; }; buildTurret(1, _local2, createContainer.btcreateturret2.x, createContainer.btcreateturret2.y); stopTurretCreator(); } private function createTurret3(_arg1){ var _local2:*; switch (turretCreator.currentFrame){ case 3: _local2 = "thunderturret"; break; case 2: _local2 = "fireturret"; break; case 1: default: _local2 = "iceturret"; break; }; buildTurret(2, _local2, createContainer.btcreateturret3.x, createContainer.btcreateturret3.y); stopTurretCreator(); } private function createTurret4(_arg1){ var _local2:*; switch (turretCreator.currentFrame){ case 3: _local2 = "thunderturret"; break; case 2: _local2 = "fireturret"; break; case 1: default: _local2 = "iceturret"; break; }; buildTurret(3, _local2, createContainer.btcreateturret4.x, createContainer.btcreateturret4.y); stopTurretCreator(); } private function startIceTurretNote(_arg1=null){ showNote(6); } private function startDragonNote(_arg1=null){ showNote(5); } private function startPanzerCreator(_arg1=null){ if ((((levelPanel.iconpanzer.currentFrame == 1)) && (unitCreatorEnable[3]))){ startUnitCreator(4); }; } private function stopUpgradeManaNote(_arg1=null){ hideNote(); } private function stopUnitCreator(){ if (((unitCreator) && (unitCreator.visible))){ unitCreator.visible = false; scroller.btcreateunitleft.visible = false; scroller.btcreateunitright.visible = false; scroller.btcreateunitleft.removeEventListener(MouseEvent.CLICK, createUnitLeft); scroller.btcreateunitright.removeEventListener(MouseEvent.CLICK, createUnitRight); stageRoot.removeEventListener(MouseEvent.MOUSE_MOVE, moveUnitCreator); }; } private function moveClip(){ var _local1:*; leftEnemyPower = 0; rightEnemyPower = 0; leftPower = 0; rightPower = 0; fxContainer.moveClip(); if (castle){ castle.moveClip(); }; _local1 = (turretArray.length - 1); while (_local1 >= 0) { if (turretArray[_local1]){ if (turretArray[_local1].visible){ turretArray[_local1].moveClip(); }; if (turretArray[_local1].currentFrame == turretArray[_local1].totalFrames){ sceneContainer.removeChild(turretArray[_local1]); gameData.addTurretsLost(turretArray[_local1].typeInt); turretArray[_local1].destroy(); turretArray[_local1] = null; }; }; _local1--; }; _local1 = (bulletArray.length - 1); while (_local1 >= 0) { if (bulletArray[_local1].visible){ bulletArray[_local1].moveClip(); }; if (bulletArray[_local1].currentFrame == bulletArray[_local1].totalFrames){ sceneContainer.removeChild(bulletArray[_local1]); bulletArray[_local1].destroy(); bulletArray.splice(_local1, 1); }; _local1--; }; _local1 = (unitArray.length - 1); while (_local1 >= 0) { if (unitArray[_local1].visible){ unitArray[_local1].moveClip(); if (unitArray[_local1].x < 275){ leftPower = (leftPower + unitArray[_local1].power); } else { rightPower = (rightPower + unitArray[_local1].power); }; }; if (unitArray[_local1].currentFrame == unitArray[_local1].totalFrames){ sceneContainer.removeChild(unitArray[_local1]); gameData.addUnitsLost(unitArray[_local1].typeInt); unitArray[_local1].destroy(); unitArray.splice(_local1, 1); }; _local1--; }; _local1 = (enemyArray.length - 1); while (_local1 >= 0) { if (enemyArray[_local1].visible){ enemyArray[_local1].moveClip(); if (enemyArray[_local1].x < 275){ leftEnemyPower = (leftEnemyPower + enemyArray[_local1].power); } else { rightEnemyPower = (rightEnemyPower + enemyArray[_local1].power); }; }; if (enemyArray[_local1].currentFrame == enemyArray[_local1].totalFrames){ increaseMana((enemyArray[_local1].cost / 2)); sceneContainer.removeChild(enemyArray[_local1]); gameData.addEnemyKilled(enemyArray[_local1].typeInt); enemyArray[_local1].destroy(); enemyArray.splice(_local1, 1); }; _local1--; }; if ((leftEnemyPower + rightEnemyPower) <= 25){ levelPanel.leftbalancelevel.gotoAndStop(Math.floor((101 - ((leftEnemyPower / 25) * 100)))); levelPanel.rightbalancelevel.gotoAndStop(Math.floor((101 - ((rightEnemyPower / 25) * 100)))); } else { if ((leftEnemyPower + rightEnemyPower) <= 100){ levelPanel.leftbalancelevel.gotoAndStop(Math.floor((101 - ((leftEnemyPower / 100) * 100)))); levelPanel.rightbalancelevel.gotoAndStop(Math.floor((101 - ((rightEnemyPower / 100) * 100)))); } else { if ((leftEnemyPower + rightEnemyPower) <= 300){ levelPanel.leftbalancelevel.gotoAndStop(Math.floor((101 - ((leftEnemyPower / 300) * 100)))); levelPanel.rightbalancelevel.gotoAndStop(Math.floor((101 - ((rightEnemyPower / 300) * 100)))); } else { levelPanel.leftbalancelevel.gotoAndStop(Math.floor((101 - (leftEnemyPower / 500)))); levelPanel.rightbalancelevel.gotoAndStop(Math.floor((101 - (rightEnemyPower / 500)))); }; }; }; } private function createUnitLeft(_arg1){ var _local2:*; switch (unitCreator.currentFrame){ case 5: _local2 = "dragon"; break; case 4: _local2 = "panzer"; break; case 3: _local2 = "eagle"; break; case 2: _local2 = "copter"; break; case 1: default: _local2 = "rider"; break; }; queueUnit(_local2, scroller.btcreateunitleft.x, scroller.btcreateunitleft.y); stopUnitCreator(); } private function moveTurretCreator(_arg1){ if (turretCreator){ turretCreator.x = _arg1.stageX; turretCreator.y = _arg1.stageY; if (createContainer.btcreateturret1.visible){ if (getDistance(createContainer.btcreateturret1, turretCreator) < 50){ turretCreator.x = createContainer.btcreateturret1.x; turretCreator.y = createContainer.btcreateturret1.y; }; } else { if (createContainer.btcreateturret2.visible){ if (getDistance(createContainer.btcreateturret2, turretCreator) < 50){ turretCreator.x = createContainer.btcreateturret2.x; turretCreator.y = createContainer.btcreateturret2.y; }; } else { if (createContainer.btcreateturret3.visible){ if (getDistance(createContainer.btcreateturret3, turretCreator) < 50){ turretCreator.x = createContainer.btcreateturret3.x; turretCreator.y = createContainer.btcreateturret3.y; }; } else { if (createContainer.btcreateturret4.visible){ if (getDistance(createContainer.btcreateturret4, turretCreator) < 50){ turretCreator.x = createContainer.btcreateturret4.x; turretCreator.y = createContainer.btcreateturret4.y; }; }; }; }; }; }; } private function destroyEnemies(){ var _local1:*; var _local2:*; _local1 = (enemyArray.length - 1); while (_local1 >= 0) { _local2 = enemyArray[_local1]; if (sceneContainer.contains(_local2)){ sceneContainer.removeChild(_local2); }; _local2.destroy(); enemyArray.splice(_local1, 1); _local2 = null; _local1--; }; } private function startUpgradeMana(_arg1=null){ if (gameData.manaCount >= (gameData.maxManaCount / 3)){ gameData.increaseManaBank(); increaseMana(0); }; showNote(14); } private function startIceTurretCreator(_arg1=null){ if ((((levelPanel.iconiceturret.currentFrame == 1)) && (turretCreatorEnable[0]))){ startTurretCreator(1); }; } private function showConfirmPanel(_arg1=null){ if (!panelConfirm.panelShow){ panelConfirm.Show(); panelConfirm.btyes.addEventListener(MouseEvent.CLICK, endCurrentLevel); panelConfirm.btcancel.addEventListener(MouseEvent.CLICK, hideConfirmPanel); }; } private function startFireTurretNote(_arg1=null){ showNote(7); } private function startThunderTurretNote(_arg1=null){ showNote(8); } private function setScrollingDown(_arg1=null){ if (((turretCreator.visible) || (unitCreator.visible))){ scrollingUp = false; scrollingDown = false; } else { scrollingUp = false; scrollingDown = true; }; } private function buildTurret(_arg1, _arg2, _arg3, _arg4){ var _local5:*; var _local6:*; switch (_arg2){ case "thunderturret": _local5 = new mc_thunderturret(); _local6 = 2; break; case "fireturret": _local5 = new mc_fireturret(); _local6 = 1; break; case "iceturret": default: _local5 = new mc_iceturret(); _local6 = 0; break; }; if (gameData.isTurretsCreatable(_local6)){ _local5.x = _arg3; _local5.y = _arg4; _local5.visible = false; _local5.initType(this, _arg2, gameData); turretArray[_arg1] = _local5; turretBuildTimer[_arg1] = gameData.turretsCreationTimer; decreaseMana(gameData.turretsCost[_local6]); gameData.addTurretsBuilt(_local6); }; } private function startEagleCreator(_arg1=null){ if ((((levelPanel.iconeagle.currentFrame == 1)) && (unitCreatorEnable[2]))){ startUnitCreator(3); }; } private function stopIceTurretNote(_arg1=null){ hideNote(); } private function createTurret(){ var _local1:*; switch (turretCreator.currentFrame){ case 3: _local1 = "thunderturret"; break; case 2: _local1 = "fireturret"; break; case 1: default: _local1 = "iceturret"; break; }; switch (creatorPos){ case 3: buildTurret(3, _local1, createContainer.btcreateturret4.x, createContainer.btcreateturret4.y); break; case 2: buildTurret(2, _local1, createContainer.btcreateturret3.x, createContainer.btcreateturret3.y); break; case 1: buildTurret(1, _local1, createContainer.btcreateturret2.x, createContainer.btcreateturret2.y); break; case 0: default: buildTurret(0, _local1, createContainer.btcreateturret1.x, createContainer.btcreateturret1.y); break; }; stopTurretCreator(); } public function regenerateMana(){ increaseMana(gameData.manaRegeneration); } public function stopGame(){ stopListeners(); destroyCastle(); destroyTurrets(); destroyBullets(); destroyEnemies(); destroyUnits(); stageRoot.removeChild(bgContainer); stageRoot.removeChild(sceneContainer); stageRoot.removeChild(fxContainer); stageRoot.removeChild(scrollerContainer); stageRoot.removeChild(menuContainer); stageRoot.removeChild(coverContainer); if (gameState == "stopbyrequest"){ gameData.resetLevelExperience(); gameData.commitLevelData(); stageRoot.gotoAndPlay("playerquit"); } else { if (gameState == "stopplayerloose"){ gameData.resetLevelExperience(); gameData.commitLevelData(); stageRoot.gotoAndPlay("playerloose"); } else { if (gameState == "stopplayerwin"){ gameData.commitLevelData(); gameData.unlockedLevel[gameData.selectedLevel] = true; stageRoot.gotoAndPlay("playerwin"); }; }; }; gameState = "stop"; } public function createBullet(_arg1, _arg2, _arg3, _arg4, _arg5){ var _local6:*; var _local7:*; switch (_arg4){ case "frozenbullet": soundMgr.playSFX("cannonshoot"); _local6 = new mc_frozenbullet(); _local7 = getDistance(_arg1, _arg2); break; case "cannonbullet": soundMgr.playSFX("cannonshoot"); _local6 = new mc_cannonbullet(); _local7 = getDistance(_arg1, _arg2); break; case "firebullet": soundMgr.playSFX("plasmashoot"); _local6 = new mc_firebullet(); _local7 = 0; break; case "icebullet": default: soundMgr.playSFX("plasmashoot"); _local6 = new mc_icebullet(); _local7 = 0; break; }; _local6.x = _arg1.x; _local6.y = _arg1.y; _local6.rotation = getAngle(_arg1, _arg2); sceneContainer.addChild(_local6); _local6.initType(this, _arg3, _arg4, _arg5, _local7); bulletArray.push(_local6); } private function startSpecialAttack(_arg1=null){ if (gameData.isSpecialAttackEnable()){ specialAttackTimer = 15; gameData.energyCount = 0; fxContainer.createParticle(castle.x, castle.y, "specialattack"); soundMgr.playSFX("specialattack"); setDistortTimer(10); showNote(17); }; } private function moveCreator(_arg1=false){ if (unitCreator.visible){ switch (creatorPos){ case 1: creatorPos = 0; unitCreator.x = scroller.btcreateunitleft.x; unitCreator.y = scroller.btcreateunitleft.y; break; case 0: default: creatorPos = 1; unitCreator.x = scroller.btcreateunitright.x; unitCreator.y = scroller.btcreateunitright.y; break; }; } else { if (turretCreator.visible){ if (_arg1){ switch (creatorPos){ case 3: if (createContainer.btcreateturret1.visible){ creatorPos = 0; turretCreator.x = createContainer.btcreateturret1.x; turretCreator.y = createContainer.btcreateturret1.y; } else { if (createContainer.btcreateturret2.visible){ creatorPos = 1; turretCreator.x = createContainer.btcreateturret2.x; turretCreator.y = createContainer.btcreateturret2.y; } else { if (createContainer.btcreateturret3.visible){ creatorPos = 2; turretCreator.x = createContainer.btcreateturret3.x; turretCreator.y = createContainer.btcreateturret3.y; }; }; }; break; case 2: if (createContainer.btcreateturret3.visible){ creatorPos = 3; turretCreator.x = createContainer.btcreateturret4.x; turretCreator.y = createContainer.btcreateturret4.y; } else { if (createContainer.btcreateturret1.visible){ creatorPos = 0; turretCreator.x = createContainer.btcreateturret1.x; turretCreator.y = createContainer.btcreateturret1.y; } else { if (createContainer.btcreateturret2.visible){ creatorPos = 1; turretCreator.x = createContainer.btcreateturret2.x; turretCreator.y = createContainer.btcreateturret2.y; }; }; }; break; case 1: if (createContainer.btcreateturret2.visible){ creatorPos = 2; turretCreator.x = createContainer.btcreateturret3.x; turretCreator.y = createContainer.btcreateturret3.y; } else { if (createContainer.btcreateturret3.visible){ creatorPos = 3; turretCreator.x = createContainer.btcreateturret4.x; turretCreator.y = createContainer.btcreateturret4.y; } else { if (createContainer.btcreateturret1.visible){ creatorPos = 0; turretCreator.x = createContainer.btcreateturret1.x; turretCreator.y = createContainer.btcreateturret1.y; }; }; }; break; case 0: default: if (createContainer.btcreateturret1.visible){ creatorPos = 1; turretCreator.x = createContainer.btcreateturret2.x; turretCreator.y = createContainer.btcreateturret2.y; } else { if (createContainer.btcreateturret2.visible){ creatorPos = 2; turretCreator.x = createContainer.btcreateturret3.x; turretCreator.y = createContainer.btcreateturret3.y; } else { if (createContainer.btcreateturret3.visible){ creatorPos = 3; turretCreator.x = createContainer.btcreateturret4.x; turretCreator.y = createContainer.btcreateturret4.y; }; }; }; break; }; } else { switch (creatorPos){ case 3: if (createContainer.btcreateturret3.visible){ creatorPos = 2; turretCreator.x = createContainer.btcreateturret3.x; turretCreator.y = createContainer.btcreateturret3.y; } else { if (createContainer.btcreateturret2.visible){ creatorPos = 1; turretCreator.x = createContainer.btcreateturret2.x; turretCreator.y = createContainer.btcreateturret2.y; } else { if (createContainer.btcreateturret1.visible){ creatorPos = 0; turretCreator.x = createContainer.btcreateturret1.x; turretCreator.y = createContainer.btcreateturret1.y; }; }; }; break; case 2: if (createContainer.btcreateturret2.visible){ creatorPos = 1; turretCreator.x = createContainer.btcreateturret2.x; turretCreator.y = createContainer.btcreateturret2.y; } else { if (createContainer.btcreateturret1.visible){ creatorPos = 0; turretCreator.x = createContainer.btcreateturret1.x; turretCreator.y = createContainer.btcreateturret1.y; } else { if (createContainer.btcreateturret4.visible){ creatorPos = 3; turretCreator.x = createContainer.btcreateturret4.x; turretCreator.y = createContainer.btcreateturret4.y; }; }; }; break; case 1: if (createContainer.btcreateturret1.visible){ creatorPos = 0; turretCreator.x = createContainer.btcreateturret1.x; turretCreator.y = createContainer.btcreateturret1.y; } else { if (createContainer.btcreateturret4.visible){ creatorPos = 3; turretCreator.x = createContainer.btcreateturret4.x; turretCreator.y = createContainer.btcreateturret4.y; } else { if (createContainer.btcreateturret3.visible){ creatorPos = 2; turretCreator.x = createContainer.btcreateturret3.x; turretCreator.y = createContainer.btcreateturret3.y; }; }; }; break; case 0: default: if (createContainer.btcreateturret4.visible){ creatorPos = 3; turretCreator.x = createContainer.btcreateturret4.x; turretCreator.y = createContainer.btcreateturret4.y; } else { if (createContainer.btcreateturret3.visible){ creatorPos = 2; turretCreator.x = createContainer.btcreateturret3.x; turretCreator.y = createContainer.btcreateturret3.y; } else { if (createContainer.btcreateturret2.visible){ creatorPos = 1; turretCreator.x = createContainer.btcreateturret2.x; turretCreator.y = createContainer.btcreateturret2.y; }; }; }; break; }; }; }; }; } private function createCastle(_arg1=1){ if (!castle){ castle = new mc_castle(); castle.x = 275; castle.y = 200; castle.initType(this, "castle", gameData); castle.level = _arg1; sceneContainer.addChild(castle); castle.repairer.visible = false; showHealth(); }; switch (_arg1){ case 3: castle.gotoAndStop(3); break; case 2: castle.gotoAndStop(2); break; case 1: default: castle.gotoAndStop(1); break; }; } private function stopThunderTurretNote(_arg1=null){ hideNote(); } private function resetScrollingDown(_arg1=null){ scrollingDown = false; } public function getAngle(_arg1, _arg2):Number{ var _local3:*; var _local4:*; _local3 = (_arg1.x - _arg2.x); _local4 = (_arg2.y - _arg1.y); return (((Math.atan2(_local4, _local3) * 180) / Math.PI)); } private function stopRepairerNote(_arg1=null){ hideNote(); } private function createBackground(_arg1=1){ switch (_arg1){ case 1: default: if (!bg1){ bg1 = new background1(); bg1.x = 0; bg1.y = 0; bgContainer.addChild(bg1); }; break; }; } private function createProgress(){ unitCreateProgress.x = levelPanel.queue1.x; unitCreateProgress.y = levelPanel.queue1.y; unitCreateProgress.gotoAndStop(unitCreateProgress.totalFrames); menuContainer.addChild(unitCreateProgress); turretCreateProgress[0].x = createContainer.btcreateturret1.x; turretCreateProgress[0].y = createContainer.btcreateturret1.y; turretCreateProgress[0].gotoAndStop(turretCreateProgress[0].totalFrames); createContainer.addChild(turretCreateProgress[0]); turretCreateProgress[1].x = createContainer.btcreateturret2.x; turretCreateProgress[1].y = createContainer.btcreateturret2.y; turretCreateProgress[1].gotoAndStop(turretCreateProgress[1].totalFrames); createContainer.addChild(turretCreateProgress[1]); turretCreateProgress[2].x = createContainer.btcreateturret3.x; turretCreateProgress[2].y = createContainer.btcreateturret3.y; turretCreateProgress[2].gotoAndStop(turretCreateProgress[2].totalFrames); createContainer.addChild(turretCreateProgress[2]); turretCreateProgress[3].x = createContainer.btcreateturret4.x; turretCreateProgress[3].y = createContainer.btcreateturret4.y; turretCreateProgress[3].gotoAndStop(turretCreateProgress[3].totalFrames); createContainer.addChild(turretCreateProgress[3]); } private function startRiderNote(_arg1=null){ showNote(1); } private function showOptionPanel(_arg1=null){ if (!panelOption.panelShow){ levelPanel.gameshadow.visible = true; panelOption.Show(); getVolumeLevel(); panelOption.btresumegame.addEventListener(MouseEvent.CLICK, toggleGamePause); panelOption.btplaymore.addEventListener(MouseEvent.CLICK, playMoreGames); panelOption.btquitlevel.addEventListener(MouseEvent.CLICK, showConfirmPanel); panelOption.bgmvol.addEventListener(MouseEvent.MOUSE_MOVE, SetBGMVolumeLevel); panelOption.sfxvol.addEventListener(MouseEvent.MOUSE_MOVE, SetSFXVolumeLevel); panelOption.bgmvol.addEventListener(MouseEvent.MOUSE_UP, SetBGMVolumeLevel); panelOption.sfxvol.addEventListener(MouseEvent.MOUSE_UP, SetSFXVolumeLevel); panelOption.bgmvol.addEventListener(MouseEvent.CLICK, SetBGMVolumeLevel); panelOption.sfxvol.addEventListener(MouseEvent.CLICK, SetSFXVolumeLevel); }; } private function getVolumeLevel(){ panelOption.bgmvol.value = Math.floor((soundMgr.bgmVolume * 10)); panelOption.sfxvol.value = Math.floor((soundMgr.sfxVolume * 10)); } private function startDragonCreator(_arg1=null){ if ((((levelPanel.icondragon.currentFrame == 1)) && (unitCreatorEnable[4]))){ startUnitCreator(5); }; } private function startUpgradeAttackNote(_arg1=null){ showNote(12); } private function createUnitRight(_arg1){ var _local2:*; switch (unitCreator.currentFrame){ case 5: _local2 = "dragon"; break; case 4: _local2 = "panzer"; break; case 3: _local2 = "eagle"; break; case 2: _local2 = "copter"; break; case 1: default: _local2 = "rider"; break; }; queueUnit(_local2, scroller.btcreateunitright.x, scroller.btcreateunitright.y); stopUnitCreator(); } private function createScroller(){ if (!scroller){ scroller = new mc_scroller(); scrollerContainer.addChild(scroller); scroller.btcreateunitleft.visible = false; scroller.btcreateunitright.visible = false; createContainer.btcreateturret1.visible = false; createContainer.btcreateturret2.visible = false; createContainer.btcreateturret3.visible = false; createContainer.btcreateturret4.visible = false; }; } private function frameEnterHandler(_arg1){ if (gameState == "play"){ calculateFrameCount(); regenerateMana(); if (repairingCastle){ setCastleTimer(); } else { if (castle.repairer.visible){ castle.repairer.visible = false; }; }; if (creatingEnemy){ setEnemyTimer(); } else { if (enemyArray.length == 0){ gameState = "stopplayerwin"; stopGame(); }; }; if (distortingValue > 0){ setDistortTimer(); }; setUnitTimer(); setTurretTimer(); setSpecialAttackTimer(); moveClip(); detectBulletHit(); setPanels(); showTimeRemaining(); showEnergyMeter(); } else { if (gameState == "gameover"){ moveClip(); regenerateMana(); }; }; showObjectStatus(); scrollScene(); } private function stopCopterNote(_arg1=null){ hideNote(); } public function setSpecialAttackTimer(){ var _local1:*; if (specialAttackTimer > 0){ specialAttackTimer--; if (specialAttackTimer == 0){ _local1 = 0; while (_local1 < enemyArray.length) { if (getDistance(castle, enemyArray[_local1]) <= (castle.range * 3)){ enemyArray[_local1].reduceHealth(gameData.getSpecialAttackDamage()); } else { enemyArray[_local1].reduceHealth((gameData.getSpecialAttackDamage() / 2)); }; _local1++; }; }; }; } private function startUpgradeHealthNote(_arg1=null){ showNote(10); } private function setCastleTimer(){ if (gameData.isRepairable(castle.health, castle.maxhealth)){ if (!castle.repairer.visible){ castle.repairer.visible = true; }; if (repairingTimer >= gameData.castleRepairTimer){ castle.health = (castle.health + 10); showHealth(); decreaseMana(1); repairingTimer = 0; } else { repairingTimer++; }; } else { repairingCastle = false; if (castle.repairer.visible){ castle.repairer.visible = false; }; }; } private function createUnitCreator(){ if (!unitCreator){ unitCreator = new mc_creator(); unitCreator.visible = false; unitCreator.x = 275; unitCreator.y = 275; scrollerContainer.addChild(unitCreator); }; } public function getDistance(_arg1, _arg2):Number{ var _local3:*; var _local4:*; _local3 = (_arg1.x - _arg2.x); _local4 = (_arg2.y - _arg1.y); return (Math.sqrt(((_local3 * _local3) + (_local4 * _local4)))); } public function setEnemyTarget(_arg1){ var _local2:*; castle.setTarget(_arg1); _local2 = (turretArray.length - 1); while (_local2 >= 0) { if (((turretArray[_local2]) && (!((turretArray[_local2].status == "destroyed"))))){ turretArray[_local2].setTarget(_arg1); }; _local2--; }; _local2 = (unitArray.length - 1); while (_local2 >= 0) { if (unitArray[_local2].status != "destroyed"){ unitArray[_local2].setTarget(_arg1); }; _local2--; }; } public function startGame(){ var _local1:*; gameState = "play"; createCastle(gameData.castleLevel); startListeners(); setPanels(); levelPanel.rightnote2.visible = false; levelPanel.rightnote.visible = true; _local1 = 0; while (_local1 < 7) { enemyTimer[_local1] = -(gameData.enemyStartTimerScenario[(gameData.selectedLevel - 1)][_local1]); _local1++; }; repairingCastle = false; creatingEnemy = true; gameStartTime = getTimer(); gamePausedTime = 0; } private function startRepairer(_arg1=null){ if (!repairingCastle){ repairingCastle = gameData.isRepairable; } else { repairingCastle = false; }; showNote(15); } private function createTurretCreator(){ if (!turretCreator){ turretCreator = new mc_turretcreator(); turretCreator.visible = false; turretCreator.x = 275; turretCreator.y = 275; scrollerContainer.addChild(turretCreator); }; } private function SetBGMVolumeLevel(_arg1=null){ if (soundMgr.bgmVolume != (panelOption.bgmvol.value / 10)){ soundMgr.adjustBGM((panelOption.bgmvol.value / 10)); }; } private function keyPressHandler(_arg1){ switch (_arg1.keyCode){ case Keyboard.UP: scrollingUp = true; break; case Keyboard.DOWN: scrollingDown = true; break; }; } private function keyReleaseHandler(_arg1){ if (gameState == "play"){ switch (_arg1.keyCode){ case 49: if (unitCreatorEnable[0]){ startRiderCreator(); }; break; case 50: if (unitCreatorEnable[1]){ startCopterCreator(); }; break; case 51: if (unitCreatorEnable[2]){ startEagleCreator(); }; break; case 52: if (unitCreatorEnable[3]){ startPanzerCreator(); }; break; case 53: if (unitCreatorEnable[4]){ startDragonCreator(); }; break; case 81: if (turretCreatorEnable[0]){ startIceTurretCreator(); }; break; case 87: if (turretCreatorEnable[1]){ startFireTurretCreator(); }; break; case 69: if (turretCreatorEnable[2]){ startThunderTurretCreator(); }; break; case Keyboard.ESCAPE: stopUnitCreator(); stopTurretCreator(); if (gameState == "pause"){ toggleGamePause(); }; break; case 80: stopUnitCreator(); stopTurretCreator(); toggleGamePause(); break; case 65: startUpgradeRange(); break; case 83: startUpgradeHealth(); break; case 68: startUpgradePower(); break; case 70: startUpgradeAttack(); break; case 71: startUpgradeDefense(); break; case 90: startUpgradeMana(); break; case 88: startRepairer(); break; case 67: startHealer(); break; case 86: startSpecialAttack(); break; case Keyboard.UP: scrollingUp = false; break; case Keyboard.DOWN: scrollingDown = false; break; case Keyboard.LEFT: if (((unitCreator) && (unitCreator.visible))){ moveCreator(false); } else { if (((turretCreator) && (turretCreator.visible))){ moveCreator(false); }; }; break; case Keyboard.RIGHT: if (((unitCreator) && (unitCreator.visible))){ moveCreator(true); } else { if (((turretCreator) && (turretCreator.visible))){ moveCreator(true); }; }; break; case Keyboard.SPACE: if (((unitCreator) && (unitCreator.visible))){ createUnit(); } else { if (((turretCreator) && (turretCreator.visible))){ createTurret(); }; }; break; }; } else { switch (_arg1.keyCode){ case Keyboard.ESCAPE: stopUnitCreator(); stopTurretCreator(); if (gameState == "pause"){ toggleGamePause(); }; break; case 80: stopUnitCreator(); stopTurretCreator(); toggleGamePause(); break; }; }; } private function startUpgradeDefense(_arg1=null){ if (gameData.isDefenseUpgradable()){ gameData.increaseUnitsDefenseFactor(); }; showNote(13); } private function startRepairerNote(_arg1=null){ showNote(15); } private function moveUnitCreator(_arg1){ if (unitCreator){ unitCreator.x = _arg1.stageX; unitCreator.y = _arg1.stageY; if (getDistance(unitCreator, scroller.btcreateunitleft) < 50){ unitCreator.x = scroller.btcreateunitleft.x; unitCreator.y = scroller.btcreateunitleft.y; } else { if (getDistance(unitCreator, scroller.btcreateunitright) < 50){ unitCreator.x = scroller.btcreateunitright.x; unitCreator.y = scroller.btcreateunitright.y; }; }; }; } private function destroyCastle(){ if (castle){ if (sceneContainer.contains(castle)){ sceneContainer.removeChild(castle); }; castle.destroy(); castle = null; }; } private function destroyUnits(){ var _local1:*; var _local2:*; unitQueueArray.splice(0); unitQueueTimer.splice(0); _local1 = (unitArray.length - 1); while (_local1 >= 0) { _local2 = unitArray[_local1]; if (sceneContainer.contains(_local2)){ sceneContainer.removeChild(_local2); }; _local2.destroy(); unitArray.splice(_local1, 1); _local2 = null; _local1--; }; } private function startHealer(_arg1=null){ var _local2:*; if (gameData.manaCount >= (gameData.maxManaCount / 2)){ gameData.manaCount = (gameData.manaCount - (gameData.maxManaCount / 2)); _local2 = 0; while (_local2 < unitArray.length) { unitArray[_local2].splashSign.play(); unitArray[_local2].resetHealth(); _local2++; }; showNote(16); }; } private function playMoreGames(_arg1=null){ navigateToURL(moreGameURL, "_blank"); } private function stopPanzerNote(_arg1=null){ hideNote(); } private function SetSFXVolumeLevel(_arg1=null){ if (soundMgr.sfxVolume != (panelOption.sfxvol.value / 10)){ soundMgr.adjustSFX((panelOption.sfxvol.value / 10)); }; } private function calculateFrameCount(){ var _local1:*; _local1 = Math.floor(((getTimer() - gameStartTime) / 1000)); if (_local1 != timecount){ if (enemyArray.length > 0){ levelPanel.note.text = ((("Enemy Wave | count: " + enemyArray.length) + " | ") + tparser.Parse(((getTimer() - gameStartTime) - gamePausedTime))); }; timecount = _local1; framecount = 0; } else { framecount++; }; } public function increaseMana(_arg1){ gameData.increaseMana(_arg1); levelPanel.manalevel.gotoAndStop(Math.floor(((gameData.manaCount / gameData.maxManaCount) * 100))); levelPanel.manapoint.text = ((Math.floor(gameData.manaCount) + "/") + Math.floor(gameData.maxManaCount)); } private function stopRiderNote(_arg1=null){ hideNote(); } private function showTimeRemaining(){ levelPanel.progresslevel.gotoAndStop((Math.floor(((((getTimer() - gameStartTime) - gamePausedTime) / gameData.gameLengthScenario[(gameData.selectedLevel - 1)]) * 100)) + 1)); if (((getTimer() - gameStartTime) - gamePausedTime) >= gameData.gameLengthScenario[(gameData.selectedLevel - 1)]){ creatingEnemy = false; }; } public function showObjectStatus(_arg1=null){ if (_arg1){ if (((selectedObject) && (!((selectedObject == _arg1))))){ selectedObject.selectedSign.visible = false; }; selectedObject = _arg1; selectedObject.selectedSign.visible = true; selectedObject.selectedSign.gotoAndPlay(1); }; if (selectedObject){ levelPanel.rightnote.txt1.text = selectedObject.type; levelPanel.rightnote.txt2.text = ((("level : " + Math.floor(selectedObject.power)) + "\nhealth : ") + Math.floor(selectedObject.health)); switch (selectedObject.status){ case "closing": if ((((selectedObject.type == "castle")) || ((selectedObject.type == "turret")))){ levelPanel.rightnote.txt3.text = "Waiting"; } else { levelPanel.rightnote.txt3.text = "Closing enemy"; }; break; case "idle": levelPanel.rightnote.txt3.text = "Waiting"; break; case "attacking": case "attackmove": levelPanel.rightnote.txt3.text = "Attacking enemy"; break; default: levelPanel.rightnote.txt3.text = ""; break; }; if (selectedObject.status == "destroyed"){ selectedObject = null; levelPanel.rightnote.txt1.text = ("Day #0" + gameData.selectedLevel); levelPanel.rightnote.txt2.text = ""; levelPanel.rightnote.txt3.text = ""; levelPanel.rightnote.gotoAndStop(2); } else { if (selectedObject.side == "enemy"){ levelPanel.rightnote.gotoAndStop(1); } else { levelPanel.rightnote.gotoAndStop(2); }; }; } else { selectedObject = null; levelPanel.rightnote.txt1.text = ("Day #0" + gameData.selectedLevel); levelPanel.rightnote.txt2.text = ""; levelPanel.rightnote.txt3.text = ""; levelPanel.rightnote.gotoAndStop(2); }; } private function hideConfirmPanel(_arg1=null){ if (panelConfirm.panelShow){ panelConfirm.Hide(); panelConfirm.btyes.removeEventListener(MouseEvent.CLICK, endCurrentLevel); panelConfirm.btcancel.removeEventListener(MouseEvent.CLICK, hideConfirmPanel); }; } private function stopUpgradeAttackNote(_arg1=null){ hideNote(); } private function setScrollingUp(_arg1=null){ if (((turretCreator.visible) || (unitCreator.visible))){ scrollingUp = false; scrollingDown = false; } else { scrollingUp = true; scrollingDown = false; }; } private function startCopterNote(_arg1=null){ showNote(2); } public function showHealth(){ levelPanel.healthlevel.gotoAndStop(Math.floor(((castle.health / castle.maxhealth) * 100))); } private function stopUpgradeHealthNote(_arg1=null){ hideNote(); } private function startSpecialAttackNote(_arg1=null){ showNote(17); } private function startUpgradePower(_arg1=null){ if (gameData.isPowerUpgradable()){ gameData.increaseUnitsPowerFactor(); }; showNote(11); } private function detectBulletHit(){ var _local1:*; var _local2:*; _local1 = 0; while (_local1 < bulletArray.length) { _local2 = detectHit(bulletArray[_local1], bulletArray[_local1].side); if (((((_local2) && (_local2.visible))) && (!((_local2.status == "destroyed"))))){ if (bulletArray[_local1].destroyable){ fxContainer.createParticle(bulletArray[_local1].x, bulletArray[_local1].y, bulletArray[_local1].subtype); bulletArray[_local1].gotoAndPlay("destroyed"); switch (bulletArray[_local1].subtype){ case "frozenbullet": case "cannonbullet": soundMgr.playSFX("cannonhit"); break; case "icebullet": case "firebullet": soundMgr.playSFX("plasmahit"); break; }; }; _local2.reduceHealth(bulletArray[_local1].damage); }; _local1++; }; } private function stopHealerNote(_arg1=null){ hideNote(); } private function startRiderCreator(_arg1=null){ if ((((levelPanel.iconrider.currentFrame == 1)) && (unitCreatorEnable[0]))){ startUnitCreator(1); }; } private function scrollScene(){ if (scrollingUp){ if (sceneContainer.y < 0){ sceneContainer.y = (sceneContainer.y + 5); } else { scrollingUp = false; }; bgContainer.y = sceneContainer.y; fxContainer.y = sceneContainer.y; createContainer.y = sceneContainer.y; } else { if (scrollingDown){ if (sceneContainer.y > -200){ sceneContainer.y = (sceneContainer.y - 5); } else { scrollingDown = false; }; bgContainer.y = sceneContainer.y; fxContainer.y = sceneContainer.y; createContainer.y = sceneContainer.y; }; }; } private function startEagleNote(_arg1=null){ showNote(3); } private function setUnitTimer(){ var _local1:*; if (unitQueueTimer.length > 0){ if (unitQueueTimer[0] > 0){ if (unitQueueTimerInit == 0){ unitQueueTimerInit = unitQueueTimer[0]; }; if (unitArray.length <= 12){ var _local2 = unitQueueTimer; var _local3:int; var _local4 = (_local2[_local3] - 1); _local2[_local3] = _local4; }; unitCreateProgress.gotoAndStop((101 - Math.floor(((unitQueueTimer[0] / unitQueueTimerInit) * 100)))); if (unitQueueTimer[0] == 0){ _local1 = unitQueueArray[0]; unitQueueArray.splice(0, 1); unitQueueTimer.splice(0, 1); sceneContainer.addChild(_local1); unitArray.push(_local1); unitQueueTimerInit = unitQueueArray[0]; }; } else { unitQueueTimer[0] = 1; }; }; } private function startTurretCreator(_arg1=1){ if (((turretCreator) && (((((((!(turretArray[0])) || (!(turretArray[1])))) || (!(turretArray[2])))) || (!(turretArray[3])))))){ sceneContainer.y = 0; bgContainer.y = sceneContainer.y; fxContainer.y = sceneContainer.y; createContainer.y = sceneContainer.y; turretCreator.visible = true; turretCreator.gotoAndStop(_arg1); if (!turretArray[0]){ creatorPos = 0; turretCreator.x = createContainer.btcreateturret1.x; turretCreator.y = createContainer.btcreateturret1.y; } else { if (!turretArray[1]){ creatorPos = 1; turretCreator.x = createContainer.btcreateturret2.x; turretCreator.y = createContainer.btcreateturret2.y; } else { if (!turretArray[2]){ creatorPos = 2; turretCreator.x = createContainer.btcreateturret3.x; turretCreator.y = createContainer.btcreateturret3.y; } else { if (!turretArray[3]){ creatorPos = 3; turretCreator.x = createContainer.btcreateturret4.x; turretCreator.y = createContainer.btcreateturret4.y; }; }; }; }; if (!turretArray[0]){ createContainer.btcreateturret1.visible = true; createContainer.btcreateturret1.addEventListener(MouseEvent.CLICK, createTurret1); }; if (!turretArray[1]){ createContainer.btcreateturret2.visible = true; createContainer.btcreateturret2.addEventListener(MouseEvent.CLICK, createTurret2); }; if (!turretArray[2]){ createContainer.btcreateturret3.visible = true; createContainer.btcreateturret3.addEventListener(MouseEvent.CLICK, createTurret3); }; if (!turretArray[3]){ createContainer.btcreateturret4.visible = true; createContainer.btcreateturret4.addEventListener(MouseEvent.CLICK, createTurret4); }; stageRoot.addEventListener(MouseEvent.MOUSE_MOVE, moveTurretCreator); }; if (unitCreator.visible){ stopUnitCreator(); }; } private function createEnemy(_arg1){ var _local2:*; switch (_arg1){ case "evilultimate": _local2 = new mc_evilultimate(); _local2.initType(this, "evilultimate", gameData); sceneContainer.addChild(_local2); enemyArray.push(_local2); break; case "evildragon": _local2 = new mc_evildragon(); _local2.initType(this, "evildragon", gameData); sceneContainer.addChild(_local2); enemyArray.push(_local2); break; case "evilknight": _local2 = new mc_blackknight(); _local2.initType(this, "evilknight", gameData); sceneContainer.addChild(_local2); enemyArray.push(_local2); break; case "evilpanzer": _local2 = new mc_evilpanzer(); _local2.initType(this, "evilpanzer", gameData); sceneContainer.addChild(_local2); enemyArray.push(_local2); break; case "bigbat": _local2 = new mc_bigbat(); _local2.initType(this, "bigbat", gameData); sceneContainer.addChild(_local2); enemyArray.push(_local2); break; case "evilcopter": _local2 = new mc_evilcopter(); _local2.initType(this, "evilcopter", gameData); sceneContainer.addChild(_local2); enemyArray.push(_local2); break; case "smallbat": default: _local2 = new mc_smallbat(); _local2.initType(this, "smallbat", gameData); sceneContainer.addChild(_local2); enemyArray.push(_local2); break; }; _local2.y = (800 + (Math.random() * 50)); if (Math.random() >= 0.5){ _local2.x = (25 + (Math.random() * 25)); } else { _local2.x = (525 - (Math.random() * 25)); }; } private function setPanels(){ if (levelPanel.gameshadow.visible){ levelPanel.gameshadow.visible = false; }; if (unitQueueArray.length >= 1){ levelPanel.queue1.gotoAndStop((unitQueueArray[0].typeInt + 2)); } else { levelPanel.queue1.gotoAndStop(1); }; if (unitQueueArray.length >= 2){ levelPanel.queue2.gotoAndStop((unitQueueArray[1].typeInt + 2)); } else { levelPanel.queue2.gotoAndStop(1); }; if (unitQueueArray.length >= 3){ levelPanel.queue3.gotoAndStop((unitQueueArray[2].typeInt + 2)); } else { levelPanel.queue3.gotoAndStop(1); }; if (unitQueueArray.length >= 4){ levelPanel.queue4.gotoAndStop((unitQueueArray[3].typeInt + 2)); } else { levelPanel.queue4.gotoAndStop(1); }; if (unitQueueArray.length >= 5){ levelPanel.queue5.gotoAndStop((unitQueueArray[4].typeInt + 2)); } else { levelPanel.queue5.gotoAndStop(1); }; if (unitQueueArray.length >= 6){ levelPanel.queue6.gotoAndStop((unitQueueArray[5].typeInt + 2)); } else { levelPanel.queue6.gotoAndStop(1); }; if (gameData.unlockedUnits[0]){ if (gameData.isRiderCreatable()){ levelPanel.iconrider.gotoAndStop(1); } else { levelPanel.iconrider.gotoAndStop(2); }; } else { levelPanel.iconrider.visible = false; }; if (gameData.unlockedUnits[1]){ if (gameData.isCopterCreatable()){ levelPanel.iconcopter.gotoAndStop(1); } else { levelPanel.iconcopter.gotoAndStop(2); }; } else { levelPanel.iconcopter.visible = false; }; if (gameData.unlockedUnits[2]){ if (gameData.isEagleCreatable()){ levelPanel.iconeagle.gotoAndStop(1); } else { levelPanel.iconeagle.gotoAndStop(2); }; } else { levelPanel.iconeagle.visible = false; }; if (gameData.unlockedUnits[3]){ if (gameData.isPanzerCreatable()){ levelPanel.iconpanzer.gotoAndStop(1); } else { levelPanel.iconpanzer.gotoAndStop(2); }; } else { levelPanel.iconpanzer.visible = false; }; if (gameData.unlockedUnits[4]){ if (gameData.isDragonCreatable()){ levelPanel.icondragon.gotoAndStop(1); } else { levelPanel.icondragon.gotoAndStop(2); }; } else { levelPanel.icondragon.visible = false; }; if (gameData.unlockedTurrets[0]){ if (gameData.isIceTurretsCreatable()){ levelPanel.iconiceturret.gotoAndStop(1); } else { levelPanel.iconiceturret.gotoAndStop(2); }; } else { levelPanel.iconiceturret.visible = false; }; if (gameData.unlockedTurrets[1]){ if (gameData.isFireTurretsCreatable()){ levelPanel.iconfireturret.gotoAndStop(1); } else { levelPanel.iconfireturret.gotoAndStop(2); }; } else { levelPanel.iconfireturret.visible = false; }; if (gameData.unlockedTurrets[2]){ if (gameData.isThunderTurretsCreatable()){ levelPanel.iconthunderturret.gotoAndStop(1); } else { levelPanel.iconthunderturret.gotoAndStop(2); }; } else { levelPanel.iconthunderturret.visible = false; }; if (gameData.isRangeUpgradable()){ levelPanel.iconupgraderange.gotoAndStop(1); } else { levelPanel.iconupgraderange.gotoAndStop(2); }; if (gameData.isHealthUpgradable()){ levelPanel.iconupgradehealth.gotoAndStop(1); } else { levelPanel.iconupgradehealth.gotoAndStop(2); }; if (gameData.isPowerUpgradable()){ levelPanel.iconupgradepower.gotoAndStop(1); } else { levelPanel.iconupgradepower.gotoAndStop(2); }; if (gameData.isAttackUpgradable()){ levelPanel.iconupgradeattack.gotoAndStop(1); } else { levelPanel.iconupgradeattack.gotoAndStop(2); }; if (gameData.isDefenseUpgradable()){ levelPanel.iconupgradedefense.gotoAndStop(1); } else { levelPanel.iconupgradedefense.gotoAndStop(2); }; if (gameData.isManaBankUpgradable()){ levelPanel.iconupgrademana.gotoAndStop(1); } else { levelPanel.iconupgrademana.gotoAndStop(2); }; if (((castle) && (gameData.isRepairable(castle.health, castle.maxhealth)))){ levelPanel.iconrepair.gotoAndStop(1); } else { levelPanel.iconrepair.gotoAndStop(2); }; if (gameData.isHealingEnable()){ levelPanel.iconheal.gotoAndStop(1); } else { levelPanel.iconheal.gotoAndStop(2); }; if (gameData.isSpecialAttackEnable()){ levelPanel.iconspecialattack.gotoAndStop(1); } else { levelPanel.iconspecialattack.gotoAndStop(2); }; } private function hideOptionPanel(_arg1=null){ if (panelOption.panelShow){ if (panelConfirm.panelShow){ hideConfirmPanel(); }; levelPanel.gameshadow.visible = false; panelOption.Hide(); panelOption.btresumegame.removeEventListener(MouseEvent.CLICK, toggleGamePause); panelOption.btplaymore.removeEventListener(MouseEvent.CLICK, playMoreGames); panelOption.btquitlevel.removeEventListener(MouseEvent.CLICK, endCurrentLevel); panelOption.bgmvol.removeEventListener(MouseEvent.MOUSE_MOVE, SetBGMVolumeLevel); panelOption.sfxvol.removeEventListener(MouseEvent.MOUSE_MOVE, SetSFXVolumeLevel); panelOption.bgmvol.removeEventListener(MouseEvent.MOUSE_UP, SetBGMVolumeLevel); panelOption.sfxvol.removeEventListener(MouseEvent.MOUSE_UP, SetSFXVolumeLevel); panelOption.bgmvol.removeEventListener(MouseEvent.CLICK, SetBGMVolumeLevel); panelOption.sfxvol.removeEventListener(MouseEvent.CLICK, SetSFXVolumeLevel); }; } private function detectHit(_arg1, _arg2):MovieClip{ var _local3:*; var _local4:*; _local4 = null; if (_arg2 == "player"){ _local3 = 0; while (((!(_local4)) && ((_local3 < enemyArray.length)))) { if (_arg1.hitTestObject(enemyArray[_local3])){ _local4 = enemyArray[_local3]; }; _local3++; }; } else { _local3 = 0; while (((!(_local4)) && ((_local3 < unitArray.length)))) { if (_arg1.hitTestObject(unitArray[_local3])){ _local4 = unitArray[_local3]; }; _local3++; }; _local3 = 0; while (((!(_local4)) && ((_local3 < turretArray.length)))) { if (turretArray[_local3]){ if (_arg1.hitTestObject(turretArray[_local3])){ _local4 = turretArray[_local3]; }; }; _local3++; }; if (!_local4){ if (_arg1.hitTestObject(castle.d1)){ _local4 = castle; }; }; }; return (_local4); } public function setDistortTimer(_arg1=0){ if (_arg1 > 0){ if (_arg1 > distortingValue){ distortingValue = _arg1; }; }; if (distortingValue > 0){ distortingValue--; if (distortingValue < 0){ distortingValue = 0; }; sceneContainer.x = (0 + (distortingValue * Math.sin(((distortingValue * Math.PI) / maxDistort)))); }; } private function startListeners(){ stageRoot.root.addEventListener(Event.ENTER_FRAME, frameEnterHandler); stageRoot.root.addEventListener(KeyboardEvent.KEY_DOWN, keyPressHandler); stageRoot.root.addEventListener(KeyboardEvent.KEY_UP, keyReleaseHandler); scroller.upscroller.addEventListener(MouseEvent.MOUSE_OVER, setScrollingUp); scroller.upscroller.addEventListener(MouseEvent.MOUSE_OUT, resetScrollingUp); scroller.downscroller.addEventListener(MouseEvent.MOUSE_OVER, setScrollingDown); scroller.downscroller.addEventListener(MouseEvent.MOUSE_OUT, resetScrollingDown); levelPanel.btquitlevel.addEventListener(MouseEvent.CLICK, showConfirmPanel); levelPanel.btplaymore.addEventListener(MouseEvent.CLICK, playMoreGames); levelPanel.btoption.addEventListener(MouseEvent.CLICK, toggleGamePause); levelPanel.iconrider.addEventListener(MouseEvent.CLICK, startRiderCreator); levelPanel.iconcopter.addEventListener(MouseEvent.CLICK, startCopterCreator); levelPanel.iconeagle.addEventListener(MouseEvent.CLICK, startEagleCreator); levelPanel.iconpanzer.addEventListener(MouseEvent.CLICK, startPanzerCreator); levelPanel.icondragon.addEventListener(MouseEvent.CLICK, startDragonCreator); levelPanel.iconiceturret.addEventListener(MouseEvent.CLICK, startIceTurretCreator); levelPanel.iconfireturret.addEventListener(MouseEvent.CLICK, startFireTurretCreator); levelPanel.iconthunderturret.addEventListener(MouseEvent.CLICK, startThunderTurretCreator); levelPanel.iconupgraderange.addEventListener(MouseEvent.CLICK, startUpgradeRange); levelPanel.iconupgradehealth.addEventListener(MouseEvent.CLICK, startUpgradeHealth); levelPanel.iconupgradepower.addEventListener(MouseEvent.CLICK, startUpgradePower); levelPanel.iconupgradeattack.addEventListener(MouseEvent.CLICK, startUpgradeAttack); levelPanel.iconupgradedefense.addEventListener(MouseEvent.CLICK, startUpgradeDefense); levelPanel.iconupgrademana.addEventListener(MouseEvent.CLICK, startUpgradeMana); levelPanel.iconrepair.addEventListener(MouseEvent.CLICK, startRepairer); levelPanel.iconheal.addEventListener(MouseEvent.CLICK, startHealer); levelPanel.iconspecialattack.addEventListener(MouseEvent.CLICK, startSpecialAttack); levelPanel.iconrider.addEventListener(MouseEvent.MOUSE_OVER, startRiderNote); levelPanel.iconcopter.addEventListener(MouseEvent.MOUSE_OVER, startCopterNote); levelPanel.iconeagle.addEventListener(MouseEvent.MOUSE_OVER, startEagleNote); levelPanel.iconpanzer.addEventListener(MouseEvent.MOUSE_OVER, startPanzerNote); levelPanel.icondragon.addEventListener(MouseEvent.MOUSE_OVER, startDragonNote); levelPanel.iconiceturret.addEventListener(MouseEvent.MOUSE_OVER, startIceTurretNote); levelPanel.iconfireturret.addEventListener(MouseEvent.MOUSE_OVER, startFireTurretNote); levelPanel.iconthunderturret.addEventListener(MouseEvent.MOUSE_OVER, startThunderTurretNote); levelPanel.iconupgraderange.addEventListener(MouseEvent.MOUSE_OVER, startUpgradeRangeNote); levelPanel.iconupgradehealth.addEventListener(MouseEvent.MOUSE_OVER, startUpgradeHealthNote); levelPanel.iconupgradepower.addEventListener(MouseEvent.MOUSE_OVER, startUpgradePowerNote); levelPanel.iconupgradeattack.addEventListener(MouseEvent.MOUSE_OVER, startUpgradeAttackNote); levelPanel.iconupgradedefense.addEventListener(MouseEvent.MOUSE_OVER, startUpgradeDefenseNote); levelPanel.iconupgrademana.addEventListener(MouseEvent.MOUSE_OVER, startUpgradeManaNote); levelPanel.iconrepair.addEventListener(MouseEvent.MOUSE_OVER, startRepairerNote); levelPanel.iconheal.addEventListener(MouseEvent.MOUSE_OVER, startHealerNote); levelPanel.iconspecialattack.addEventListener(MouseEvent.MOUSE_OVER, startSpecialAttackNote); levelPanel.iconrider.addEventListener(MouseEvent.MOUSE_OUT, stopRiderNote); levelPanel.iconcopter.addEventListener(MouseEvent.MOUSE_OUT, stopCopterNote); levelPanel.iconeagle.addEventListener(MouseEvent.MOUSE_OUT, stopEagleNote); levelPanel.iconpanzer.addEventListener(MouseEvent.MOUSE_OUT, stopPanzerNote); levelPanel.icondragon.addEventListener(MouseEvent.MOUSE_OUT, stopDragonNote); levelPanel.iconiceturret.addEventListener(MouseEvent.MOUSE_OUT, stopIceTurretNote); levelPanel.iconfireturret.addEventListener(MouseEvent.MOUSE_OUT, stopFireTurretNote); levelPanel.iconthunderturret.addEventListener(MouseEvent.MOUSE_OUT, stopThunderTurretNote); levelPanel.iconupgraderange.addEventListener(MouseEvent.MOUSE_OUT, stopUpgradeRangeNote); levelPanel.iconupgradehealth.addEventListener(MouseEvent.MOUSE_OUT, stopUpgradeHealthNote); levelPanel.iconupgradepower.addEventListener(MouseEvent.MOUSE_OUT, stopUpgradePowerNote); levelPanel.iconupgradeattack.addEventListener(MouseEvent.MOUSE_OUT, stopUpgradeAttackNote); levelPanel.iconupgradedefense.addEventListener(MouseEvent.MOUSE_OUT, stopUpgradeDefenseNote); levelPanel.iconupgrademana.addEventListener(MouseEvent.MOUSE_OUT, stopUpgradeManaNote); levelPanel.iconrepair.addEventListener(MouseEvent.MOUSE_OUT, stopRepairerNote); levelPanel.iconheal.addEventListener(MouseEvent.MOUSE_OUT, stopHealerNote); levelPanel.iconspecialattack.addEventListener(MouseEvent.MOUSE_OUT, stopSpecialAttackNote); } private function startPanzerNote(_arg1=null){ showNote(4); } } }//package
Section 76
//mc_bigbat (mc_bigbat) package { public dynamic class mc_bigbat extends BaseAIClip { public function mc_bigbat(){ addFrameScript(15, frame16, 16, frame17); } function frame17(){ stop(); } function frame16(){ gotoAndPlay(1); } } }//package
Section 77
//mc_blackknight (mc_blackknight) package { public dynamic class mc_blackknight extends BaseAIClip { public function mc_blackknight(){ addFrameScript(15, frame16, 31, frame32, 32, frame33); } function frame16(){ gotoAndPlay(1); } function frame33(){ stop(); } function frame32(){ gotoAndPlay(1); } } }//package
Section 78
//mc_bluesplashfx (mc_bluesplashfx) package { import flash.display.*; public dynamic class mc_bluesplashfx extends MovieClip { public function mc_bluesplashfx(){ addFrameScript(9, frame10); } function frame10(){ gotoAndStop(1); } } }//package
Section 79
//mc_cannonblow1 (mc_cannonblow1) package { import flash.display.*; public dynamic class mc_cannonblow1 extends MovieClip { } }//package
Section 80
//mc_cannonblow2 (mc_cannonblow2) package { import flash.display.*; public dynamic class mc_cannonblow2 extends MovieClip { } }//package
Section 81
//mc_cannonblow3 (mc_cannonblow3) package { import flash.display.*; public dynamic class mc_cannonblow3 extends MovieClip { } }//package
Section 82
//mc_cannonbullet (mc_cannonbullet) package { public dynamic class mc_cannonbullet extends BaseBulletClip { public function mc_cannonbullet(){ addFrameScript(60, frame61); } function frame61(){ stop(); } } }//package
Section 83
//mc_castle (mc_castle) package { public dynamic class mc_castle extends BaseAIClip { public function mc_castle(){ addFrameScript(0, frame1, 1, frame2, 2, frame3, 3, frame4, 4, frame5, 5, frame6); } function frame3(){ stop(); } function frame1(){ stop(); } function frame5(){ stop(); } function frame6(){ stop(); } function frame4(){ stop(); } function frame2(){ stop(); } } }//package
Section 84
//mc_copter (mc_copter) package { public dynamic class mc_copter extends BaseAIClip { public function mc_copter(){ addFrameScript(7, frame8, 15, frame16, 16, frame17); } function frame8(){ gotoAndPlay(1); } function frame17(){ stop(); } function frame16(){ gotoAndPlay(9); } } }//package
Section 85
//mc_cover (mc_cover) package { import flash.display.*; public dynamic class mc_cover extends MovieClip { } }//package
Section 86
//mc_creator (mc_creator) package { import flash.display.*; public dynamic class mc_creator extends MovieClip { } }//package
Section 87
//mc_dragon (mc_dragon) package { public dynamic class mc_dragon extends BaseAIClip { public function mc_dragon(){ addFrameScript(15, frame16, 31, frame32, 32, frame33); } function frame16(){ gotoAndPlay(1); } function frame33(){ stop(); } function frame32(){ gotoAndPlay(17); } } }//package
Section 88
//mc_eagle (mc_eagle) package { public dynamic class mc_eagle extends BaseAIClip { public function mc_eagle(){ addFrameScript(15, frame16, 31, frame32, 32, frame33); } function frame16(){ gotoAndPlay(1); } function frame33(){ stop(); } function frame32(){ gotoAndPlay(17); } } }//package
Section 89
//mc_electricsplashfx (mc_electricsplashfx) package { import flash.display.*; public dynamic class mc_electricsplashfx extends MovieClip { } }//package
Section 90
//mc_evilcopter (mc_evilcopter) package { public dynamic class mc_evilcopter extends BaseAIClip { public function mc_evilcopter(){ addFrameScript(7, frame8, 15, frame16, 16, frame17); } function frame8(){ gotoAndPlay(1); } function frame17(){ stop(); } function frame16(){ gotoAndPlay(9); } } }//package
Section 91
//mc_evildragon (mc_evildragon) package { public dynamic class mc_evildragon extends BaseAIClip { public function mc_evildragon(){ addFrameScript(15, frame16, 31, frame32, 32, frame33); } function frame16(){ gotoAndPlay(1); } function frame33(){ stop(); } function frame32(){ gotoAndPlay(17); } } }//package
Section 92
//mc_evilpanzer (mc_evilpanzer) package { public dynamic class mc_evilpanzer extends BaseAIClip { public function mc_evilpanzer(){ addFrameScript(7, frame8, 15, frame16, 16, frame17); } function frame8(){ gotoAndPlay(1); } function frame17(){ stop(); } function frame16(){ gotoAndPlay(9); } } }//package
Section 93
//mc_evilultimate (mc_evilultimate) package { public dynamic class mc_evilultimate extends BaseAIClip { public function mc_evilultimate(){ addFrameScript(15, frame16, 31, frame32, 32, frame33); } function frame16(){ gotoAndPlay(1); } function frame33(){ stop(); } function frame32(){ gotoAndPlay(17); } } }//package
Section 94
//mc_firebullet (mc_firebullet) package { public dynamic class mc_firebullet extends BaseBulletClip { public function mc_firebullet(){ addFrameScript(60, frame61); } function frame61(){ stop(); } } }//package
Section 95
//mc_fireturret (mc_fireturret) package { public dynamic class mc_fireturret extends BaseAIClip { public function mc_fireturret(){ addFrameScript(0, frame1, 1, frame2); } function frame1(){ stop(); } function frame2(){ stop(); } } }//package
Section 96
//mc_frozenbullet (mc_frozenbullet) package { public dynamic class mc_frozenbullet extends BaseBulletClip { public function mc_frozenbullet(){ addFrameScript(60, frame61); } function frame61(){ stop(); } } }//package
Section 97
//mc_healthbar (mc_healthbar) package { import flash.display.*; public dynamic class mc_healthbar extends MovieClip { } }//package
Section 98
//mc_icebullet (mc_icebullet) package { public dynamic class mc_icebullet extends BaseBulletClip { public function mc_icebullet(){ addFrameScript(60, frame61); } function frame61(){ stop(); } } }//package
Section 99
//mc_iceturret (mc_iceturret) package { public dynamic class mc_iceturret extends BaseAIClip { public function mc_iceturret(){ addFrameScript(0, frame1, 1, frame2); } function frame1(){ stop(); } function frame2(){ stop(); } } }//package
Section 100
//mc_levelnote (mc_levelnote) package { public dynamic class mc_levelnote extends PanelMover { } }//package
Section 101
//mc_levelpanel (mc_levelpanel) package { import flash.display.*; import flash.text.*; public dynamic class mc_levelpanel extends MovieClip { public var rightnote2:MovieClip; public var rightnote:MovieClip; public var iconeagle:MovieClip; public var queue4:MovieClip; public var queue5:MovieClip; public var queue6:MovieClip; public var queue2:MovieClip; public var iconupgradedefense:MovieClip; public var btoption:SimpleButton; public var rightbalancelevel:MovieClip; public var iconupgradepower:MovieClip; public var queue1:MovieClip; public var iconspecialattack:MovieClip; public var queue3:MovieClip; public var iconrepair:MovieClip; public var btquitlevel:SimpleButton; public var iconupgrademana:MovieClip; public var gameshadow:MovieClip; public var iconupgraderange:MovieClip; public var iconupgradehealth:MovieClip; public var iconrider:MovieClip; public var healthlevel:MovieClip; public var manapoint:TextField; public var iconupgradeattack:MovieClip; public var leftbalancelevel:MovieClip; public var progresslevel:MovieClip; public var iconpanzer:MovieClip; public var icondragon:MovieClip; public var iconthunderturret:MovieClip; public var iconcopter:MovieClip; public var btplaymore:SimpleButton; public var iconheal:MovieClip; public var iconfireturret:MovieClip; public var iconiceturret:MovieClip; public var manalevel:MovieClip; public var note:TextField; } }//package
Section 102
//mc_panzer (mc_panzer) package { public dynamic class mc_panzer extends BaseAIClip { public function mc_panzer(){ addFrameScript(7, frame8, 15, frame16, 16, frame17); } function frame8(){ gotoAndPlay(1); } function frame17(){ stop(); } function frame16(){ gotoAndPlay(9); } } }//package
Section 103
//mc_progress (mc_progress) package { import flash.display.*; public dynamic class mc_progress extends MovieClip { public function mc_progress(){ addFrameScript(100, frame101); } function frame101(){ stop(); } } }//package
Section 104
//mc_redsplashfx (mc_redsplashfx) package { import flash.display.*; public dynamic class mc_redsplashfx extends MovieClip { public function mc_redsplashfx(){ addFrameScript(9, frame10); } function frame10(){ gotoAndStop(1); } } }//package
Section 105
//mc_rider (mc_rider) package { public dynamic class mc_rider extends BaseAIClip { public function mc_rider(){ addFrameScript(7, frame8, 15, frame16, 16, frame17); } function frame8(){ gotoAndPlay(1); } function frame17(){ stop(); } function frame16(){ gotoAndPlay(9); } } }//package
Section 106
//mc_scroller (mc_scroller) package { import flash.display.*; public dynamic class mc_scroller extends MovieClip { public var downscroller:SimpleButton; public var btcreateunitright:SimpleButton; public var btcreateunitleft:SimpleButton; public var upscroller:SimpleButton; } }//package
Section 107
//mc_selected (mc_selected) package { import flash.display.*; public dynamic class mc_selected extends MovieClip { } }//package
Section 108
//mc_smallbat (mc_smallbat) package { public dynamic class mc_smallbat extends BaseAIClip { public function mc_smallbat(){ addFrameScript(15, frame16, 16, frame17); } function frame17(){ stop(); } function frame16(){ gotoAndPlay(1); } } }//package
Section 109
//mc_specialfx (mc_specialfx) package { import flash.display.*; public dynamic class mc_specialfx extends MovieClip { public function mc_specialfx(){ addFrameScript(25, frame26); } function frame26(){ stop(); stop(); } } }//package
Section 110
//mc_splashfx (mc_splashfx) package { import flash.display.*; public dynamic class mc_splashfx extends MovieClip { public function mc_splashfx(){ addFrameScript(0, frame1, 15, frame16); } function frame16(){ gotoAndStop(1); } function frame1(){ stop(); } } }//package
Section 111
//mc_thunder (mc_thunder) package { import flash.display.*; public dynamic class mc_thunder extends MovieClip { } }//package
Section 112
//mc_thunderturret (mc_thunderturret) package { public dynamic class mc_thunderturret extends BaseAIClip { public function mc_thunderturret(){ addFrameScript(0, frame1, 1, frame2); } function frame1(){ stop(); } function frame2(){ stop(); } } }//package
Section 113
//mc_turretcreator (mc_turretcreator) package { import flash.display.*; public dynamic class mc_turretcreator extends MovieClip { } }//package
Section 114
//mc_turretlayer (mc_turretlayer) package { import flash.display.*; public dynamic class mc_turretlayer extends MovieClip { public var btcreateturret1:SimpleButton; public var btcreateturret3:SimpleButton; public var btcreateturret2:SimpleButton; public var btcreateturret4:SimpleButton; } }//package
Section 115
//mc_tutorial (mc_tutorial) package { import flash.display.*; public dynamic class mc_tutorial extends MovieClip { public function mc_tutorial(){ addFrameScript(0, frame1, 481, frame482); } function frame1(){ stop(); } function frame482(){ stop(); } } }//package
Section 116
//MochiBot (MochiBot) package { import flash.display.*; import flash.net.*; import flash.system.*; public dynamic class MochiBot extends Sprite { public static function track(_arg1:Sprite, _arg2:String):MochiBot{ var _local3:MochiBot; var _local4:String; var _local5:URLVariables; var _local6:String; var _local7:URLRequest; var _local8:Loader; if (Security.sandboxType == "localWithFile"){ return (null); }; _local3 = new (MochiBot); _arg1.addChild(_local3); Security.allowDomain("*"); Security.allowInsecureDomain("*"); _local4 = "http://core.mochibot.com/my/core.swf"; _local5 = new URLVariables(); _local5["sb"] = Security.sandboxType; _local5["v"] = Capabilities.version; _local5["swfid"] = _arg2; _local5["mv"] = "8"; _local5["fv"] = "9"; _local6 = _local3.root.loaderInfo.loaderURL; if (_local6.indexOf("http") == 0){ _local5["url"] = _local6; } else { _local5["url"] = "local"; }; _local7 = new URLRequest(_local4); _local7.contentType = "application/x-www-form-urlencoded"; _local7.method = URLRequestMethod.POST; _local7.data = _local5; _local8 = new Loader(); _local3.addChild(_local8); _local8.load(_local7); return (_local3); } } }//package
Section 117
//panelconfirm (panelconfirm) package { public dynamic class panelconfirm extends PanelMover { } }//package
Section 118
//PanelMover (PanelMover) package { import flash.events.*; import flash.display.*; import fl.controls.*; import flash.text.*; public class PanelMover extends MovieClip { private var presentX:int; public var bgmvol:Slider; private var presentY:int; private var distanceX:int; private var distanceY:int; private var showY:int; private var factorX:int;// = 0 public var sfxvol:Slider; public var panelShow:Boolean;// = false public var btcancel:btno; private var hideY:int; private var hideX:int; public var mana:TextField; private var moving:Boolean;// = false public var btyes:SimpleButton; public var btresumegame:MovieClip; private var showX:int; public var btquitlevel:MovieClip; private var substrX:int;// = 0 private var substrY:int;// = 0 public var btplaymore:MovieClip; private var factorY:int;// = 0 public var quality:Slider; public function PanelMover(){ factorX = 0; factorY = 0; substrX = 0; substrY = 0; moving = false; panelShow = false; super(); } public function Show(){ if (!panelShow){ panelShow = true; if (!moving){ this.addEventListener(Event.ENTER_FRAME, FrameEnterHandler); moving = true; }; }; } public function Init(_arg1=0, _arg2=0, _arg3=0, _arg4=0){ hideX = _arg3; hideY = _arg4; showX = _arg1; showY = _arg2; factorX = ((showX)>hideX) ? 1 : -1; factorY = ((showY)>hideY) ? 1 : -1; substrX = (Math.abs((_arg1 - _arg3)) / 12); substrY = (Math.abs((_arg2 - _arg4)) / 12); panelShow = false; presentX = hideX; presentY = hideY; this.x = hideX; this.y = hideY; } public function Hide(){ if (panelShow){ panelShow = false; if (!moving){ this.addEventListener(Event.ENTER_FRAME, FrameEnterHandler); moving = true; }; }; } private function FrameEnterHandler(_arg1:Event){ if (panelShow){ if (presentX != showX){ distanceX = Math.abs((presentX - showX)); if (distanceX <= 5){ presentX = showX; } else { presentX = (presentX + ((distanceX * 0.5) * factorX)); }; this.x = presentX; }; if (presentY != showY){ distanceY = Math.abs((presentY - showY)); if (distanceY <= 5){ presentY = showY; } else { presentY = (presentY + ((distanceY * 0.5) * factorY)); }; this.y = presentY; }; if ((((presentX == showX)) && ((presentY == showY)))){ this.removeEventListener(Event.ENTER_FRAME, FrameEnterHandler); moving = false; }; } else { if (presentX != hideX){ distanceX = Math.abs((presentX - hideX)); if (distanceX <= 5){ presentX = hideX; } else { presentX = (presentX - (substrX * factorX)); }; this.x = presentX; }; if (presentY != hideY){ distanceY = Math.abs((presentY - hideY)); if (distanceY <= 5){ presentY = hideY; } else { presentY = (presentY - (substrY * factorY)); }; this.y = presentY; }; if ((((presentX == hideX)) && ((presentY == hideY)))){ this.removeEventListener(Event.ENTER_FRAME, FrameEnterHandler); moving = false; }; }; } public function Destroy(){ } } }//package
Section 119
//paneloption (paneloption) package { public dynamic class paneloption extends PanelMover { public function paneloption(){ __setProp_quality_paneloption_Layer4_1(); __setProp_bgmvol_paneloption_Layer4_1(); __setProp_sfxvol_paneloption_Layer4_1(); } function __setProp_sfxvol_paneloption_Layer4_1(){ try { sfxvol["componentInspectorSetting"] = true; } catch(e:Error) { }; sfxvol.direction = "horizontal"; sfxvol.enabled = true; sfxvol.liveDragging = false; sfxvol.maximum = 10; sfxvol.minimum = 0; sfxvol.snapInterval = 1; sfxvol.tickInterval = 1; sfxvol.value = 5; sfxvol.visible = true; try { sfxvol["componentInspectorSetting"] = false; } catch(e:Error) { }; } function __setProp_quality_paneloption_Layer4_1(){ try { quality["componentInspectorSetting"] = true; } catch(e:Error) { }; quality.direction = "horizontal"; quality.enabled = true; quality.liveDragging = false; quality.maximum = 3; quality.minimum = 1; quality.snapInterval = 1; quality.tickInterval = 1; quality.value = 2; quality.visible = true; try { quality["componentInspectorSetting"] = false; } catch(e:Error) { }; } function __setProp_bgmvol_paneloption_Layer4_1(){ try { bgmvol["componentInspectorSetting"] = true; } catch(e:Error) { }; bgmvol.direction = "horizontal"; bgmvol.enabled = true; bgmvol.liveDragging = false; bgmvol.maximum = 10; bgmvol.minimum = 0; bgmvol.snapInterval = 1; bgmvol.tickInterval = 1; bgmvol.value = 5; bgmvol.visible = true; try { bgmvol["componentInspectorSetting"] = false; } catch(e:Error) { }; } } }//package
Section 120
//sfxambient (sfxambient) package { public dynamic class sfxambient extends BaseSound { } }//package
Section 121
//sfxcannonhit1 (sfxcannonhit1) package { public dynamic class sfxcannonhit1 extends BaseSound { } }//package
Section 122
//sfxcannonhit2 (sfxcannonhit2) package { public dynamic class sfxcannonhit2 extends BaseSound { } }//package
Section 123
//sfxcannonhit3 (sfxcannonhit3) package { public dynamic class sfxcannonhit3 extends BaseSound { } }//package
Section 124
//sfxcannonshoot (sfxcannonshoot) package { public dynamic class sfxcannonshoot extends BaseSound { } }//package
Section 125
//sfxplasmahit (sfxplasmahit) package { public dynamic class sfxplasmahit extends BaseSound { } }//package
Section 126
//sfxplasmashoot (sfxplasmashoot) package { public dynamic class sfxplasmashoot extends BaseSound { } }//package
Section 127
//sfxspecialattack (sfxspecialattack) package { public dynamic class sfxspecialattack extends BaseSound { } }//package
Section 128
//sfxtest (sfxtest) package { public dynamic class sfxtest extends BaseSound { } }//package
Section 129
//shadow (shadow) package { import flash.display.*; public dynamic class shadow extends MovieClip { } }//package
Section 130
//SiteLock (SiteLock) package { public class SiteLock { private var stageRoot; private var allowedDomain:Array; public function SiteLock(_arg1){ allowedDomain = new Array(); super(); stageRoot = _arg1; addSite("www.artlogic.com"); addSite("artlogic.com"); } public function checkKongregate():Boolean{ var _local1:*; var _local2:*; var _local3:*; var _local4:*; var _local5:*; _local1 = stageRoot.loaderInfo.loaderURL.split("://"); _local2 = _local1[1].split("/"); _local3 = _local2[0]; _local4 = false; _local4 = ((_local4) || ((_local3 == "www.kongregate.com"))); _local4 = ((_local4) || ((_local3 == "chat.kongregate.com"))); _local4 = ((_local4) || ((_local3 == "a.kongregate.com"))); _local4 = ((_local4) || ((_local3 == "kongregate.com"))); return (_local4); } public function addSite(_arg1){ allowedDomain.push(_arg1); } public function checkArmorgames():Boolean{ var _local1:*; var _local2:*; var _local3:*; var _local4:*; var _local5:*; _local1 = stageRoot.loaderInfo.loaderURL.split("://"); _local2 = _local1[1].split("/"); _local3 = _local2[0]; _local4 = false; _local4 = ((_local4) || ((_local3 == "www.armorgames.com"))); _local4 = ((_local4) || ((_local3 == "armorgames.com"))); return (_local4); } public function checkLocalhost():Boolean{ var _local1:*; var _local2:*; var _local3:*; var _local4:*; var _local5:*; _local1 = stageRoot.loaderInfo.loaderURL.split("://"); _local2 = _local1[1].split("/"); _local3 = _local2[0]; _local4 = false; _local4 = ((_local4) || ((_local3 == "localhost"))); return (_local4); } public function checkLocked():Boolean{ var _local1:*; var _local2:*; var _local3:*; var _local4:*; var _local5:*; _local1 = stageRoot.loaderInfo.loaderURL.split("://"); _local2 = _local1[1].split("/"); _local3 = _local2[0]; _local4 = false; _local5 = 0; while (_local5 < allowedDomain.length) { _local4 = ((_local4) || ((_local3 == allowedDomain[_local5]))); _local5++; }; return (_local4); } } }//package
Section 131
//SliderThumb_disabledSkin (SliderThumb_disabledSkin) package { import flash.display.*; public dynamic class SliderThumb_disabledSkin extends MovieClip { } }//package
Section 132
//SliderThumb_downSkin (SliderThumb_downSkin) package { import flash.display.*; public dynamic class SliderThumb_downSkin extends MovieClip { } }//package
Section 133
//SliderThumb_overSkin (SliderThumb_overSkin) package { import flash.display.*; public dynamic class SliderThumb_overSkin extends MovieClip { } }//package
Section 134
//SliderThumb_upSkin (SliderThumb_upSkin) package { import flash.display.*; public dynamic class SliderThumb_upSkin extends MovieClip { } }//package
Section 135
//SliderTick_skin (SliderTick_skin) package { import flash.display.*; public dynamic class SliderTick_skin extends MovieClip { } }//package
Section 136
//SliderTrack_disabledSkin (SliderTrack_disabledSkin) package { import flash.display.*; public dynamic class SliderTrack_disabledSkin extends MovieClip { } }//package
Section 137
//SliderTrack_skin (SliderTrack_skin) package { import flash.display.*; public dynamic class SliderTrack_skin extends MovieClip { } }//package
Section 138
//SoundManager (SoundManager) package { public class SoundManager { private var sfxCannonHit1; public var bgmVolume:Number;// = 0.7 private var sfxCannonHit2; private var sndFxCannonShoot;// = null private var sfxCannonHit3; private var bgmIntro; private var sndFxPlasmaHit;// = null private var sndFx;// = null private var sndBgm;// = null private var myParent; private var sndFxSpecial;// = null private var sfxTest; private var sfxPlasmaShoot; private var bgmCover; private var bgmStage1; private var sfxSpecialAttack; private var sfxCannonShoot; private var sndFxPlasmaShoot;// = null private var sfxPlasmaHit; private var sndFxCannonHit;// = null private var sndFxAmbient; public var sfxVolume:Number;// = 0.5 public function SoundManager(){ bgmVolume = 0.7; sfxVolume = 0.5; sfxCannonShoot = new sfxcannonshoot(); sfxCannonHit1 = new sfxcannonhit1(); sfxCannonHit2 = new sfxcannonhit2(); sfxCannonHit3 = new sfxcannonhit3(); sfxPlasmaShoot = new sfxplasmashoot(); sfxPlasmaHit = new sfxplasmahit(); sfxSpecialAttack = new sfxspecialattack(); sfxTest = new sfxtest(); bgmIntro = new bgmintro(); bgmCover = new bgmcover(); bgmStage1 = new bgmstage(); sndBgm = null; sndFxAmbient = new sfxambient(); sndFxSpecial = null; sndFxPlasmaShoot = null; sndFxPlasmaHit = null; sndFxCannonShoot = null; sndFxCannonHit = null; sndFx = null; super(); sndFxAmbient.playSoundLoop(); sndFxAmbient.volume = (1 * sfxVolume); } public function stopSFX(){ if (sndFxPlasmaShoot){ sndFxPlasmaShoot.stopSound(); }; if (sndFxPlasmaHit){ sndFxPlasmaHit.stopSound(); }; if (sndFxCannonShoot){ sndFxCannonShoot.stopSound(); }; if (sndFxCannonHit){ sndFxCannonHit.stopSound(); }; if (sndFx){ sndFx.stopSound(); }; } public function playSFX(_arg1:String=""){ var _local2:*; _local2 = Math.random(); switch (_arg1){ case "specialattack": if (sndFxSpecial != sfxSpecialAttack){ if (sndFxSpecial){ sndFxSpecial.stopSound(); }; sndFxSpecial = sfxSpecialAttack; sndFxSpecial.playSound(); sndFxSpecial.setVolume((0.8 * sfxVolume)); } else { if (!sndFxSpecial.sndPlaying){ sndFxSpecial.playSound(); sndFxSpecial.setVolume((0.8 * sfxVolume)); }; }; break; case "plasmahit": if (sndFxPlasmaHit != sfxPlasmaHit){ if (sndFxPlasmaHit){ sndFxPlasmaHit.stopSound(); }; sndFxPlasmaHit = sfxPlasmaHit; sndFxPlasmaHit.playSound(); sfxPlasmaHit.setVolume((0.6 * sfxVolume)); } else { if (!sndFxPlasmaHit.sndPlaying){ sndFxPlasmaHit.playSound(); sfxPlasmaHit.setVolume((0.6 * sfxVolume)); }; }; break; case "plasmashoot": if (sndFxPlasmaShoot != sfxPlasmaShoot){ if (sndFxPlasmaShoot){ sndFxPlasmaShoot.stopSound(); }; sndFxPlasmaShoot = sfxPlasmaShoot; sndFxPlasmaShoot.playSound(); sfxPlasmaShoot.setVolume((0.6 * sfxVolume)); } else { if (!sndFxPlasmaShoot.sndPlaying){ sndFxPlasmaShoot.playSound(); sfxPlasmaShoot.setVolume((0.6 * sfxVolume)); }; }; break; case "cannonhit": if (((((!((sndFx == sfxCannonHit1))) && (!((sndFx == sfxCannonHit2))))) && (!((sndFx == sfxCannonHit3))))){ if (sndFxCannonHit){ sndFxCannonHit.stopSound(); }; if (_local2 < 0.4){ sndFxCannonHit = sfxCannonHit1; } else { if (_local2 < 0.7){ sndFxCannonHit = sfxCannonHit2; } else { sndFxCannonHit = sfxCannonHit3; }; }; sndFxCannonHit.playSound(); if (sndFxCannonHit == sfxCannonHit1){ sfxCannonHit1.setVolume((0.6 * sfxVolume)); } else { if (sndFxCannonHit == sfxCannonHit2){ sfxCannonHit2.setVolume((0.6 * sfxVolume)); } else { if (sndFxCannonHit == sfxCannonHit3){ sfxCannonHit3.setVolume((0.6 * sfxVolume)); }; }; }; } else { if (!sndFxCannonHit.sndPlaying){ sndFxCannonHit.playSound(); if (sndFxCannonHit == sfxCannonHit1){ sfxCannonHit1.setVolume((0.6 * sfxVolume)); } else { if (sndFxCannonHit == sfxCannonHit2){ sfxCannonHit2.setVolume((0.6 * sfxVolume)); } else { if (sndFxCannonHit == sfxCannonHit3){ sfxCannonHit3.setVolume((0.6 * sfxVolume)); }; }; }; }; }; break; case "cannonshoot": if (sndFxCannonShoot != sfxCannonShoot){ if (sndFxCannonShoot){ sndFxCannonShoot.stopSound(); }; sndFxCannonShoot = sfxCannonShoot; sndFxCannonShoot.playSound(); sfxCannonShoot.setVolume((0.6 * sfxVolume)); } else { if (!sndFxCannonShoot.sndPlaying){ sndFxCannonShoot.playSound(); sfxCannonShoot.setVolume((0.6 * sfxVolume)); }; }; break; case "test": default: sfxTest.playSound(); sfxTest.setVolume((1 * sfxVolume)); break; }; } public function adjustBGM(_arg1=0.7){ var _local2:*; bgmVolume = _arg1; playBGM("test"); playBGM(); } public function stopBGM(){ if (sndBgm){ sndBgm.stopSound(); sndBgm = null; }; } public function playBGM(_arg1:String=""){ switch (_arg1){ case "stage": if (sndBgm != bgmStage1){ stopBGM(); sndBgm = bgmStage1; sndBgm.playSoundLoop(); sndBgm.setVolume((1 * bgmVolume)); } else { sndBgm.setVolume((1 * bgmVolume)); }; break; case "intro": if (sndBgm != bgmIntro){ stopBGM(); sndBgm = bgmIntro; sndBgm.playSoundLoop(); sndBgm.setVolume((1 * bgmVolume)); } else { sndBgm.setVolume((1 * bgmVolume)); }; break; case "cover": if (sndBgm != bgmCover){ stopBGM(); sndBgm = bgmCover; sndBgm.playSoundLoop(); sndBgm.setVolume((0.8 * bgmVolume)); } else { sndBgm.setVolume((0.8 * bgmVolume)); }; break; case "test": sfxTest.playSound(); sfxTest.setVolume((1 * bgmVolume)); break; default: if (sndBgm){ sndBgm.setVolume((1 * bgmVolume)); }; }; } public function adjustSFX(_arg1=0.5){ sfxVolume = _arg1; playSFX("test"); sndFxAmbient.volume = (1 * sfxVolume); } } }//package
Section 139
//TimeParser (TimeParser) package { import flash.utils.*; public class TimeParser { public var stime:String; public var hour:uint; public var smsecond:String; public var ssecond:String; public var time:uint; public var msecond:uint; public var second:uint; public var minute:uint; public var shour:String; public var sminute:String; public function TimeParser(_arg1=null){ if (_arg1){ time = _arg1; } else { time = getTimer(); }; Parse(time); } public function Parse(_arg1:uint, _arg2:String=":"):String{ time = _arg1; hour = Math.floor((time / 3600000)); minute = (Math.floor((time / 60000)) % 60); second = (Math.floor((time / 1000)) % 60); msecond = (Math.floor((time / 10)) % 100); shour = String(hour); if (minute < 10){ sminute = ("0" + String(minute)); } else { sminute = String(minute); }; if (second < 10){ ssecond = ("0" + String(second)); } else { ssecond = String(second); }; if (msecond < 10){ smsecond = ("0" + String(msecond)); } else { smsecond = String(msecond); }; if (hour > 0){ stime = ((((shour + _arg2) + sminute) + _arg2) + ssecond); } else { stime = ((sminute + _arg2) + ssecond); }; return (stime); } } }//package

Library Items

Symbol 1 BitmapUsed by:2
Symbol 2 GraphicUses:1Used by:9
Symbol 3 BitmapUsed by:4
Symbol 4 GraphicUses:3Used by:5
Symbol 5 ButtonUses:4Used by:9
Symbol 6 BitmapUsed by:7
Symbol 7 GraphicUses:6Used by:8
Symbol 8 Button {btno}Uses:7Used by:9
Symbol 9 MovieClip {panelconfirm}Uses:2 5 8
Symbol 10 BitmapUsed by:11
Symbol 11 GraphicUses:10Used by:20
Symbol 12 BitmapUsed by:13
Symbol 13 GraphicUses:12Used by:20
Symbol 14 BitmapUsed by:15
Symbol 15 GraphicUses:14Used by:20
Symbol 16 BitmapUsed by:17
Symbol 17 GraphicUses:16Used by:20
Symbol 18 BitmapUsed by:19
Symbol 19 GraphicUses:18Used by:20
Symbol 20 MovieClip {mc_creator}Uses:11 13 15 17 19
Symbol 21 BitmapUsed by:22
Symbol 22 GraphicUses:21Used by:27
Symbol 23 BitmapUsed by:24
Symbol 24 GraphicUses:23Used by:27
Symbol 25 BitmapUsed by:26
Symbol 26 GraphicUses:25Used by:27
Symbol 27 MovieClip {mc_turretcreator}Uses:22 24 26
Symbol 28 GraphicUsed by:29
Symbol 29 MovieClip {shadow}Uses:28
Symbol 30 ShapeTweeningUsed by:33
Symbol 31 ShapeTweeningUsed by:33
Symbol 32 GraphicUsed by:33
Symbol 33 MovieClip {mc_selected}Uses:30 31 32
Symbol 34 BitmapUsed by:35
Symbol 35 GraphicUses:34Used by:55
Symbol 36 FontUsed by:37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 530 531 542 555
Symbol 37 TextUses:36Used by:55
Symbol 38 EditableTextUses:36Used by:55
Symbol 39 TextUses:36Used by:55
Symbol 40 TextUses:36Used by:55
Symbol 41 TextUses:36Used by:55
Symbol 42 TextUses:36Used by:55
Symbol 43 TextUses:36Used by:55
Symbol 44 TextUses:36Used by:55
Symbol 45 TextUses:36Used by:55
Symbol 46 TextUses:36Used by:55
Symbol 47 TextUses:36Used by:55
Symbol 48 TextUses:36Used by:55
Symbol 49 TextUses:36Used by:55
Symbol 50 TextUses:36Used by:55
Symbol 51 TextUses:36Used by:55
Symbol 52 TextUses:36Used by:55
Symbol 53 TextUses:36Used by:55
Symbol 54 TextUses:36Used by:55
Symbol 55 MovieClip {mc_levelnote}Uses:35 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54
Symbol 56 ShapeTweeningUsed by:59
Symbol 57 ShapeTweeningUsed by:59
Symbol 58 GraphicUsed by:59
Symbol 59 MovieClip {mc_splashfx}Uses:56 57 58
Symbol 60 ShapeTweeningUsed by:69
Symbol 61 ShapeTweeningUsed by:69
Symbol 62 ShapeTweeningUsed by:69
Symbol 63 ShapeTweeningUsed by:69
Symbol 64 ShapeTweeningUsed by:69
Symbol 65 GraphicUsed by:69
Symbol 66 GraphicUsed by:69
Symbol 67 ShapeTweeningUsed by:69
Symbol 68 GraphicUsed by:69
Symbol 69 MovieClip {mc_specialfx}Uses:60 61 62 63 64 65 66 67 68
Symbol 70 GraphicUsed by:74
Symbol 71 GraphicUsed by:74
Symbol 72 GraphicUsed by:74
Symbol 73 GraphicUsed by:74
Symbol 74 ButtonUses:70 71 72 73Used by:75 572
Symbol 75 MovieClip {mc_turretlayer}Uses:74
Symbol 76 GraphicUsed by:77
Symbol 77 MovieClipUses:76Used by:95
Symbol 78 MovieClip {fl.core.ComponentShim}Used by:95
Symbol 79 GraphicUsed by:80
Symbol 80 MovieClip {SliderThumb_upSkin}Uses:79Used by:95
Symbol 81 GraphicUsed by:82
Symbol 82 MovieClip {SliderThumb_overSkin}Uses:81Used by:95
Symbol 83 GraphicUsed by:84
Symbol 84 MovieClip {SliderThumb_downSkin}Uses:83Used by:95
Symbol 85 GraphicUsed by:86
Symbol 86 MovieClip {SliderThumb_disabledSkin}Uses:85Used by:95
Symbol 87 GraphicUsed by:88
Symbol 88 MovieClip {SliderTrack_skin}Uses:87Used by:95
Symbol 89 GraphicUsed by:90
Symbol 90 MovieClip {SliderTick_skin}Uses:89Used by:95
Symbol 91 GraphicUsed by:92
Symbol 92 MovieClip {SliderTrack_disabledSkin}Uses:91Used by:95
Symbol 93 GraphicUsed by:94
Symbol 94 MovieClip {focusRectSkin}Uses:93Used by:95
Symbol 95 MovieClip {fl.controls.Slider}Uses:77 78 80 82 84 86 88 90 92 94Used by:598
Symbol 96 MovieClip {com.kongregate.as3.client.KongregateAPI}
Symbol 97 GraphicUsed by:Timeline
Symbol 98 BitmapUsed by:99
Symbol 99 GraphicUses:98Used by:100
Symbol 100 ButtonUses:99Used by:Timeline
Symbol 101 GraphicUsed by:102
Symbol 102 MovieClipUses:101Used by:Timeline
Symbol 103 GraphicUsed by:133
Symbol 104 BitmapUsed by:105
Symbol 105 GraphicUses:104Used by:106
Symbol 106 MovieClipUses:105Used by:133
Symbol 107 FontUsed by:108 109 110 111 112 124
Symbol 108 TextUses:107Used by:129
Symbol 109 TextUses:107Used by:129
Symbol 110 TextUses:107Used by:129
Symbol 111 TextUses:107Used by:129
Symbol 112 TextUses:107Used by:129
Symbol 113 GraphicUsed by:123
Symbol 114 GraphicUsed by:123
Symbol 115 GraphicUsed by:123
Symbol 116 GraphicUsed by:123
Symbol 117 GraphicUsed by:123
Symbol 118 GraphicUsed by:123
Symbol 119 GraphicUsed by:123
Symbol 120 GraphicUsed by:123
Symbol 121 GraphicUsed by:123
Symbol 122 GraphicUsed by:123
Symbol 123 MovieClipUses:113 114 115 116 117 118 119 120 121 122Used by:129
Symbol 124 TextUses:107Used by:129
Symbol 125 GraphicUsed by:129
Symbol 126 GraphicUsed by:127
Symbol 127 MovieClipUses:126Used by:129
Symbol 128 GraphicUsed by:129  Timeline
Symbol 129 MovieClipUses:108 109 110 111 112 123 124 125 127 128Used by:133
Symbol 130 GraphicUsed by:131
Symbol 131 ButtonUses:130Used by:133
Symbol 132 GraphicUsed by:133
Symbol 133 MovieClip {windkingdom_armor_fla.armor_promo_3}Uses:103 106 129 131 132Used by:Timeline
Symbol 134 GraphicUsed by:135
Symbol 135 MovieClipUses:134Used by:Timeline
Symbol 136 FontUsed by:137 140 660 694 696 698 704 709 714 719 799 801 802 805 806 895 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 942 978 996 1000
Symbol 137 TextUses:136Used by:Timeline
Symbol 138 FontUsed by:139 660 693 695 697 699 704 709 714 719 806 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 1000
Symbol 139 TextUses:138Used by:Timeline
Symbol 140 TextUses:136Used by:Timeline
Symbol 141 FontUsed by:142
Symbol 142 TextUses:141Used by:Timeline
Symbol 143 GraphicUsed by:146
Symbol 144 ShapeTweeningUsed by:146
Symbol 145 GraphicUsed by:146
Symbol 146 MovieClip {windkingdom_armor_fla.mcpreloaderBar_10}Uses:143 144 145Used by:Timeline
Symbol 147 FontUsed by:148 554 577 578 579 580 581 582 586 587 588 636 637 640 641 643 644 646 647 649 650 658 669 670 671 673 674 675 677 678 679 681 682 683 685 686 687 689 690 691 727 728 732 753 754 756 757 759 760 762 763 765 766 768 769 771 772 792 793 796 798 800 803 890 892 893 896 897 898 899 900 901 902 903 904 905 906 943 944 997
Symbol 148 TextUses:147Used by:150
Symbol 149 GraphicUsed by:150
Symbol 150 ButtonUses:148 149Used by:Timeline
Symbol 151 GraphicUsed by:614
Symbol 152 GraphicUsed by:614
Symbol 153 BitmapUsed by:154
Symbol 154 GraphicUses:153Used by:159
Symbol 155 BitmapUsed by:156
Symbol 156 GraphicUses:155Used by:159
Symbol 157 BitmapUsed by:158
Symbol 158 GraphicUses:157Used by:159
Symbol 159 MovieClip {mc_bigbat}Uses:154 156 158Used by:614
Symbol 160 BitmapUsed by:161
Symbol 161 GraphicUses:160Used by:176
Symbol 162 BitmapUsed by:163
Symbol 163 GraphicUses:162Used by:176
Symbol 164 BitmapUsed by:165
Symbol 165 GraphicUses:164Used by:176
Symbol 166 BitmapUsed by:167
Symbol 167 GraphicUses:166Used by:176
Symbol 168 BitmapUsed by:169
Symbol 169 GraphicUses:168Used by:176
Symbol 170 BitmapUsed by:171
Symbol 171 GraphicUses:170Used by:176
Symbol 172 BitmapUsed by:173
Symbol 173 GraphicUses:172Used by:176
Symbol 174 BitmapUsed by:175
Symbol 175 GraphicUses:174Used by:176
Symbol 176 MovieClip {mc_blackknight}Uses:161 163 165 167 169 171 173 175Used by:614
Symbol 177 BitmapUsed by:178
Symbol 178 GraphicUses:177Used by:185
Symbol 179 BitmapUsed by:180
Symbol 180 GraphicUses:179Used by:185
Symbol 181 BitmapUsed by:182
Symbol 182 GraphicUses:181Used by:185
Symbol 183 BitmapUsed by:184
Symbol 184 GraphicUses:183Used by:185
Symbol 185 MovieClip {mc_evilcopter}Uses:178 180 182 184Used by:614
Symbol 186 BitmapUsed by:187
Symbol 187 GraphicUses:186Used by:198
Symbol 188 BitmapUsed by:189
Symbol 189 GraphicUses:188Used by:198
Symbol 190 BitmapUsed by:191
Symbol 191 GraphicUses:190Used by:198
Symbol 192 BitmapUsed by:193
Symbol 193 GraphicUses:192Used by:198
Symbol 194 BitmapUsed by:195
Symbol 195 GraphicUses:194Used by:198
Symbol 196 BitmapUsed by:197
Symbol 197 GraphicUses:196Used by:198
Symbol 198 MovieClip {mc_evildragon}Uses:187 189 191 193 195 197Used by:614
Symbol 199 BitmapUsed by:200
Symbol 200 GraphicUses:199Used by:203
Symbol 201 BitmapUsed by:202
Symbol 202 GraphicUses:201Used by:203
Symbol 203 MovieClip {mc_evilpanzer}Uses:200 202Used by:614
Symbol 204 BitmapUsed by:205
Symbol 205 GraphicUses:204Used by:216
Symbol 206 BitmapUsed by:207
Symbol 207 GraphicUses:206Used by:216
Symbol 208 BitmapUsed by:209
Symbol 209 GraphicUses:208Used by:216
Symbol 210 BitmapUsed by:211
Symbol 211 GraphicUses:210Used by:216
Symbol 212 BitmapUsed by:213
Symbol 213 GraphicUses:212Used by:216
Symbol 214 BitmapUsed by:215
Symbol 215 GraphicUses:214Used by:216
Symbol 216 MovieClip {mc_evilultimate}Uses:205 207 209 211 213 215Used by:614
Symbol 217 BitmapUsed by:218
Symbol 218 GraphicUses:217Used by:223
Symbol 219 BitmapUsed by:220
Symbol 220 GraphicUses:219Used by:223
Symbol 221 BitmapUsed by:222
Symbol 222 GraphicUses:221Used by:223
Symbol 223 MovieClip {mc_smallbat}Uses:218 220 222Used by:614
Symbol 224 BitmapUsed by:225
Symbol 225 GraphicUses:224Used by:226
Symbol 226 MovieClipUses:225Used by:274
Symbol 227 BitmapUsed by:228
Symbol 228 GraphicUses:227Used by:238 253
Symbol 229 GraphicUsed by:230 333
Symbol 230 MovieClipUses:229Used by:231
Symbol 231 MovieClipUses:230Used by:253 264 270
Symbol 232 GraphicUsed by:235
Symbol 233 GraphicUsed by:235
Symbol 234 GraphicUsed by:235
Symbol 235 MovieClipUses:232 233 234Used by:253 264 270 271 272 273
Symbol 236 BitmapUsed by:237
Symbol 237 GraphicUses:236Used by:238
Symbol 238 MovieClipUses:228 237Used by:253 271
Symbol 239 ShapeTweeningUsed by:252
Symbol 240 BitmapUsed by:241
Symbol 241 GraphicUses:240Used by:252 429
Symbol 242 BitmapUsed by:243
Symbol 243 GraphicUses:242Used by:252 429
Symbol 244 BitmapUsed by:245
Symbol 245 GraphicUses:244Used by:252 429
Symbol 246 ShapeTweeningUsed by:252
Symbol 247 BitmapUsed by:248
Symbol 248 GraphicUses:247Used by:252 429
Symbol 249 BitmapUsed by:250
Symbol 250 GraphicUses:249Used by:252 429
Symbol 251 GraphicUsed by:252 429
Symbol 252 MovieClip {windkingdom_armor_fla.mc_redsplashfxcopy_27}Uses:239 241 243 245 246 248 250 251Used by:253 264 270 271 272 273
Symbol 253 MovieClip {windkingdom_armor_fla.lv1_22}Uses:228 231 235 238 252Used by:274
Symbol 254 GraphicUsed by:255
Symbol 255 MovieClipUses:254Used by:274
Symbol 256 GraphicUsed by:257
Symbol 257 MovieClipUses:256Used by:258
Symbol 258 MovieClipUses:257Used by:274
Symbol 259 BitmapUsed by:260
Symbol 260 GraphicUses:259Used by:263 264
Symbol 261 BitmapUsed by:262
Symbol 262 GraphicUses:261Used by:263
Symbol 263 MovieClipUses:260 262Used by:264 272
Symbol 264 MovieClip {windkingdom_armor_fla.lv2_31}Uses:260 231 235 263 252Used by:274
Symbol 265 BitmapUsed by:266
Symbol 266 GraphicUses:265Used by:269 270
Symbol 267 BitmapUsed by:268
Symbol 268 GraphicUses:267Used by:269
Symbol 269 MovieClipUses:266 268Used by:270 273
Symbol 270 MovieClip {windkingdom_armor_fla.lv3_33}Uses:266 231 235 269 252Used by:274
Symbol 271 MovieClipUses:235 238 252Used by:274
Symbol 272 MovieClipUses:235 263 252Used by:274
Symbol 273 MovieClipUses:235 269 252Used by:274
Symbol 274 MovieClip {mc_castle}Uses:226 253 255 258 264 270 271 272 273Used by:614
Symbol 275 BitmapUsed by:276
Symbol 276 GraphicUses:275Used by:277
Symbol 277 MovieClipUses:276Used by:294 300 306
Symbol 278 ShapeTweeningUsed by:294
Symbol 279 BitmapUsed by:280
Symbol 280 GraphicUses:279Used by:294 300 306
Symbol 281 BitmapUsed by:282 296 302
Symbol 282 GraphicUses:281Used by:294
Symbol 283 BitmapUsed by:284
Symbol 284 GraphicUses:283Used by:294 300 306
Symbol 285 ShapeTweeningUsed by:294
Symbol 286 ShapeTweeningUsed by:294
Symbol 287 BitmapUsed by:288
Symbol 288 GraphicUses:287Used by:294 300 306
Symbol 289 BitmapUsed by:290
Symbol 290 GraphicUses:289Used by:294 300 306
Symbol 291 ShapeTweeningUsed by:294
Symbol 292 GraphicUsed by:294 300 306
Symbol 293 GraphicUsed by:294 300 306
Symbol 294 MovieClip {mc_cannonblow1}Uses:277 278 280 282 284 285 286 288 290 291 292 293Used by:614
Symbol 295 ShapeTweeningUsed by:300
Symbol 296 GraphicUses:281Used by:300
Symbol 297 ShapeTweeningUsed by:300
Symbol 298 ShapeTweeningUsed by:300
Symbol 299 ShapeTweeningUsed by:300
Symbol 300 MovieClip {mc_cannonblow2}Uses:277 295 280 296 284 297 298 288 290 299 292 293Used by:614
Symbol 301 ShapeTweeningUsed by:306
Symbol 302 GraphicUses:281Used by:306
Symbol 303 ShapeTweeningUsed by:306
Symbol 304 ShapeTweeningUsed by:306
Symbol 305 ShapeTweeningUsed by:306
Symbol 306 MovieClip {mc_cannonblow3}Uses:277 301 280 302 284 303 304 288 290 305 292 293Used by:614
Symbol 307 BitmapUsed by:308 311
Symbol 308 GraphicUses:307Used by:313
Symbol 309 BitmapUsed by:310 312
Symbol 310 GraphicUses:309Used by:313
Symbol 311 GraphicUses:307Used by:313
Symbol 312 GraphicUses:309Used by:313
Symbol 313 MovieClipUses:308 310 311 312Used by:314
Symbol 314 MovieClip {mc_cannonbullet}Uses:313Used by:614
Symbol 315 BitmapUsed by:316
Symbol 316 GraphicUses:315Used by:317
Symbol 317 MovieClip {mc_firebullet}Uses:316Used by:614
Symbol 318 BitmapUsed by:319
Symbol 319 GraphicUses:318Used by:320
Symbol 320 MovieClip {mc_frozenbullet}Uses:319Used by:614
Symbol 321 BitmapUsed by:322
Symbol 322 GraphicUses:321Used by:323
Symbol 323 MovieClip {mc_icebullet}Uses:322Used by:614
Symbol 324 BitmapUsed by:325
Symbol 325 GraphicUses:324Used by:330
Symbol 326 BitmapUsed by:327
Symbol 327 GraphicUses:326Used by:330
Symbol 328 BitmapUsed by:329
Symbol 329 GraphicUses:328Used by:330
Symbol 330 MovieClip {mc_thunder}Uses:325 327 329Used by:614
Symbol 331 BitmapUsed by:332
Symbol 332 GraphicUses:331Used by:335
Symbol 333 MovieClipUses:229Used by:334 338 342
Symbol 334 MovieClipUses:333Used by:335
Symbol 335 MovieClip {mc_fireturret}Uses:332 334Used by:614
Symbol 336 BitmapUsed by:337
Symbol 337 GraphicUses:336Used by:339
Symbol 338 MovieClipUses:333Used by:339
Symbol 339 MovieClip {mc_iceturret}Uses:337 338Used by:614
Symbol 340 BitmapUsed by:341
Symbol 341 GraphicUses:340Used by:343
Symbol 342 MovieClipUses:333Used by:343
Symbol 343 MovieClip {mc_thunderturret}Uses:341 342Used by:614
Symbol 344 BitmapUsed by:345 826 844
Symbol 345 GraphicUses:344Used by:352
Symbol 346 BitmapUsed by:347
Symbol 347 GraphicUses:346Used by:352
Symbol 348 BitmapUsed by:349
Symbol 349 GraphicUses:348Used by:352
Symbol 350 BitmapUsed by:351
Symbol 351 GraphicUses:350Used by:352
Symbol 352 MovieClip {mc_copter}Uses:345 347 349 351Used by:614
Symbol 353 BitmapUsed by:354
Symbol 354 GraphicUses:353Used by:365
Symbol 355 BitmapUsed by:356 833
Symbol 356 GraphicUses:355Used by:365
Symbol 357 BitmapUsed by:358
Symbol 358 GraphicUses:357Used by:365
Symbol 359 BitmapUsed by:360
Symbol 360 GraphicUses:359Used by:365
Symbol 361 BitmapUsed by:362
Symbol 362 GraphicUses:361Used by:365
Symbol 363 BitmapUsed by:364
Symbol 364 GraphicUses:363Used by:365
Symbol 365 MovieClip {mc_dragon}Uses:354 356 358 360 362 364Used by:614
Symbol 366 BitmapUsed by:367
Symbol 367 GraphicUses:366Used by:378 829
Symbol 368 BitmapUsed by:369
Symbol 369 GraphicUses:368Used by:378
Symbol 370 BitmapUsed by:371
Symbol 371 GraphicUses:370Used by:378
Symbol 372 BitmapUsed by:373
Symbol 373 GraphicUses:372Used by:378
Symbol 374 BitmapUsed by:375
Symbol 375 GraphicUses:374Used by:378
Symbol 376 BitmapUsed by:377
Symbol 377 GraphicUses:376Used by:378
Symbol 378 MovieClip {mc_eagle}Uses:367 369 371 373 375 377Used by:614
Symbol 379 BitmapUsed by:380
Symbol 380 GraphicUses:379Used by:383
Symbol 381 BitmapUsed by:382
Symbol 382 GraphicUses:381Used by:383
Symbol 383 MovieClip {mc_panzer}Uses:380 382Used by:614
Symbol 384 BitmapUsed by:385 824
Symbol 385 GraphicUses:384Used by:388
Symbol 386 BitmapUsed by:387
Symbol 387 GraphicUses:386Used by:388
Symbol 388 MovieClip {mc_rider}Uses:385 387Used by:614
Symbol 389 ShapeTweeningUsed by:402
Symbol 390 BitmapUsed by:391
Symbol 391 GraphicUses:390Used by:402
Symbol 392 BitmapUsed by:393
Symbol 393 GraphicUses:392Used by:402
Symbol 394 BitmapUsed by:395
Symbol 395 GraphicUses:394Used by:402
Symbol 396 ShapeTweeningUsed by:402
Symbol 397 BitmapUsed by:398
Symbol 398 GraphicUses:397Used by:402
Symbol 399 BitmapUsed by:400
Symbol 400 GraphicUses:399Used by:402
Symbol 401 GraphicUsed by:402
Symbol 402 MovieClip {mc_bluesplashfx}Uses:389 391 393 395 396 398 400 401Used by:614
Symbol 403 ShapeTweeningUsed by:412
Symbol 404 BitmapUsed by:405
Symbol 405 GraphicUses:404Used by:412
Symbol 406 BitmapUsed by:407
Symbol 407 GraphicUses:406Used by:412
Symbol 408 ShapeTweeningUsed by:412
Symbol 409 BitmapUsed by:410
Symbol 410 GraphicUses:409Used by:412
Symbol 411 GraphicUsed by:412
Symbol 412 MovieClip {mc_electricsplashfx}Uses:403 405 407 408 410 411Used by:614
Symbol 413 ShapeTweeningUsed by:418
Symbol 414 ShapeTweeningUsed by:418
Symbol 415 ShapeTweeningUsed by:418
Symbol 416 ShapeTweeningUsed by:418
Symbol 417 GraphicUsed by:418
Symbol 418 MovieClip {mc_healthbar}Uses:413 414 415 416 417Used by:614
Symbol 419 GraphicUsed by:426
Symbol 420 GraphicUsed by:426
Symbol 421 GraphicUsed by:426
Symbol 422 GraphicUsed by:426
Symbol 423 GraphicUsed by:426
Symbol 424 GraphicUsed by:426
Symbol 425 GraphicUsed by:426
Symbol 426 MovieClip {mc_progress}Uses:419 420 421 422 423 424 425Used by:614
Symbol 427 ShapeTweeningUsed by:429
Symbol 428 ShapeTweeningUsed by:429
Symbol 429 MovieClip {mc_redsplashfx}Uses:427 241 243 245 428 248 250 251Used by:614
Symbol 430 BitmapUsed by:431
Symbol 431 GraphicUses:430Used by:432
Symbol 432 MovieClip {background1}Uses:431Used by:614
Symbol 433 GraphicUsed by:434
Symbol 434 MovieClip {mc_cover}Uses:433Used by:614
Symbol 435 BitmapUsed by:436
Symbol 436 GraphicUses:435Used by:562
Symbol 437 BitmapUsed by:438
Symbol 438 GraphicUses:437Used by:451
Symbol 439 GraphicUsed by:450
Symbol 440 GraphicUsed by:450
Symbol 441 GraphicUsed by:450
Symbol 442 GraphicUsed by:450
Symbol 443 GraphicUsed by:450
Symbol 444 GraphicUsed by:450
Symbol 445 GraphicUsed by:450
Symbol 446 GraphicUsed by:450
Symbol 447 GraphicUsed by:450
Symbol 448 GraphicUsed by:450
Symbol 449 GraphicUsed by:450
Symbol 450 MovieClipUses:439 440 441 442 443 444 445 446 447 448 449Used by:451
Symbol 451 MovieClip {windkingdom_armor_fla.iconspecialattack_68}Uses:438 450Used by:562
Symbol 452 BitmapUsed by:453
Symbol 453 GraphicUses:452Used by:456
Symbol 454 BitmapUsed by:455
Symbol 455 GraphicUses:454Used by:456
Symbol 456 MovieClipUses:453 455Used by:562
Symbol 457 BitmapUsed by:458
Symbol 458 GraphicUses:457Used by:461
Symbol 459 BitmapUsed by:460
Symbol 460 GraphicUses:459Used by:461
Symbol 461 MovieClipUses:458 460Used by:562
Symbol 462 BitmapUsed by:463
Symbol 463 GraphicUses:462Used by:466
Symbol 464 BitmapUsed by:465
Symbol 465 GraphicUses:464Used by:466
Symbol 466 MovieClipUses:463 465Used by:562
Symbol 467 BitmapUsed by:468
Symbol 468 GraphicUses:467Used by:471
Symbol 469 BitmapUsed by:470
Symbol 470 GraphicUses:469Used by:471
Symbol 471 MovieClipUses:468 470Used by:562
Symbol 472 BitmapUsed by:473
Symbol 473 GraphicUses:472Used by:476
Symbol 474 BitmapUsed by:475
Symbol 475 GraphicUses:474Used by:476
Symbol 476 MovieClipUses:473 475Used by:562
Symbol 477 BitmapUsed by:478
Symbol 478 GraphicUses:477Used by:481
Symbol 479 BitmapUsed by:480
Symbol 480 GraphicUses:479Used by:481
Symbol 481 MovieClipUses:478 480Used by:562
Symbol 482 BitmapUsed by:483
Symbol 483 GraphicUses:482Used by:486
Symbol 484 BitmapUsed by:485
Symbol 485 GraphicUses:484Used by:486
Symbol 486 MovieClipUses:483 485Used by:562
Symbol 487 BitmapUsed by:488
Symbol 488 GraphicUses:487Used by:491
Symbol 489 BitmapUsed by:490
Symbol 490 GraphicUses:489Used by:491
Symbol 491 MovieClipUses:488 490Used by:562
Symbol 492 BitmapUsed by:493
Symbol 493 GraphicUses:492Used by:496 499 502 505 508 511 514 517
Symbol 494 GraphicUsed by:496
Symbol 495 GraphicUsed by:496
Symbol 496 MovieClipUses:493 494 495Used by:562
Symbol 497 GraphicUsed by:499
Symbol 498 GraphicUsed by:499
Symbol 499 MovieClipUses:493 497 498Used by:562
Symbol 500 GraphicUsed by:502
Symbol 501 GraphicUsed by:502
Symbol 502 MovieClipUses:493 500 501Used by:562
Symbol 503 GraphicUsed by:505
Symbol 504 GraphicUsed by:505
Symbol 505 MovieClipUses:493 503 504Used by:562
Symbol 506 GraphicUsed by:508
Symbol 507 GraphicUsed by:508
Symbol 508 MovieClipUses:493 506 507Used by:562
Symbol 509 GraphicUsed by:511
Symbol 510 GraphicUsed by:511
Symbol 511 MovieClipUses:493 509 510Used by:562
Symbol 512 GraphicUsed by:514
Symbol 513 GraphicUsed by:514
Symbol 514 MovieClipUses:493 512 513Used by:562
Symbol 515 GraphicUsed by:517
Symbol 516 GraphicUsed by:517
Symbol 517 MovieClipUses:493 515 516Used by:562
Symbol 518 BitmapUsed by:519
Symbol 519 GraphicUses:518Used by:520
Symbol 520 ButtonUses:519Used by:562
Symbol 521 BitmapUsed by:522
Symbol 522 GraphicUses:521Used by:523
Symbol 523 ButtonUses:522Used by:562
Symbol 524 BitmapUsed by:525
Symbol 525 GraphicUses:524Used by:526
Symbol 526 ButtonUses:525Used by:562
Symbol 527 GraphicUsed by:533
Symbol 528 FontUsed by:529
Symbol 529 EditableTextUses:528Used by:533
Symbol 530 EditableTextUses:36Used by:533
Symbol 531 EditableTextUses:36Used by:533
Symbol 532 GraphicUsed by:533
Symbol 533 MovieClip {windkingdom_armor_fla.rightnote_89}Uses:527 529 530 531 532Used by:562
Symbol 534 GraphicUsed by:536
Symbol 535 ShapeTweeningUsed by:536
Symbol 536 MovieClip {windkingdom_armor_fla.health_90}Uses:534 535Used by:562
Symbol 537 ShapeTweeningUsed by:539
Symbol 538 GraphicUsed by:539
Symbol 539 MovieClipUses:537 538Used by:562
Symbol 540 BitmapUsed by:541
Symbol 541 GraphicUses:540Used by:562
Symbol 542 EditableTextUses:36Used by:562
Symbol 543 BitmapUsed by:544
Symbol 544 GraphicUses:543Used by:553
Symbol 545 BitmapUsed by:546
Symbol 546 GraphicUses:545Used by:553
Symbol 547 BitmapUsed by:548
Symbol 548 GraphicUses:547Used by:553
Symbol 549 BitmapUsed by:550
Symbol 550 GraphicUses:549Used by:553
Symbol 551 BitmapUsed by:552
Symbol 552 GraphicUses:551Used by:553
Symbol 553 MovieClipUses:544 546 548 550 552Used by:562
Symbol 554 EditableTextUses:147Used by:562
Symbol 555 EditableTextUses:36Used by:562
Symbol 556 BitmapUsed by:559
Symbol 557 BitmapUsed by:559
Symbol 558 BitmapUsed by:559
Symbol 559 GraphicUses:556 557 558Used by:562
Symbol 560 GraphicUsed by:561
Symbol 561 MovieClipUses:560Used by:562
Symbol 562 MovieClip {mc_levelpanel}Uses:436 451 456 461 466 471 476 481 486 491 496 499 502 505 508 511 514 517 520 523 526 533 536 539 541 542 553 554 555 559 561Used by:614
Symbol 563 GraphicUsed by:572
Symbol 564 GraphicUsed by:567
Symbol 565 GraphicUsed by:567
Symbol 566 GraphicUsed by:567
Symbol 567 ButtonUses:564 565 566Used by:572
Symbol 568 GraphicUsed by:571
Symbol 569 GraphicUsed by:571
Symbol 570 GraphicUsed by:571
Symbol 571 ButtonUses:568 569 570Used by:572
Symbol 572 MovieClip {mc_scroller}Uses:563 567 74 571Used by:614
Symbol 573 GraphicUsed by:574
Symbol 574 MovieClipUses:573Used by:583
Symbol 575 GraphicUsed by:576
Symbol 576 MovieClipUses:575Used by:583 797
Symbol 577 TextUses:147Used by:583
Symbol 578 TextUses:147Used by:583
Symbol 579 TextUses:147Used by:583
Symbol 580 TextUses:147Used by:583
Symbol 581 TextUses:147Used by:583
Symbol 582 TextUses:147Used by:583
Symbol 583 MovieClip {mc_tutorial}Uses:574 576 577 578 579 580 581 582Used by:614
Symbol 584 BitmapUsed by:585
Symbol 585 GraphicUses:584Used by:598
Symbol 586 TextUses:147Used by:598
Symbol 587 TextUses:147Used by:598
Symbol 588 TextUses:147Used by:598
Symbol 589 BitmapUsed by:590
Symbol 590 GraphicUses:589Used by:591
Symbol 591 MovieClipUses:590Used by:598
Symbol 592 BitmapUsed by:593
Symbol 593 GraphicUses:592Used by:594
Symbol 594 MovieClipUses:593Used by:598
Symbol 595 BitmapUsed by:596
Symbol 596 GraphicUses:595Used by:597
Symbol 597 MovieClipUses:596Used by:598
Symbol 598 MovieClip {paneloption}Uses:585 586 587 588 591 594 597 95Used by:614
Symbol 599 Sound {bgmintro}Used by:614
Symbol 600 Sound {bgmcover}Used by:614
Symbol 601 Sound {bgmstage}Used by:614
Symbol 602 SoundUsed by:614 639 642 645 648 651 729 755 758 761 764 767 770 773 794 894 945
Symbol 603 SoundUsed by:614 639 642 645 648 651 729 755 758 761 764 767 770 773 794 894 945
Symbol 604 Sound {sfxambient}Used by:614
Symbol 605 Sound {sfxcannonhit1}Used by:614
Symbol 606 Sound {sfxcannonhit2}Used by:614
Symbol 607 Sound {sfxcannonhit3}Used by:614
Symbol 608 Sound {sfxcannonshoot}Used by:614
Symbol 609 Sound {sfxplasmahit}Used by:614
Symbol 610 Sound {sfxplasmashoot}Used by:614
Symbol 611 Sound {sfxspecialattack}Used by:614
Symbol 612 Sound {sfxtest}Used by:614
Symbol 613 SoundUsed by:614 672 676 680 684 688 692 738 740 742 744 746 748 750 752
Symbol 614 MovieClip {windkingdom_armor_fla.mc_preload_dumper_12}Uses:151 152 159 176 185 198 203 216 223 274 294 300 306 314 317 320 323 330 335 339 343 352 365 378 383 388 402 412 418 426 429 432 434 562 572 583 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613Used by:Timeline
Symbol 615 GraphicUsed by:630
Symbol 616 GraphicUsed by:630
Symbol 617 GraphicUsed by:630
Symbol 618 SoundUsed by:630
Symbol 619 SoundUsed by:630
Symbol 620 GraphicUsed by:630
Symbol 621 GraphicUsed by:622
Symbol 622 MovieClipUses:621Used by:630
Symbol 623 SoundUsed by:630
Symbol 624 SoundUsed by:630
Symbol 625 SoundUsed by:630
Symbol 626 GraphicUsed by:627
Symbol 627 ButtonUses:626Used by:630
Symbol 628 SoundUsed by:630
Symbol 629 SoundUsed by:630
Symbol 630 MovieClip {windkingdom_armor_fla.ag_intro_mc_115}Uses:615 616 617 618 619 620 622 623 624 625 627 628 629Used by:Timeline
Symbol 631 BitmapUsed by:632
Symbol 632 GraphicUses:631Used by:633
Symbol 633 MovieClipUses:632Used by:Timeline
Symbol 634 BitmapUsed by:635
Symbol 635 GraphicUses:634Used by:639 642 645 648 651
Symbol 636 TextUses:147Used by:639
Symbol 637 TextUses:147Used by:639
Symbol 638 GraphicUsed by:639 642 645 648 651
Symbol 639 ButtonUses:635 636 637 638 602 603Used by:Timeline
Symbol 640 TextUses:147Used by:642
Symbol 641 TextUses:147Used by:642
Symbol 642 ButtonUses:635 640 641 638 602 603Used by:Timeline
Symbol 643 TextUses:147Used by:645
Symbol 644 TextUses:147Used by:645
Symbol 645 ButtonUses:635 643 644 638 602 603Used by:Timeline
Symbol 646 TextUses:147Used by:648
Symbol 647 TextUses:147Used by:648
Symbol 648 ButtonUses:635 646 647 638 602 603Used by:Timeline
Symbol 649 TextUses:147Used by:651
Symbol 650 TextUses:147Used by:651
Symbol 651 ButtonUses:635 649 650 638 602 603Used by:Timeline
Symbol 652 BitmapUsed by:653
Symbol 653 GraphicUses:652Used by:654
Symbol 654 ButtonUses:653Used by:Timeline
Symbol 655 BitmapUsed by:656
Symbol 656 GraphicUses:655Used by:657
Symbol 657 MovieClipUses:656Used by:Timeline
Symbol 658 TextUses:147Used by:Timeline
Symbol 659 GraphicUsed by:Timeline
Symbol 660 TextUses:138 136Used by:724
Symbol 661 BitmapUsed by:663 668 700 705 710 715 720
Symbol 662 BitmapUsed by:663 700 705 710 715 720
Symbol 663 GraphicUses:661 662Used by:724
Symbol 664 FontUsed by:665 667 701 706 711 716 721
Symbol 665 TextUses:664Used by:667
Symbol 666 TextUsed by:667
Symbol 667 MovieClipUses:664 665 666Used by:724
Symbol 668 GraphicUses:661Used by:672 676 680 684 688 692
Symbol 669 TextUses:147Used by:672
Symbol 670 TextUses:147Used by:672
Symbol 671 TextUses:147Used by:672
Symbol 672 ButtonUses:668 669 670 671 613Used by:724
Symbol 673 TextUses:147Used by:676
Symbol 674 TextUses:147Used by:676
Symbol 675 TextUses:147Used by:676
Symbol 676 ButtonUses:668 673 674 675 613Used by:724
Symbol 677 TextUses:147Used by:680
Symbol 678 TextUses:147Used by:680
Symbol 679 TextUses:147Used by:680
Symbol 680 ButtonUses:668 677 678 679 613Used by:724
Symbol 681 TextUses:147Used by:684
Symbol 682 TextUses:147Used by:684
Symbol 683 TextUses:147Used by:684
Symbol 684 ButtonUses:668 681 682 683 613Used by:724
Symbol 685 TextUses:147Used by:688
Symbol 686 TextUses:147Used by:688
Symbol 687 TextUses:147Used by:688
Symbol 688 ButtonUses:668 685 686 687 613Used by:724
Symbol 689 TextUses:147Used by:692
Symbol 690 TextUses:147Used by:692
Symbol 691 TextUses:147Used by:692
Symbol 692 ButtonUses:668 689 690 691 613Used by:724
Symbol 693 TextUses:138Used by:724
Symbol 694 TextUses:136Used by:724
Symbol 695 TextUses:138Used by:724
Symbol 696 TextUses:136Used by:724
Symbol 697 TextUses:138Used by:724
Symbol 698 TextUses:136Used by:724
Symbol 699 TextUses:138Used by:724
Symbol 700 GraphicUses:661 662Used by:724
Symbol 701 TextUses:664Used by:703
Symbol 702 TextUsed by:703
Symbol 703 MovieClipUses:701 702Used by:724
Symbol 704 TextUses:138 136Used by:724
Symbol 705 GraphicUses:661 662Used by:724
Symbol 706 TextUses:664Used by:708
Symbol 707 TextUsed by:708
Symbol 708 MovieClipUses:706 707Used by:724
Symbol 709 TextUses:138 136Used by:724
Symbol 710 GraphicUses:661 662Used by:724
Symbol 711 TextUses:664Used by:713
Symbol 712 TextUsed by:713
Symbol 713 MovieClipUses:711 712Used by:724
Symbol 714 TextUses:138 136Used by:724
Symbol 715 GraphicUses:661 662Used by:724
Symbol 716 TextUses:664Used by:718
Symbol 717 TextUsed by:718
Symbol 718 MovieClipUses:716 717Used by:724
Symbol 719 TextUses:138 136Used by:724
Symbol 720 GraphicUses:661 662Used by:724
Symbol 721 TextUses:664Used by:723
Symbol 722 TextUsed by:723
Symbol 723 MovieClipUses:721 722Used by:724
Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126}Uses:660 663 667 672 676 680 684 688 692 693 694 695 696 697 698 699 700 703 704 705 708 709 710 713 714 715 718 719 720 723Used by:Timeline
Symbol 725 BitmapUsed by:726
Symbol 726 GraphicUses:725Used by:729 755 758 761 764 767 770 773 794 894 945
Symbol 727 TextUses:147Used by:729
Symbol 728 TextUses:147Used by:729
Symbol 729 ButtonUses:726 727 728 602 603Used by:Timeline
Symbol 730 BitmapUsed by:731 774 999
Symbol 731 GraphicUses:730Used by:Timeline
Symbol 732 TextUses:147Used by:Timeline
Symbol 733 BitmapUsed by:734
Symbol 734 GraphicUses:733Used by:738 740 742 744 746 748 750 752
Symbol 735 FontUsed by:736 739 741 743 745 747 749 751 776 777 778 779 780 781 782 783 784 785 787 789
Symbol 736 TextUses:735Used by:738
Symbol 737 GraphicUsed by:738 740 742 744 746 748 750 752
Symbol 738 ButtonUses:734 736 737 613Used by:Timeline
Symbol 739 TextUses:735Used by:740
Symbol 740 ButtonUses:734 739 737 613Used by:Timeline
Symbol 741 TextUses:735Used by:742
Symbol 742 ButtonUses:734 741 737 613Used by:Timeline
Symbol 743 TextUses:735Used by:744
Symbol 744 ButtonUses:734 743 737 613Used by:Timeline
Symbol 745 TextUses:735Used by:746
Symbol 746 ButtonUses:734 745 737 613Used by:Timeline
Symbol 747 TextUses:735Used by:748
Symbol 748 ButtonUses:734 747 737 613Used by:Timeline
Symbol 749 TextUses:735Used by:750
Symbol 750 ButtonUses:734 749 737 613Used by:Timeline
Symbol 751 TextUses:735Used by:752
Symbol 752 ButtonUses:734 751 737 613Used by:Timeline
Symbol 753 TextUses:147Used by:755
Symbol 754 TextUses:147Used by:755
Symbol 755 ButtonUses:726 753 754 602 603Used by:Timeline
Symbol 756 TextUses:147Used by:758
Symbol 757 TextUses:147Used by:758
Symbol 758 ButtonUses:726 756 757 602 603Used by:Timeline
Symbol 759 TextUses:147Used by:761
Symbol 760 TextUses:147Used by:761
Symbol 761 ButtonUses:726 759 760 602 603Used by:Timeline
Symbol 762 TextUses:147Used by:764
Symbol 763 TextUses:147Used by:764
Symbol 764 ButtonUses:726 762 763 602 603Used by:Timeline
Symbol 765 TextUses:147Used by:767
Symbol 766 TextUses:147Used by:767
Symbol 767 ButtonUses:726 765 766 602 603Used by:Timeline
Symbol 768 TextUses:147Used by:770
Symbol 769 TextUses:147Used by:770
Symbol 770 ButtonUses:726 768 769 602 603Used by:Timeline
Symbol 771 TextUses:147Used by:773
Symbol 772 TextUses:147Used by:773
Symbol 773 ButtonUses:726 771 772 602 603Used by:Timeline
Symbol 774 GraphicUses:730Used by:791
Symbol 775 FontUsed by:776 778 780 782 784 786 788 790
Symbol 776 TextUses:735 775Used by:791
Symbol 777 TextUses:735Used by:791
Symbol 778 TextUses:775 735Used by:791
Symbol 779 TextUses:735Used by:791
Symbol 780 TextUses:775 735Used by:791
Symbol 781 TextUses:735Used by:791
Symbol 782 TextUses:775 735Used by:791
Symbol 783 TextUses:735Used by:791
Symbol 784 TextUses:775 735Used by:791
Symbol 785 TextUses:735Used by:791
Symbol 786 TextUses:775Used by:791
Symbol 787 TextUses:735Used by:791
Symbol 788 TextUses:775Used by:791
Symbol 789 TextUses:735Used by:791
Symbol 790 TextUses:775Used by:791
Symbol 791 MovieClipUses:774 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790Used by:Timeline
Symbol 792 TextUses:147Used by:794
Symbol 793 TextUses:147Used by:794
Symbol 794 ButtonUses:726 792 793 602 603Used by:Timeline
Symbol 795 GraphicUsed by:797
Symbol 796 TextUses:147Used by:797
Symbol 797 MovieClip {windkingdom_armor_fla.mc_tutorialskills_151}Uses:795 576 796Used by:Timeline
Symbol 798 TextUses:147Used by:Timeline
Symbol 799 TextUses:136Used by:Timeline
Symbol 800 TextUses:147Used by:Timeline
Symbol 801 TextUses:136Used by:Timeline
Symbol 802 TextUses:136Used by:Timeline
Symbol 803 TextUses:147Used by:Timeline
Symbol 804 GraphicUsed by:Timeline
Symbol 805 TextUses:136Used by:Timeline
Symbol 806 EditableTextUses:136 138Used by:Timeline
Symbol 807 FontUsed by:808 810 908
Symbol 808 TextUses:807Used by:809
Symbol 809 MovieClipUses:808Used by:812
Symbol 810 TextUses:807Used by:811
Symbol 811 MovieClipUses:810Used by:812
Symbol 812 MovieClip {windkingdom_armor_fla.upgradewarning_152}Uses:809 811Used by:Timeline
Symbol 813 GraphicUsed by:823 829 832 834 837 840 843
Symbol 814 BitmapUsed by:815
Symbol 815 GraphicUses:814Used by:823
Symbol 816 GraphicUsed by:817
Symbol 817 MovieClipUses:816Used by:823 825 827 829 832 834 837 840 843 850 852 855 857
Symbol 818 GraphicUsed by:823 825 827 829 832 834 837 840 843
Symbol 819 GraphicUsed by:823 825 827 829 832 834 837 840 843
Symbol 820 GraphicUsed by:823 825 827 829 832 834 837 840 843
Symbol 821 GraphicUsed by:823 825 827 829 832 834 837 840 843
Symbol 822 GraphicUsed by:823 825 827 829 832 834 837 840 843
Symbol 823 MovieClip {windkingdom_armor_fla.btupgradecastle_155}Uses:813 815 817 818 819 820 821 822Used by:Timeline
Symbol 824 GraphicUses:384Used by:825
Symbol 825 MovieClip {windkingdom_armor_fla.btupgraderider_157}Uses:824 817 818 819 820 821 822Used by:Timeline
Symbol 826 GraphicUses:344Used by:827
Symbol 827 MovieClip {windkingdom_armor_fla.btupgradecopter_158}Uses:826 817 818 819 820 821 822Used by:Timeline
Symbol 828 GraphicUsed by:829 832 834 837 840 843 855 857
Symbol 829 MovieClip {windkingdom_armor_fla.btupgradeeagle_159}Uses:828 813 367 817 818 819 820 821 822Used by:Timeline
Symbol 830 BitmapUsed by:831
Symbol 831 GraphicUses:830Used by:832
Symbol 832 MovieClip {windkingdom_armor_fla.btupgradepanzer_160}Uses:828 813 831 817 818 819 820 821 822Used by:Timeline
Symbol 833 GraphicUses:355Used by:834
Symbol 834 MovieClip {windkingdom_armor_fla.btupgradedragon_161}Uses:828 813 833 817 818 819 820 821 822Used by:Timeline
Symbol 835 BitmapUsed by:836
Symbol 836 GraphicUses:835Used by:837
Symbol 837 MovieClip {windkingdom_armor_fla.btupgradeiceturret_162}Uses:828 813 836 817 818 819 820 821 822Used by:Timeline
Symbol 838 BitmapUsed by:839 851
Symbol 839 GraphicUses:838Used by:840
Symbol 840 MovieClip {windkingdom_armor_fla.btupgradefireturret_163}Uses:828 813 839 817 818 819 820 821 822Used by:Timeline
Symbol 841 BitmapUsed by:842
Symbol 842 GraphicUses:841Used by:843
Symbol 843 MovieClip {windkingdom_armor_fla.btupgradethunderturret_164}Uses:828 813 842 817 818 819 820 821 822Used by:Timeline
Symbol 844 GraphicUses:344Used by:850
Symbol 845 GraphicUsed by:850 852 855 857
Symbol 846 GraphicUsed by:850 852 855 857
Symbol 847 GraphicUsed by:850 852 855 857
Symbol 848 GraphicUsed by:850 852 855 857
Symbol 849 GraphicUsed by:850 852 855 857
Symbol 850 MovieClip {windkingdom_armor_fla.btupgradeunitcreatetime_165}Uses:844 817 845 846 847 848 849Used by:Timeline
Symbol 851 GraphicUses:838Used by:852
Symbol 852 MovieClip {windkingdom_armor_fla.btupgradeturretcreatetime_166}Uses:851 817 845 846 847 848 849Used by:Timeline
Symbol 853 GraphicUsed by:855 857
Symbol 854 GraphicUsed by:855
Symbol 855 MovieClip {windkingdom_armor_fla.btupgrademanaregeneratetime_167}Uses:828 853 854 817 845 846 847 848 849Used by:Timeline
Symbol 856 GraphicUsed by:857
Symbol 857 MovieClip {windkingdom_armor_fla.btupgradeinitialmanabank_168}Uses:828 853 856 817 845 846 847 848 849Used by:Timeline
Symbol 858 BitmapUsed by:859
Symbol 859 GraphicUses:858Used by:889
Symbol 860 FontUsed by:861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976
Symbol 861 EditableTextUses:860Used by:889
Symbol 862 TextUses:860Used by:889
Symbol 863 TextUses:860Used by:889
Symbol 864 TextUses:860Used by:889
Symbol 865 TextUses:860Used by:889
Symbol 866 TextUses:860Used by:889
Symbol 867 TextUses:860Used by:889
Symbol 868 TextUses:860Used by:889
Symbol 869 TextUses:860Used by:889
Symbol 870 TextUses:860Used by:889
Symbol 871 TextUses:860Used by:889
Symbol 872 TextUses:860Used by:889
Symbol 873 TextUses:860Used by:889
Symbol 874 TextUses:860Used by:889
Symbol 875 TextUses:860Used by:889
Symbol 876 TextUses:860Used by:889
Symbol 877 TextUses:860Used by:889
Symbol 878 TextUses:860Used by:889
Symbol 879 TextUses:860Used by:889
Symbol 880 TextUses:860Used by:889
Symbol 881 TextUses:860Used by:889
Symbol 882 TextUses:860Used by:889
Symbol 883 TextUses:860Used by:889
Symbol 884 TextUses:860Used by:889
Symbol 885 TextUses:860Used by:889
Symbol 886 TextUses:860Used by:889
Symbol 887 TextUses:860Used by:889
Symbol 888 TextUses:860Used by:889
Symbol 889 MovieClip {windkingdom_armor_fla.panelnote_169}Uses:859 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888Used by:Timeline
Symbol 890 TextUses:147Used by:Timeline
Symbol 891 GraphicUsed by:Timeline
Symbol 892 TextUses:147Used by:894
Symbol 893 TextUses:147Used by:894
Symbol 894 ButtonUses:726 892 893 602 603Used by:Timeline
Symbol 895 TextUses:136Used by:Timeline
Symbol 896 EditableTextUses:147Used by:Timeline
Symbol 897 EditableTextUses:147Used by:Timeline
Symbol 898 EditableTextUses:147Used by:Timeline
Symbol 899 EditableTextUses:147Used by:Timeline
Symbol 900 EditableTextUses:147Used by:Timeline
Symbol 901 EditableTextUses:147Used by:Timeline
Symbol 902 EditableTextUses:147Used by:Timeline
Symbol 903 EditableTextUses:147Used by:Timeline
Symbol 904 EditableTextUses:147Used by:Timeline
Symbol 905 TextUses:147Used by:Timeline
Symbol 906 TextUses:147Used by:Timeline
Symbol 907 GraphicUsed by:941 977 995
Symbol 908 TextUses:807Used by:941 977 995
Symbol 909 TextUses:136Used by:941 977 995
Symbol 910 TextUses:136Used by:941 977 995
Symbol 911 TextUses:136Used by:941 977 995
Symbol 912 TextUses:136Used by:941 977 995
Symbol 913 TextUses:136Used by:941 977 995
Symbol 914 TextUses:136Used by:941 977 995
Symbol 915 TextUses:136Used by:941 977 995
Symbol 916 TextUses:136Used by:941 977 995
Symbol 917 TextUses:136Used by:941 977 995
Symbol 918 TextUses:136Used by:941 977 995
Symbol 919 TextUses:136Used by:941 977 995
Symbol 920 TextUses:136Used by:941 977 995
Symbol 921 TextUses:136Used by:941 977 995
Symbol 922 TextUses:136Used by:941 977 995
Symbol 923 TextUses:136Used by:941 977 995
Symbol 924 EditableTextUses:138Used by:941
Symbol 925 EditableTextUses:138Used by:941
Symbol 926 EditableTextUses:138Used by:941
Symbol 927 EditableTextUses:138Used by:941
Symbol 928 EditableTextUses:138Used by:941
Symbol 929 EditableTextUses:138Used by:941
Symbol 930 EditableTextUses:138Used by:941
Symbol 931 EditableTextUses:138Used by:941
Symbol 932 EditableTextUses:138Used by:941
Symbol 933 EditableTextUses:138Used by:941
Symbol 934 EditableTextUses:138Used by:941
Symbol 935 EditableTextUses:138Used by:941
Symbol 936 EditableTextUses:138Used by:941
Symbol 937 EditableTextUses:138Used by:941
Symbol 938 EditableTextUses:138Used by:941
Symbol 939 TextUses:138Used by:941 977 995
Symbol 940 EditableTextUses:138Used by:941
Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171}Uses:907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940Used by:Timeline
Symbol 942 TextUses:136Used by:Timeline
Symbol 943 TextUses:147Used by:945
Symbol 944 TextUses:147Used by:945
Symbol 945 ButtonUses:726 943 944 602 603Used by:Timeline
Symbol 946 EditableTextUses:138Used by:977
Symbol 947 EditableTextUses:138Used by:977
Symbol 948 EditableTextUses:138Used by:977
Symbol 949 EditableTextUses:138Used by:977
Symbol 950 EditableTextUses:138Used by:977
Symbol 951 EditableTextUses:138Used by:977
Symbol 952 EditableTextUses:138Used by:977
Symbol 953 EditableTextUses:138Used by:977
Symbol 954 EditableTextUses:138Used by:977
Symbol 955 EditableTextUses:138Used by:977
Symbol 956 EditableTextUses:138Used by:977
Symbol 957 EditableTextUses:138Used by:977
Symbol 958 EditableTextUses:138Used by:977
Symbol 959 EditableTextUses:138Used by:977
Symbol 960 EditableTextUses:138Used by:977
Symbol 961 EditableTextUses:138Used by:977
Symbol 962 TextUses:860Used by:977 995
Symbol 963 TextUses:860Used by:977 995
Symbol 964 TextUses:860Used by:977 995
Symbol 965 TextUses:860Used by:977 995
Symbol 966 TextUses:860Used by:977 995
Symbol 967 TextUses:860Used by:977 995
Symbol 968 TextUses:860Used by:977 995
Symbol 969 TextUses:860Used by:977 995
Symbol 970 TextUses:860Used by:977 995
Symbol 971 TextUses:860Used by:977 995
Symbol 972 TextUses:860Used by:977 995
Symbol 973 TextUses:860Used by:977 995
Symbol 974 TextUses:860Used by:977 995
Symbol 975 TextUses:860Used by:977 995
Symbol 976 TextUses:860Used by:977
Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173}Uses:907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 939 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976Used by:Timeline
Symbol 978 TextUses:136Used by:Timeline
Symbol 979 EditableTextUses:138Used by:995
Symbol 980 EditableTextUses:138Used by:995
Symbol 981 EditableTextUses:138Used by:995
Symbol 982 EditableTextUses:138Used by:995
Symbol 983 EditableTextUses:138Used by:995
Symbol 984 EditableTextUses:138Used by:995
Symbol 985 EditableTextUses:138Used by:995
Symbol 986 EditableTextUses:138Used by:995
Symbol 987 EditableTextUses:138Used by:995
Symbol 988 EditableTextUses:138Used by:995
Symbol 989 EditableTextUses:138Used by:995
Symbol 990 EditableTextUses:138Used by:995
Symbol 991 EditableTextUses:138Used by:995
Symbol 992 EditableTextUses:138Used by:995
Symbol 993 EditableTextUses:138Used by:995
Symbol 994 EditableTextUses:138Used by:995
Symbol 995 MovieClip {windkingdom_armor_fla.result_174}Uses:907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 939 994 962 963 964 965 966 967 968 969 970 971 972 973 974 975Used by:Timeline
Symbol 996 TextUses:136Used by:Timeline
Symbol 997 TextUses:147Used by:Timeline
Symbol 998 GraphicUsed by:Timeline
Symbol 999 GraphicUses:730Used by:Timeline
Symbol 1000 TextUses:138 136Used by:Timeline

Instance Names

"armorbtn"Frame 1Symbol 100 Button
"artbtn"Frame 1Symbol 102 MovieClip
"adsbtn"Frame 1Symbol 133 MovieClip {windkingdom_armor_fla.armor_promo_3}
"adBox"Frame 1Symbol 135 MovieClip
"mcpreloader"Frame 1Symbol 146 MovieClip {windkingdom_armor_fla.mcpreloaderBar_10}
"playbtn"Frame 2Symbol 150 Button
"mc_armor"Frame 3Symbol 630 MovieClip {windkingdom_armor_fla.ag_intro_mc_115}
"btloadgame"Frame 6Symbol 639 Button
"btplay"Frame 6Symbol 642 Button
"btaddgame"Frame 6Symbol 645 Button
"btplaymore"Frame 6Symbol 648 Button
"btcredit"Frame 6Symbol 651 Button
"btarmor"Frame 6Symbol 654 Button
"instructionnote"Frame 14Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126}
"btcancel"Frame 14Symbol 729 Button
"btday1"Frame 24Symbol 738 Button
"btday2"Frame 24Symbol 740 Button
"btday3"Frame 24Symbol 742 Button
"btday4"Frame 24Symbol 744 Button
"btday5"Frame 24Symbol 746 Button
"btday6"Frame 24Symbol 748 Button
"btday7"Frame 24Symbol 750 Button
"btday8"Frame 24Symbol 752 Button
"btplay"Frame 24Symbol 755 Button
"btloadgame"Frame 24Symbol 758 Button
"btsavegame"Frame 24Symbol 761 Button
"btplaymore"Frame 24Symbol 764 Button
"btupgrade"Frame 24Symbol 767 Button
"btstatistics"Frame 24Symbol 770 Button
"btinstructions"Frame 24Symbol 773 Button
"levelnote"Frame 24Symbol 791 MovieClip
"btmainmenu"Frame 24Symbol 794 Button
"tutorial_mc"Frame 24Symbol 797 MovieClip {windkingdom_armor_fla.mc_tutorialskills_151}
"btcancel"Frame 34Symbol 729 Button
"ep"Frame 64Symbol 806 EditableText
"upgradewarning"Frame 64Symbol 812 MovieClip {windkingdom_armor_fla.upgradewarning_152}
"btupgradecastle"Frame 64Symbol 823 MovieClip {windkingdom_armor_fla.btupgradecastle_155}
"btupgraderider"Frame 64Symbol 825 MovieClip {windkingdom_armor_fla.btupgraderider_157}
"btupgradecopter"Frame 64Symbol 827 MovieClip {windkingdom_armor_fla.btupgradecopter_158}
"btupgradeeagle"Frame 64Symbol 829 MovieClip {windkingdom_armor_fla.btupgradeeagle_159}
"btupgradepanzer"Frame 64Symbol 832 MovieClip {windkingdom_armor_fla.btupgradepanzer_160}
"btupgradedragon"Frame 64Symbol 834 MovieClip {windkingdom_armor_fla.btupgradedragon_161}
"btupgradeiceturret"Frame 64Symbol 837 MovieClip {windkingdom_armor_fla.btupgradeiceturret_162}
"btupgradefireturret"Frame 64Symbol 840 MovieClip {windkingdom_armor_fla.btupgradefireturret_163}
"btupgradethunderturret"Frame 64Symbol 843 MovieClip {windkingdom_armor_fla.btupgradethunderturret_164}
"btupgradeunitcreatetime"Frame 64Symbol 850 MovieClip {windkingdom_armor_fla.btupgradeunitcreatetime_165}
"btupgradeturretcreatetime"Frame 64Symbol 852 MovieClip {windkingdom_armor_fla.btupgradeturretcreatetime_166}
"btupgrademanaregeneratetime"Frame 64Symbol 855 MovieClip {windkingdom_armor_fla.btupgrademanaregeneratetime_167}
"btupgradeinitialmanabank"Frame 64Symbol 857 MovieClip {windkingdom_armor_fla.btupgradeinitialmanabank_168}
"panelnote"Frame 64Symbol 889 MovieClip {windkingdom_armor_fla.panelnote_169}
"btcancel"Frame 74Symbol 894 Button
"txt1"Frame 74Symbol 896 EditableText
"txt2"Frame 74Symbol 897 EditableText
"txt3"Frame 74Symbol 898 EditableText
"txt4"Frame 74Symbol 899 EditableText
"txt5"Frame 74Symbol 900 EditableText
"txt6"Frame 74Symbol 901 EditableText
"txt7"Frame 74Symbol 902 EditableText
"txt8"Frame 74Symbol 903 EditableText
"txt9"Frame 74Symbol 904 EditableText
"btcancel"Frame 94Symbol 729 Button
"result"Frame 94Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171}
"btcancel"Frame 104Symbol 945 Button
"result"Frame 104Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173}
"result"Frame 114Symbol 995 MovieClip {windkingdom_armor_fla.result_174}
"btcancel"Frame 114Symbol 729 Button
"btyes"Symbol 9 MovieClip {panelconfirm} Frame 1Symbol 5 Button
"btcancel"Symbol 9 MovieClip {panelconfirm} Frame 1Symbol 8 Button {btno}
"mana"Symbol 55 MovieClip {mc_levelnote} Frame 1Symbol 38 EditableText
"btcreateturret2"Symbol 75 MovieClip {mc_turretlayer} Frame 1Symbol 74 Button
"btcreateturret1"Symbol 75 MovieClip {mc_turretlayer} Frame 1Symbol 74 Button
"btcreateturret4"Symbol 75 MovieClip {mc_turretlayer} Frame 1Symbol 74 Button
"btcreateturret3"Symbol 75 MovieClip {mc_turretlayer} Frame 1Symbol 74 Button
"c1"Symbol 253 MovieClip {windkingdom_armor_fla.lv1_22} Frame 1Symbol 231 MovieClip
"c2"Symbol 253 MovieClip {windkingdom_armor_fla.lv1_22} Frame 1Symbol 231 MovieClip
"c1"Symbol 264 MovieClip {windkingdom_armor_fla.lv2_31} Frame 1Symbol 231 MovieClip
"c2"Symbol 264 MovieClip {windkingdom_armor_fla.lv2_31} Frame 1Symbol 231 MovieClip
"c3"Symbol 264 MovieClip {windkingdom_armor_fla.lv2_31} Frame 1Symbol 231 MovieClip
"c1"Symbol 270 MovieClip {windkingdom_armor_fla.lv3_33} Frame 1Symbol 231 MovieClip
"c2"Symbol 270 MovieClip {windkingdom_armor_fla.lv3_33} Frame 1Symbol 231 MovieClip
"c3"Symbol 270 MovieClip {windkingdom_armor_fla.lv3_33} Frame 1Symbol 231 MovieClip
"c4"Symbol 270 MovieClip {windkingdom_armor_fla.lv3_33} Frame 1Symbol 231 MovieClip
"c5"Symbol 270 MovieClip {windkingdom_armor_fla.lv3_33} Frame 1Symbol 231 MovieClip
"castle"Symbol 274 MovieClip {mc_castle} Frame 1Symbol 253 MovieClip {windkingdom_armor_fla.lv1_22}
"d1"Symbol 274 MovieClip {mc_castle} Frame 1Symbol 255 MovieClip
"repairer"Symbol 274 MovieClip {mc_castle} Frame 1Symbol 258 MovieClip
"castle"Symbol 274 MovieClip {mc_castle} Frame 2Symbol 264 MovieClip {windkingdom_armor_fla.lv2_31}
"castle"Symbol 274 MovieClip {mc_castle} Frame 3Symbol 270 MovieClip {windkingdom_armor_fla.lv3_33}
"powermeter"Symbol 451 MovieClip {windkingdom_armor_fla.iconspecialattack_68} Frame 1Symbol 450 MovieClip
"txt1"Symbol 533 MovieClip {windkingdom_armor_fla.rightnote_89} Frame 1Symbol 529 EditableText
"txt2"Symbol 533 MovieClip {windkingdom_armor_fla.rightnote_89} Frame 1Symbol 530 EditableText
"txt3"Symbol 533 MovieClip {windkingdom_armor_fla.rightnote_89} Frame 1Symbol 531 EditableText
"iconspecialattack"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 451 MovieClip {windkingdom_armor_fla.iconspecialattack_68}
"iconrider"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 456 MovieClip
"iconcopter"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 461 MovieClip
"iconeagle"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 466 MovieClip
"iconpanzer"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 471 MovieClip
"icondragon"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 476 MovieClip
"iconiceturret"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 481 MovieClip
"iconfireturret"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 486 MovieClip
"iconthunderturret"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 491 MovieClip
"iconupgraderange"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 496 MovieClip
"iconupgradehealth"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 499 MovieClip
"iconupgradepower"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 502 MovieClip
"iconupgradeattack"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 505 MovieClip
"iconupgradedefense"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 508 MovieClip
"iconrepair"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 511 MovieClip
"iconheal"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 514 MovieClip
"iconupgrademana"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 517 MovieClip
"btquitlevel"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 520 Button
"btplaymore"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 523 Button
"btoption"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 526 Button
"rightnote"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 533 MovieClip {windkingdom_armor_fla.rightnote_89}
"rightnote2"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 533 MovieClip {windkingdom_armor_fla.rightnote_89}
"manalevel"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 536 MovieClip {windkingdom_armor_fla.health_90}
"healthlevel"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 536 MovieClip {windkingdom_armor_fla.health_90}
"progresslevel"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 536 MovieClip {windkingdom_armor_fla.health_90}
"leftbalancelevel"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 539 MovieClip
"rightbalancelevel"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 539 MovieClip
"note"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 542 EditableText
"queue1"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 553 MovieClip
"queue2"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 553 MovieClip
"queue3"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 553 MovieClip
"queue4"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 553 MovieClip
"queue5"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 553 MovieClip
"queue6"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 553 MovieClip
"manapoint"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 555 EditableText
"gameshadow"Symbol 562 MovieClip {mc_levelpanel} Frame 1Symbol 561 MovieClip
"upscroller"Symbol 572 MovieClip {mc_scroller} Frame 1Symbol 567 Button
"btcreateunitright"Symbol 572 MovieClip {mc_scroller} Frame 1Symbol 74 Button
"btcreateunitleft"Symbol 572 MovieClip {mc_scroller} Frame 1Symbol 74 Button
"downscroller"Symbol 572 MovieClip {mc_scroller} Frame 1Symbol 571 Button
"btplaymore"Symbol 598 MovieClip {paneloption} Frame 1Symbol 591 MovieClip
"btquitlevel"Symbol 598 MovieClip {paneloption} Frame 1Symbol 594 MovieClip
"btresumegame"Symbol 598 MovieClip {paneloption} Frame 1Symbol 597 MovieClip
"sfxvol"Symbol 598 MovieClip {paneloption} Frame 1Symbol 95 MovieClip {fl.controls.Slider}
"bgmvol"Symbol 598 MovieClip {paneloption} Frame 1Symbol 95 MovieClip {fl.controls.Slider}
"quality"Symbol 598 MovieClip {paneloption} Frame 1Symbol 95 MovieClip {fl.controls.Slider}
"btshortcuts"Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126} Frame 1Symbol 672 Button
"btunits"Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126} Frame 1Symbol 676 Button
"btexp"Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126} Frame 1Symbol 680 Button
"btbattle"Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126} Frame 1Symbol 684 Button
"btupgrade"Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126} Frame 1Symbol 688 Button
"btgameplay"Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126} Frame 1Symbol 692 Button
"locker"Symbol 823 MovieClip {windkingdom_armor_fla.btupgradecastle_155} Frame 1Symbol 817 MovieClip
"locker"Symbol 825 MovieClip {windkingdom_armor_fla.btupgraderider_157} Frame 1Symbol 817 MovieClip
"locker"Symbol 827 MovieClip {windkingdom_armor_fla.btupgradecopter_158} Frame 1Symbol 817 MovieClip
"locker"Symbol 829 MovieClip {windkingdom_armor_fla.btupgradeeagle_159} Frame 1Symbol 817 MovieClip
"locker"Symbol 832 MovieClip {windkingdom_armor_fla.btupgradepanzer_160} Frame 1Symbol 817 MovieClip
"locker"Symbol 834 MovieClip {windkingdom_armor_fla.btupgradedragon_161} Frame 1Symbol 817 MovieClip
"locker"Symbol 837 MovieClip {windkingdom_armor_fla.btupgradeiceturret_162} Frame 1Symbol 817 MovieClip
"locker"Symbol 840 MovieClip {windkingdom_armor_fla.btupgradefireturret_163} Frame 1Symbol 817 MovieClip
"locker"Symbol 843 MovieClip {windkingdom_armor_fla.btupgradethunderturret_164} Frame 1Symbol 817 MovieClip
"locker"Symbol 850 MovieClip {windkingdom_armor_fla.btupgradeunitcreatetime_165} Frame 1Symbol 817 MovieClip
"locker"Symbol 852 MovieClip {windkingdom_armor_fla.btupgradeturretcreatetime_166} Frame 1Symbol 817 MovieClip
"locker"Symbol 855 MovieClip {windkingdom_armor_fla.btupgrademanaregeneratetime_167} Frame 1Symbol 817 MovieClip
"locker"Symbol 857 MovieClip {windkingdom_armor_fla.btupgradeinitialmanabank_168} Frame 1Symbol 817 MovieClip
"ep"Symbol 889 MovieClip {windkingdom_armor_fla.panelnote_169} Frame 1Symbol 861 EditableText
"txt1"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 924 EditableText
"txt2"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 925 EditableText
"txt3"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 926 EditableText
"txt4"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 927 EditableText
"txt6"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 928 EditableText
"txt5"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 929 EditableText
"txt7"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 930 EditableText
"txt8"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 931 EditableText
"txt9"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 932 EditableText
"txt10"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 933 EditableText
"txt11"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 934 EditableText
"txt12"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 935 EditableText
"txt14"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 936 EditableText
"txt13"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 937 EditableText
"txt15"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 938 EditableText
"txt16"Symbol 941 MovieClip {windkingdom_armor_fla.result_quit_171} Frame 1Symbol 940 EditableText
"txt1"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 946 EditableText
"txt2"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 947 EditableText
"txt3"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 948 EditableText
"txt4"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 949 EditableText
"txt6"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 950 EditableText
"txt5"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 951 EditableText
"txt7"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 952 EditableText
"txt8"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 953 EditableText
"txt9"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 954 EditableText
"txt10"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 955 EditableText
"txt11"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 956 EditableText
"txt12"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 957 EditableText
"txt14"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 958 EditableText
"txt13"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 959 EditableText
"txt15"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 960 EditableText
"txt16"Symbol 977 MovieClip {windkingdom_armor_fla.result_loose_173} Frame 1Symbol 961 EditableText
"txt1"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 979 EditableText
"txt2"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 980 EditableText
"txt3"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 981 EditableText
"txt4"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 982 EditableText
"txt6"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 983 EditableText
"txt5"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 984 EditableText
"txt7"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 985 EditableText
"txt8"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 986 EditableText
"txt9"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 987 EditableText
"txt10"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 988 EditableText
"txt11"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 989 EditableText
"txt12"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 990 EditableText
"txt14"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 991 EditableText
"txt13"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 992 EditableText
"txt15"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 993 EditableText
"txt16"Symbol 995 MovieClip {windkingdom_armor_fla.result_174} Frame 1Symbol 994 EditableText

Special Tags

FileAttributes (69)Timeline Frame 1Access network only, Metadata not present, AS3.

Labels

"locked"Frame 4
"leveljumper"Frame 8
"menuselect"Frame 10
"instructions"Frame 14
"levelselect"Frame 24
"savegame"Frame 34
"loadgame"Frame 44
"unloadgame"Frame 54
"upgrade"Frame 64
"statistics"Frame 74
"gameplay"Frame 84
"playerquit"Frame 94
"playerloose"Frame 104
"playerwin"Frame 114
"ultimatewin"Frame 124
"credits"Frame 135
"destroyed"Symbol 159 MovieClip {mc_bigbat} Frame 17
"attack"Symbol 176 MovieClip {mc_blackknight} Frame 17
"destroyed"Symbol 176 MovieClip {mc_blackknight} Frame 33
"facedown"Symbol 185 MovieClip {mc_evilcopter} Frame 1
"faceup"Symbol 185 MovieClip {mc_evilcopter} Frame 9
"destroyed"Symbol 185 MovieClip {mc_evilcopter} Frame 17
"facedown"Symbol 198 MovieClip {mc_evildragon} Frame 1
"faceup"Symbol 198 MovieClip {mc_evildragon} Frame 17
"destroyed"Symbol 198 MovieClip {mc_evildragon} Frame 33
"facedown"Symbol 203 MovieClip {mc_evilpanzer} Frame 1
"faceup"Symbol 203 MovieClip {mc_evilpanzer} Frame 9
"destroyed"Symbol 203 MovieClip {mc_evilpanzer} Frame 17
"facedown"Symbol 216 MovieClip {mc_evilultimate} Frame 1
"faceup"Symbol 216 MovieClip {mc_evilultimate} Frame 17
"destroyed"Symbol 216 MovieClip {mc_evilultimate} Frame 33
"destroyed"Symbol 223 MovieClip {mc_smallbat} Frame 17
"destroy"Symbol 253 MovieClip {windkingdom_armor_fla.lv1_22} Frame 2
"destroy"Symbol 264 MovieClip {windkingdom_armor_fla.lv2_31} Frame 2
"destroy"Symbol 270 MovieClip {windkingdom_armor_fla.lv3_33} Frame 2
"destroy"Symbol 271 MovieClip Frame 1
"destroy"Symbol 272 MovieClip Frame 1
"destroy"Symbol 273 MovieClip Frame 1
"destroyed"Symbol 314 MovieClip {mc_cannonbullet} Frame 61
"destroyed"Symbol 317 MovieClip {mc_firebullet} Frame 61
"destroyed"Symbol 320 MovieClip {mc_frozenbullet} Frame 61
"destroyed"Symbol 323 MovieClip {mc_icebullet} Frame 61
"destroyed"Symbol 335 MovieClip {mc_fireturret} Frame 2
"destroyed"Symbol 339 MovieClip {mc_iceturret} Frame 2
"destroyed"Symbol 343 MovieClip {mc_thunderturret} Frame 2
"facedown"Symbol 352 MovieClip {mc_copter} Frame 1
"faceup"Symbol 352 MovieClip {mc_copter} Frame 9
"destroyed"Symbol 352 MovieClip {mc_copter} Frame 17
"facedown"Symbol 365 MovieClip {mc_dragon} Frame 1
"faceup"Symbol 365 MovieClip {mc_dragon} Frame 17
"destroyed"Symbol 365 MovieClip {mc_dragon} Frame 33
"facedown"Symbol 378 MovieClip {mc_eagle} Frame 1
"faceup"Symbol 378 MovieClip {mc_eagle} Frame 17
"destroyed"Symbol 378 MovieClip {mc_eagle} Frame 33
"facedown"Symbol 383 MovieClip {mc_panzer} Frame 1
"faceup"Symbol 383 MovieClip {mc_panzer} Frame 9
"destroyed"Symbol 383 MovieClip {mc_panzer} Frame 17
"facedown"Symbol 388 MovieClip {mc_rider} Frame 1
"faceup"Symbol 388 MovieClip {mc_rider} Frame 9
"destroyed"Symbol 388 MovieClip {mc_rider} Frame 17
"gameplay"Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126} Frame 1
"shortcuts"Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126} Frame 11
"units"Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126} Frame 21
"exp"Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126} Frame 31
"battle"Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126} Frame 41
"upgrade"Symbol 724 MovieClip {windkingdom_armor_fla.instructionnotes_126} Frame 51
"insufficient"Symbol 812 MovieClip {windkingdom_armor_fla.upgradewarning_152} Frame 2
"maximum"Symbol 812 MovieClip {windkingdom_armor_fla.upgradewarning_152} Frame 31




http://swfchan.com/10/46480/info.shtml
Created: 3/5 -2019 14:29:37 Last modified: 3/5 -2019 14:29:37 Server time: 17/05 -2024 12:10:02