Frame 1
_accProps = new Object();
_accProps.silent = true;
_root.mysize = _root.getBytesLoaded();
_root.myspeed = int(((int(_root.mysize) - int(_root.oldsize)) * 15) / 1000);
_root.oldsize = int(_root.mysize);
_root.percent = int((_root.getBytesLoaded() / _root.getBytesTotal()) * 1000);
_root.percent = _root.percent / 10;
_root.lightval = int(int(_root.percent) / 5);
if (_root["block" + _root.lightval]._currentframe == 1) {
_root["block" + _root.lightval].gotoAndPlay("alive");
i = 0;
while (i <= _root.lightval) {
if (_root["block" + i]._currentframe == 1) {
_root["block" + i].gotoAndPlay("alive");
}
i++;
}
}
Frame 2
if (_root.getBytesTotal() != _root.getBytesLoaded()) {
gotoAndPlay (1);
}
_root.hit = _root.hit + 1;
if (_root.hit >= 100) {
_root.hit = 0;
var randomTalk = random(30);
switch (randomTalk) {
case 1 :
pettalk.text = "I'm not really the star of the game... *sigh*";
break;
case 2 :
pettalk.text = "Hey there, how ya doing? I'm gonna bug you while it loads!";
break;
case 3 :
pettalk.text = "Wanna hear a joke? Neither do I...";
break;
case 4 :
pettalk.text = ("Well we're nearly done you've got about " + _root.percent) + "% downloaded";
break;
case 5 :
pettalk.text = "Okay... Okay... wait for it! ... ... ah that's better ;)";
break;
case 6 :
pettalk.text = "Boo! - Scared ya!";
break;
case 7 :
pettalk.text = "... You think I like this job?";
break;
case 8 :
pettalk.text = "I'm not gay... but try me!";
break;
case 9 :
pettalk.text = "I am a little blob, lalala";
break;
case 10 :
pettalk.text = "Hey, that Leuitanent Maya is pretty hot... raaaorrar!";
break;
case 11 :
pettalk.text = "I hear it's possible to see Maya topless in this game...";
break;
case 12 :
pettalk.text = "Come visit me in the minigames section, you can wipe my butt";
break;
case 13 :
pettalk.text = "Have you seen Lord Of The Rings? Good for you...";
break;
case 14 :
pettalk.text = "I thought Starwars Episode 3 was rubbish... so STFU noob!";
break;
case 15 :
pettalk.text = "I play Call Of Duty... I'm a member of Junk52... serious!";
break;
case 16 :
pettalk.text = "On the weekends I write romantic novels.";
break;
case 17 :
pettalk.text = "You think my lipstick suits me? I wasn't sure about the shade.";
break;
case 18 :
pettalk.text = "Are you getting fed up of me yet?";
break;
case 19 :
pettalk.text = "Am I a boy or a girl? You decide.";
break;
case 20 :
pettalk.text = "I enjoy a nice piece of cheese on the odd occaision";
break;
case 21 :
pettalk.text = "It seems to me, you've lived your life... like a candle in the wind";
break;
case 22 :
pettalk.text = "This game took about 40 litres of Coca-Cola to make...";
break;
case 23 :
pettalk.text = "Oh.. Oh... Where are my keys? WHERE ARE MY KEYS";
break;
case 24 :
pettalk.text = "*sigh* Your connection is slower than my grandads Nissan";
break;
case 25 :
pettalk.text = "I thought Batman was pretty good, he looks hot.";
break;
case 26 :
pettalk.text = "Dum Dum Dum-Dum PAT BUTCHER!";
break;
case 27 :
pettalk.text = "I need a drink...";
break;
case 28 :
pettalk.text = ("We're gonna be waiting for ages, you only have " + _root.percent) + "%";
break;
case 30 :
pettalk.text = "This game may contain traces of nuts";
break;
case 29 :
pettalk.text = "I like chicken I like liver, miaow-mix miaow-mix please de-liver!";
}
}
Frame 10
stopAllSounds();
_root.sfx_vol = 0;
_root.music_vol = 0;
Frame 11
stopAllSounds();
Instance of Symbol 324 MovieClip "campaign" in Frame 11
on (press) {
if (_root.resume._currentframe == 29) {
_root.start.gotoAndPlay("on");
_root.resume.gotoAndPlay("on");
_root.back.gotoAndPlay("on");
_root.achievements.gotoAndPlay("close");
_root.options.gotoAndPlay("close");
_root.premade.gotoAndPlay("close");
_root.editor.gotoAndPlay("close");
_root.campaign.gotoAndPlay("close");
_root.skirmish.gotoAndPlay("close");
_root.player.gotoAndPlay("close");
}
}
Frame 12
stopAllSounds();
Frame 13
stopAllSounds();
Frame 14
stopAllSounds();
Frame 15
stopAllSounds();
stopAllSounds();
Frame 16
stopAllSounds();
Frame 17
stopAllSounds();
Frame 18
stopAllSounds();
Frame 19
stopAllSounds();
Frame 20
stopAllSounds();
stopAllSounds();
Frame 21
stopAllSounds();
Frame 22
stopAllSounds();
Frame 23
stopAllSounds();
Frame 24
stopAllSounds();
Frame 25
stopAllSounds();
stopAllSounds();
Frame 26
stopAllSounds();
Frame 27
stopAllSounds();
Frame 28
stopAllSounds();
Frame 29
stopAllSounds();
Frame 30
stopAllSounds();
stopAllSounds();
Frame 31
var myGameData = SharedObject.getLocal("myGameData");
Frame 34
var mission = 0;
var music_vol = 70;
var sfx_vol = 100;
var fastmove = false;
stop();
Frame 35
Mouse.show();
stopAllSounds();
_root.int_victory.removeMovieClip();
_root.advisor.removeMovieClip();
_root.interface_mc.removeMovieClip();
_root.int_spin.removeMovieClip();
_root.reset();
campaign.onRollOver = function () {
campaign.gotoAndPlay("over");
};
skirmish.onRollOver = function () {
skirmish.gotoAndPlay("over");
};
player.onRollOver = function () {
player.gotoAndPlay("over");
};
start.onRollOver = function () {
_root.setskirmish = false;
start.gotoAndPlay("over");
};
resume.onRollOver = function () {
_root.setskirmish = false;
resume.gotoAndPlay("over");
};
premade.onRollOver = function () {
premade.gotoAndPlay("over");
};
editor.onRollOver = function () {
editor.gotoAndPlay("over");
};
achievements.onRollOver = function () {
achievements.gotoAndPlay("over");
};
options.onRollOver = function () {
options.gotoAndPlay("over");
};
campaign.onRollOut = function () {
campaign.gotoAndPlay("out");
};
skirmish.onRollOut = function () {
skirmish.gotoAndPlay("out");
};
player.onRollOut = function () {
player.gotoAndPlay("out");
};
start.onRollOut = function () {
start.gotoAndPlay("out");
};
resume.onRollOut = function () {
resume.gotoAndPlay("out");
};
premade.onRollOut = function () {
premade.gotoAndPlay("out");
};
editor.onRollOut = function () {
editor.gotoAndPlay("out");
};
achievements.onRollOut = function () {
achievements.gotoAndPlay("out");
};
options.onRollOut = function () {
options.gotoAndPlay("out");
};
back.onRollOut = function () {
back.gotoAndPlay("out");
};
back.onRollOver = function () {
back.gotoAndPlay("over");
};
start.onPress = function () {
gotoAndPlay ("new");
int_options.removeMovieClip();
};
resume.onPress = function () {
gotoAndPlay ("load");
int_options.removeMovieClip();
};
editor.onPress = function () {
gotoAndPlay ("maped");
int_options.removeMovieClip();
};
premade.onPress = function () {
gotoAndPlay ("skirmish");
int_options.removeMovieClip();
};
achievements.onPress = function () {
gotoAndPlay ("awards");
int_options.removeMovieClip();
};
options.onPress = function () {
_root.attachMovie("int_options", "int_options", 2999);
};
_root.start.gotoAndStop(29);
_root.resume.gotoAndStop(29);
_root.premade.gotoAndStop(29);
_root.editor.gotoAndStop(29);
_root.achievements.gotoAndStop(29);
_root.options.gotoAndStop(29);
_root.back.gotoAndStop(29);
Instance of Symbol 324 MovieClip "player" in Frame 35
on (press) {
if (_root.options._currentframe == 29) {
_root.start.gotoAndPlay("close");
_root.resume.gotoAndPlay("close");
_root.back.gotoAndPlay("on");
_root.achievements.gotoAndPlay("on");
_root.options.gotoAndPlay("on");
_root.premade.gotoAndPlay("close");
_root.editor.gotoAndPlay("close");
_root.campaign.gotoAndPlay("close");
_root.skirmish.gotoAndPlay("close");
_root.player.gotoAndPlay("close");
}
}
Instance of Symbol 324 MovieClip "skirmish" in Frame 35
on (press) {
if (_root.premade._currentframe == 29) {
_root.start.gotoAndPlay("close");
_root.resume.gotoAndPlay("close");
_root.back.gotoAndPlay("on");
_root.achievements.gotoAndPlay("close");
_root.options.gotoAndPlay("close");
_root.premade.gotoAndPlay("on");
_root.editor.gotoAndPlay("on");
_root.campaign.gotoAndPlay("close");
_root.skirmish.gotoAndPlay("close");
_root.player.gotoAndPlay("close");
}
}
Instance of Symbol 324 MovieClip "campaign" in Frame 35
on (press) {
if (_root.resume._currentframe == 29) {
if (_root.myGameData.data.playername != undefined) {
_root.warning.gotoAndPlay("on");
}
_root.start.gotoAndPlay("on");
_root.resume.gotoAndPlay("on");
_root.back.gotoAndPlay("on");
_root.achievements.gotoAndPlay("close");
_root.options.gotoAndPlay("close");
_root.premade.gotoAndPlay("close");
_root.editor.gotoAndPlay("close");
_root.campaign.gotoAndPlay("close");
_root.skirmish.gotoAndPlay("close");
_root.player.gotoAndPlay("close");
}
}
Instance of Symbol 324 MovieClip "back" in Frame 35
on (press) {
if (_root.campaign._currentframe == 29) {
if (_root.myGameData.data.playername != undefined) {
_root.warning.gotoAndPlay("close");
}
int_options.removeMovieClip();
_root.start.gotoAndPlay("close");
_root.resume.gotoAndPlay("close");
_root.back.gotoAndPlay("close");
_root.achievements.gotoAndPlay("close");
_root.options.gotoAndPlay("close");
_root.premade.gotoAndPlay("close");
_root.editor.gotoAndPlay("close");
_root.campaign.gotoAndPlay("on");
_root.skirmish.gotoAndPlay("on");
_root.player.gotoAndPlay("on");
}
}
Frame 36
_root.bgm = new Sound();
_root.bgm.attachSound("titlebgm");
_root.bgm.setVolume(_root.music_vol);
_root.bgm.start(0, 999);
Frame 37
stop();
Frame 38
var myGameData = SharedObject.getLocal("myGameData");
_root.mission = int(myGameData.data.mission);
_root.multiplayer = false;
stopAllSounds();
_root.gotoAndPlay("init");
Frame 39
var myGameData = SharedObject.getLocal("myGameData");
stopAllSounds();
_root.mission = 0;
for (var i in myGameData.data) {
delete myGameData.data[i];
}
myGameData.flush();
var stat_player_built = 0;
var stat_player_lost = 0;
var stat_player_cash = 0;
var stat_player_time = 0;
var stat_player_captured = 0;
var stat_player_turns = 0;
var tstat_player_built = 0;
var tstat_player_lost = 0;
var tstat_player_cash = 0;
var tstat_player_time = 0;
var tstat_player_captured = 0;
var tstat_player_turns = 0;
var tstat_com_built = 0;
var tstat_com_lost = 0;
var tstat_com_cash = 0;
var tstat_com_captured = 0;
accept.onRollOut = function () {
accept.gotoAndPlay("out");
};
accept.onRollOver = function () {
accept.gotoAndPlay("over");
};
accept.onPress = function () {
myGameData.data.playername = _root.playername;
myGameData.flush();
_root.gotoAndPlay("init");
};
listenForKey_obj = new Object();
listenForKey_obj.onKeyDown = function () {
var _local1 = new Sound();
_local1.attachSound("key");
_local1.start(0, 1);
};
Key.addListener(listenForKey_obj);
stop();
Instance of Symbol 324 MovieClip "accept" in Frame 39
on (press) {
if (_root.resume._currentframe == 29) {
if (_root.myGameData.data.stat_player_time != undefined) {
_root.warning.gotoAndPlay("on");
}
_root.start.gotoAndPlay("on");
_root.resume.gotoAndPlay("on");
_root.back.gotoAndPlay("on");
_root.achievements.gotoAndPlay("close");
_root.options.gotoAndPlay("close");
_root.premade.gotoAndPlay("close");
_root.editor.gotoAndPlay("close");
_root.campaign.gotoAndPlay("close");
_root.skirmish.gotoAndPlay("close");
_root.player.gotoAndPlay("close");
}
}
Frame 40
location01.onRollOver = function () {
location01.gotoAndPlay("over");
};
location01.onRollOut = function () {
location01.gotoAndPlay("out");
};
location02.onRollOver = function () {
location02.gotoAndPlay("over");
};
location02.onRollOut = function () {
location02.gotoAndPlay("out");
};
location03.onRollOver = function () {
location03.gotoAndPlay("over");
};
location03.onRollOut = function () {
location03.gotoAndPlay("out");
};
location04.onRollOver = function () {
location04.gotoAndPlay("over");
};
location04.onRollOut = function () {
location04.gotoAndPlay("out");
};
location05.onRollOver = function () {
location05.gotoAndPlay("over");
};
location05.onRollOut = function () {
location05.gotoAndPlay("out");
};
location06.onRollOver = function () {
location06.gotoAndPlay("over");
};
location06.onRollOut = function () {
location06.gotoAndPlay("out");
};
location07.onRollOver = function () {
location07.gotoAndPlay("over");
};
location07.onRollOut = function () {
location07.gotoAndPlay("out");
};
location08.onRollOver = function () {
location08.gotoAndPlay("over");
};
location08.onRollOut = function () {
location08.gotoAndPlay("out");
};
location09.onRollOver = function () {
location09.gotoAndPlay("over");
};
location09.onRollOut = function () {
location09.gotoAndPlay("out");
};
location10.onRollOver = function () {
location10.gotoAndPlay("over");
};
location10.onRollOut = function () {
location10.gotoAndPlay("out");
};
location11.onRollOver = function () {
location11.gotoAndPlay("over");
};
location11.onRollOut = function () {
location11.gotoAndPlay("out");
};
location12.onRollOver = function () {
location12.gotoAndPlay("over");
};
location12.onRollOut = function () {
location12.gotoAndPlay("out");
};
mainmenu.onRollOver = function () {
mainmenu.gotoAndPlay("over");
};
mainmenu.onRollOut = function () {
mainmenu.gotoAndPlay("out");
};
_root.play.onRollOver = function () {
play.gotoAndPlay("over");
};
_root.play.onRollOut = function () {
play.gotoAndPlay("out");
};
_root.fog.onRollOver = function () {
fog.gotoAndPlay("over");
};
_root.fog.onRollOut = function () {
fog.gotoAndPlay("out");
};
stop();
Instance of Symbol 324 MovieClip "libertypet" in Frame 40
on (press) {
_root.gotoAndPlay("pet");
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "libertywhack" in Frame 40
on (press) {
_root.gotoAndPlay("whack");
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "libertyraces" in Frame 40
on (press) {
_root.gotoAndPlay("races");
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission19" in Frame 40
on (press) {
_root.mission = 18;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission18" in Frame 40
on (press) {
_root.mission = 17;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission17" in Frame 40
on (press) {
_root.mission = 16;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission16" in Frame 40
on (press) {
_root.mission = 15;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission15" in Frame 40
on (press) {
_root.mission = 14;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission14" in Frame 40
on (press) {
_root.mission = 13;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission13" in Frame 40
on (press) {
_root.mission = 12;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission12" in Frame 40
on (press) {
_root.mission = 11;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission11" in Frame 40
on (press) {
_root.mission = 10;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission07" in Frame 40
on (press) {
_root.mission = 6;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission09" in Frame 40
on (press) {
_root.mission = 8;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission08" in Frame 40
on (press) {
_root.mission = 7;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission04" in Frame 40
on (press) {
_root.mission = 3;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission06" in Frame 40
on (press) {
_root.mission = 5;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission05" in Frame 40
on (press) {
_root.mission = 4;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission01" in Frame 40
on (press) {
_root.mission = 0;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission10" in Frame 40
on (press) {
_root.mission = 9;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission03" in Frame 40
on (press) {
_root.mission = 2;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "mission02" in Frame 40
on (press) {
_root.mission = 1;
_root.sample.gotoAndStop(13);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "custom" in Frame 40
on (press) {
_root.mission = 99;
_root.sample.gotoAndStop(12);
_root.map.gotoAndStop(12);
_root.sample.mystatic.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "location11" in Frame 40
on (press) {
_root.mission = 41;
_root.sample.gotoAndStop(11);
_root.map.gotoAndStop(11);
_root.sample.mystatic.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "play" in Frame 40
on (press) {
if ((_root.mission < 20) && (_root.myGameData.data.gameComplete == true)) {
_root.setskirmish = true;
_root.gotoAndPlay("init");
}
if (_root.mission > 20) {
_root.setskirmish = true;
_root.gotoAndPlay("init");
}
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "location07" in Frame 40
on (press) {
_root.mission = 37;
_root.sample.gotoAndStop(7);
_root.map.gotoAndStop(7);
_root.sample.mystatic.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "location09" in Frame 40
on (press) {
_root.mission = 39;
_root.sample.gotoAndStop(9);
_root.map.gotoAndStop(9);
_root.sample.mystatic.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "location08" in Frame 40
on (press) {
_root.mission = 38;
_root.sample.gotoAndStop(8);
_root.map.gotoAndStop(8);
_root.sample.mystatic.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "location04" in Frame 40
on (press) {
_root.mission = 34;
_root.sample.gotoAndStop(4);
_root.map.gotoAndStop(4);
_root.sample.mystatic.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "location06" in Frame 40
on (press) {
_root.mission = 36;
_root.sample.gotoAndStop(6);
_root.map.gotoAndStop(6);
_root.sample.mystatic.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "location05" in Frame 40
on (press) {
_root.mission = 35;
_root.sample.gotoAndStop(5);
_root.map.gotoAndStop(5);
_root.sample.mystatic.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "location01" in Frame 40
on (press) {
_root.mission = 30;
_root.sample.gotoAndStop(1);
_root.map.gotoAndStop(1);
_root.sample.mystatic.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "mainmenu" in Frame 40
on (press) {
_root.gotoAndPlay("menu");
}
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
Instance of Symbol 324 MovieClip "location10" in Frame 40
on (press) {
_root.mission = 40;
_root.sample.gotoAndStop(10);
_root.map.gotoAndStop(10);
_root.sample.mystatic.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "location03" in Frame 40
on (press) {
_root.mission = 32;
_root.sample.gotoAndStop(3);
_root.map.gotoAndStop(3);
_root.sample.mystatic.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "location02" in Frame 40
on (press) {
_root.mission = 31;
_root.sample.gotoAndStop(2);
_root.map.gotoAndStop(2);
_root.sample.mystatic.gotoAndPlay(1);
}
Frame 41
stopAllSounds();
var day = 1;
var lock = false;
var phase = 0;
var date_start = new Date();
_root.multiplayer = false;
_root.int_victory.removeMovieClip();
_root.advisor.seq = 1;
_root.advisor.removeMovieClip();
if (_root.mission == 19) {
gotoAndPlay ("credits");
}
function placeUnits() {
if (_root.mission < 10) {
switch (int(_root.mission)) {
case 0 :
_root.fow = false;
_root.attachMovie("blue_infantry", "unit1", 2201, {_x:540, _y:360, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_infantry", "unit2", 2202, {_x:540, _y:300, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_infantry", "unit3", 2203, {_x:540, _y:330, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit50", 2250, {_x:30, _y:150, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit51", 2251, {_x:30, _y:120, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit52", 2252, {_x:30, _y:180, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
break;
case 1 :
_root.attachMovie("red_tank", "unit50", 2250, {_x:30, _y:150, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_tank", "unit51", 2251, {_x:30, _y:180, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_infantry", "unit53", 2253, {_x:60, _y:150, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit54", 2254, {_x:60, _y:210, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_aa", "unit9", 2209, {_x:60, _y:180, hp:100, team:1, unitType:"track", unitClass:"aa"});
_root.attachMovie("red_aa", "unit10", 2210, {_x:360, _y:180, hp:100, team:1, unitType:"track", unitClass:"aa"});
_root.attachMovie("albatross", "unit12", 2212, {_x:180, _y:90, hp:100, team:20, unitType:"wheel", unitClass:"albatross"});
_root.attachMovie("blue_truck", "unit11", 2211, {_x:240, _y:360, hp:100, team:0, unitClass:"truck", unitType:"wheel"});
_root.attachMovie("blue_infantry", "unit1", 2201, {_x:540, _y:330, hp:100, team:0, unitType:"foot"});
_root.attachMovie("blue_tank", "unit7", 2207, {_x:570, _y:300, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_tank", "unit8", 2208, {_x:570, _y:330, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_apc", "unit3", 2203, {_x:510, _y:270, hp:100, team:0, unitType:"track", unitClass:"apc"});
break;
case 2 :
_root.attachMovie("red_tank", "unit50", 2250, {_x:30, _y:330, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_tank", "unit51", 2251, {_x:30, _y:360, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_tank", "unit52", 2252, {_x:30, _y:300, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_tank", "unit53", 2253, {_x:60, _y:300, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_infantry", "unit54", 2254, {_x:60, _y:150, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_rocketinf", "unit4", 2204, {_x:540, _y:90, hp:100, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("blue_rocketinf", "unit5", 2205, {_x:570, _y:90, hp:100, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("blue_rocketinf", "unit1", 2201, {_x:570, _y:60, hp:100, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("blue_rocketinf", "unit2", 2202, {_x:540, _y:60, hp:100, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("blue_rocketinf", "unit3", 2203, {_x:510, _y:60, hp:100, team:0, unitType:"foot", unitClass:"rocket infantry"});
break;
case 3 :
_root.attachMovie("red_art", "unit50", 2250, {_x:360, _y:90, hp:100, team:1, unitType:"track", unitClass:"artillery", frozen:true});
_root.attachMovie("red_art", "unit51", 2251, {_x:510, _y:60, hp:100, team:1, unitType:"track", unitClass:"artillery", frozen:true});
_root.attachMovie("red_art", "unit52", 2252, {_x:360, _y:330, hp:100, team:1, unitType:"track", unitClass:"artillery", frozen:true});
_root.attachMovie("red_art", "unit53", 2253, {_x:240, _y:180, hp:100, team:1, unitType:"track", unitClass:"artillery", frozen:true});
_root.attachMovie("red_art", "unit54", 2254, {_x:120, _y:120, hp:100, team:1, unitType:"track", unitClass:"artillery", frozen:true});
_root.attachMovie("red_art", "unit55", 2255, {_x:0, _y:180, hp:100, team:1, unitType:"track", unitClass:"artillery", frozen:true});
_root.attachMovie("red_art", "unit56", 2256, {_x:0, _y:30, hp:100, team:1, unitType:"track", unitClass:"artillery", frozen:true});
_root.attachMovie("red_art", "unit57", 2257, {_x:60, _y:360, hp:100, team:1, unitType:"track", unitClass:"artillery", frozen:true});
_root.attachMovie("blue_tank", "unit1", 2201, {_x:570, _y:390, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_scout", "unit0", 2200, {_x:540, _y:360, team:0, unitType:"wheel", unitClass:"scout"});
_root.attachMovie("blue_scout", "unit5", 2205, {_x:540, _y:330, team:0, unitType:"wheel", unitClass:"scout"});
_root.attachMovie("blue_rocketinf", "unit2", 2202, {_x:570, _y:360, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("blue_rocketinf", "unit3", 2203, {_x:570, _y:330, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("blue_rocketinf", "unit4", 2204, {_x:570, _y:300, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.fow = true;
break;
case 4 :
_root.fow = false;
_root.cash = 5000;
_root.enemycash = 5000;
_root.t95.city_owner = 0;
_root.t95.gotoAndPlay(2);
_root.t97.city_owner = 0;
_root.t97.gotoAndPlay(2);
_root.t243.city_owner = 1;
_root.t243.gotoAndPlay(3);
_root.t201.city_owner = 1;
_root.t201.gotoAndPlay(3);
_root.fow = false;
break;
case 5 :
_root.attachMovie("stratofighter", "unit99", 2299, {_x:480, _y:180, hp:100, team:20, unitType:"wheel", unitClass:"albatross"});
_root.attachMovie("blue_infantry", "unit1", 2201, {_x:510, _y:180, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_infantry", "unit2", 2202, {_x:510, _y:150, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_infantry", "unit3", 2203, {_x:510, _y:210, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
break;
case 6 :
_root.fow = true;
_root.attachMovie("blue_infantry", "unit1", 2201, {_x:510, _y:120, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_infantry", "unit2", 2202, {_x:510, _y:150, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_rocketinf", "unit3", 2203, {_x:510, _y:180, hp:100, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("blue_tank", "unit4", 2204, {_x:510, _y:210, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_tank", "unit5", 2205, {_x:540, _y:120, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_tank", "unit6", 2206, {_x:540, _y:150, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_art", "unit7", 2207, {_x:540, _y:180, hp:100, team:0, unitType:"track", unitClass:"artillery"});
_root.attachMovie("blue_rocket", "unit8", 2208, {_x:540, _y:210, hp:100, team:0, unitType:"track", unitClass:"rocket"});
_root.attachMovie("blue_apc", "unit9", 2209, {_x:480, _y:150, hp:100, team:0, unitType:"track", unitClass:"apc"});
_root.attachMovie("blue_apc", "unit10", 2210, {_x:480, _y:180, hp:100, team:0, unitType:"track", unitClass:"apc"});
_root.attachMovie("red_infantry", "unit25", 2225, {_x:0, _y:210, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit26", 2226, {_x:0, _y:240, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_rocketinf", "unit27", 2227, {_x:0, _y:270, hp:100, team:1, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("red_tank", "unit28", 2228, {_x:0, _y:300, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_tank", "unit29", 2229, {_x:30, _y:210, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_tank", "unit30", 2230, {_x:30, _y:240, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_art", "unit31", 2231, {_x:30, _y:270, hp:100, team:1, unitType:"track", unitClass:"artillery"});
_root.attachMovie("red_rocket", "unit32", 2232, {_x:30, _y:180, hp:100, team:1, unitType:"track", unitClass:"rocket"});
_root.attachMovie("red_apc", "unit33", 2233, {_x:60, _y:210, hp:100, team:1, unitType:"track", unitClass:"apc"});
_root.attachMovie("red_apc", "unit34", 2234, {_x:60, _y:240, hp:100, team:1, unitType:"track", unitClass:"apc"});
_root.attachMovie("red_rocket", "unit32", 2232, {_x:60, _y:270, hp:100, team:1, unitType:"track", unitClass:"rocket"});
_root.attachMovie("red_tank", "unit33", 2233, {_x:60, _y:300, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_art", "unit34", 2234, {_x:60, _y:180, hp:100, team:1, unitType:"track", unitClass:"artillery"});
_root.fow = true;
break;
case 7 :
_root.fow = true;
_root.attachMovie("red_infantry", "unit50", 2250, {_x:90, _y:90, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit51", 2251, {_x:90, _y:180, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit52", 2252, {_x:180, _y:270, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit53", 2253, {_x:240, _y:240, hp:100, team:1, unitType:"foot", unitClass:"infantry", frozen:true});
_root.attachMovie("red_infantry", "unit54", 2254, {_x:240, _y:180, hp:100, team:1, unitType:"foot", unitClass:"infantry", frozen:true});
_root.attachMovie("red_infantry", "unit55", 2255, {_x:270, _y:90, hp:100, team:1, unitType:"foot", unitClass:"infantry", frozen:true});
_root.attachMovie("red_infantry", "unit56", 2256, {_x:0, _y:330, hp:100, team:1, unitType:"foot", unitClass:"infantry", frozen:true});
_root.attachMovie("red_tank", "unit57", 2257, {_x:120, _y:120, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_tank", "unit58", 2258, {_x:120, _y:300, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_rocketinf", "unit1", 2201, {_x:420, _y:210, hp:100, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("blue_rocketinf", "unit2", 2202, {_x:450, _y:210, hp:100, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("blue_art", "unit3", 2203, {_x:510, _y:150, hp:100, team:0, unitType:"track", unitClass:"artillery"});
_root.attachMovie("blue_art", "unit4", 2204, {_x:510, _y:180, hp:100, team:0, unitType:"track", unitClass:"artillery"});
_root.attachMovie("blue_art", "unit5", 2205, {_x:510, _y:210, hp:100, team:0, unitType:"track", unitClass:"artillery"});
_root.fow = true;
break;
case 8 :
_root.fow = false;
_root.attachMovie("red_infantry", "unit25", 2225, {_x:90, _y:210, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit26", 2226, {_x:90, _y:270, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_infantry", "unit1", 2201, {_x:540, _y:240, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_transport", "unit0", 2200, {_x:540, _y:270, hp:100, team:0, unitType:"air", unitClass:"transport"});
_root.fow = false;
break;
case 9 :
_root.fow = false;
_root.attachMovie("red_destroyer", "unit25", 2225, {_x:30, _y:90, hp:100, team:1, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit26", 2226, {_x:30, _y:180, hp:100, team:1, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit27", 2227, {_x:30, _y:270, hp:100, team:1, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_lander", "unit28", 2228, {_x:0, _y:90, hp:100, team:1, unitType:"sea", unitClass:"lander"});
_root.attachMovie("red_lander", "unit29", 2229, {_x:0, _y:60, hp:100, team:1, unitType:"sea", unitClass:"lander"});
_root.attachMovie("red_lander", "unit30", 2230, {_x:0, _y:180, hp:100, team:1, unitType:"sea", unitClass:"lander"});
_root.attachMovie("red_lander", "unit31", 2231, {_x:0, _y:150, hp:100, team:1, unitType:"sea", unitClass:"lander"});
_root.attachMovie("red_lander", "unit32", 2232, {_x:0, _y:270, hp:100, team:1, unitType:"sea", unitClass:"lander"});
_root.attachMovie("red_lander", "unit33", 2233, {_x:0, _y:240, hp:100, team:1, unitType:"sea", unitClass:"lander"});
_root.attachMovie("blue_sub", "unit0", 2200, {_x:510, _y:180, hp:100, team:0, unitType:"sea", unitClass:"submarine"});
_root.attachMovie("blue_destroyer", "unit3", 2203, {_x:510, _y:210, hp:100, team:0, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("blue_sub", "unit1", 2201, {_x:510, _y:240, hp:100, team:0, unitType:"sea", unitClass:"submarine"});
_root.attachMovie("blue_destroyer", "unit4", 2204, {_x:510, _y:270, hp:100, team:0, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("blue_sub", "unit2", 2202, {_x:510, _y:300, hp:100, team:0, unitType:"sea", unitClass:"submarine"});
_root.fow = false;
}
}
if (mission >= 10) {
switch (int(_root.mission)) {
case 10 :
_root.fow = true;
_root.attachMovie("red_destroyer", "unit25", 2225, {_x:210, _y:0, hp:100, team:1, frozen:true, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit26", 2226, {_x:240, _y:60, hp:100, team:1, frozen:true, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit27", 2227, {_x:270, _y:90, hp:100, team:1, frozen:true, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit28", 2228, {_x:300, _y:120, hp:100, team:1, frozen:true, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit29", 2229, {_x:270, _y:210, hp:100, team:1, frozen:true, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit30", 2230, {_x:270, _y:240, hp:100, team:1, frozen:true, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit31", 2231, {_x:240, _y:270, hp:100, team:1, frozen:true, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit32", 2232, {_x:210, _y:330, hp:100, team:1, frozen:true, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit33", 2233, {_x:300, _y:30, hp:100, team:1, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit34", 2234, {_x:300, _y:90, hp:100, team:1, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit35", 2235, {_x:300, _y:180, hp:100, team:1, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit36", 2236, {_x:300, _y:240, hp:100, team:1, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_destroyer", "unit37", 2237, {_x:300, _y:270, hp:100, team:1, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("red_carrier", "unit38", 2238, {_x:300, _y:0, hp:100, team:1, frozen:true, unitType:"sea", unitClass:"carrier"});
_root.attachMovie("red_carrier", "unit39", 2239, {_x:300, _y:60, hp:100, team:1, frozen:true, unitType:"sea", unitClass:"carrier"});
_root.attachMovie("red_carrier", "unit40", 2240, {_x:300, _y:210, hp:100, team:1, frozen:true, unitType:"sea", unitClass:"carrier"});
_root.attachMovie("red_carrier", "unit41", 2241, {_x:300, _y:300, hp:100, team:1, frozen:true, unitType:"sea", unitClass:"carrier"});
_root.attachMovie("blue_destroyer", "unit0", 2200, {_x:570, _y:180, hp:100, team:0, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("blue_destroyer", "unit3", 2203, {_x:540, _y:210, hp:100, team:0, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("blue_bomber", "unit6", 2206, {_x:540, _y:210, hp:100, team:0, unitType:"air", unitClass:"bomber"});
_root.attachMovie("blue_bomber", "unit7", 2207, {_x:510, _y:240, hp:100, team:0, unitType:"air", unitClass:"bomber"});
_root.attachMovie("blue_carrier", "unit10", 2210, {_x:570, _y:240, hp:100, team:0, unitType:"sea", unitClass:"carrier"});
_root.attachMovie("blue_carrier", "unit11", 2211, {_x:570, _y:270, hp:100, team:0, unitType:"sea", unitClass:"carrier"});
_root.attachMovie("blue_bomber", "unit8", 2208, {_x:510, _y:270, hp:100, team:0, unitType:"air", unitClass:"bomber"});
_root.attachMovie("blue_bomber", "unit9", 2209, {_x:540, _y:300, hp:100, team:0, unitType:"air", unitClass:"bomber"});
_root.attachMovie("blue_destroyer", "unit1", 2201, {_x:540, _y:300, hp:100, team:0, unitType:"sea", unitClass:"destroyer"});
_root.attachMovie("blue_destroyer", "unit4", 2204, {_x:570, _y:330, hp:100, team:0, unitType:"sea", unitClass:"destroyer"});
_root.fow = true;
break;
case 11 :
_root.fow = false;
_root.attachMovie("blue_infantry", "unit2", 2202, {_x:-30, _y:0, _alpha:0, moves_left:2, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_infantry", "unit3", 2203, {_x:-60, _y:0, _alpha:0, moves_left:2, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_transport", "unit0", 2200, {_x:540, _y:0, hp:100, team:0, inside:_root.unit2, unitType:"air", unitClass:"transport"});
_root.attachMovie("blue_transport", "unit1", 2201, {_x:570, _y:30, hp:100, team:0, inside:_root.unit3, unitType:"air", unitClass:"transport"});
_root.unit2.moves_left = 2;
_root.unit3.moves_left = 2;
_root.attachMovie("blue_fighter", "unit4", 2204, {_x:540, _y:60, hp:100, team:0, unitType:"air", unitClass:"fighter"});
_root.attachMovie("blue_fighter", "unit5", 2205, {_x:510, _y:90, hp:100, team:0, unitType:"air", unitClass:"fighter"});
_root.attachMovie("blue_fighter", "unit6", 2206, {_x:540, _y:0, hp:100, team:0, unitType:"air", unitClass:"fighter"});
_root.attachMovie("blue_helicopter", "unit7", 2207, {_x:480, _y:0, hp:100, team:0, unitType:"air", unitClass:"helicopter"});
_root.attachMovie("blue_helicopter", "unit8", 2208, {_x:480, _y:30, hp:100, team:0, unitType:"air", unitClass:"helicopter"});
_root.attachMovie("red_aa", "unit25", 2225, {_x:270, _y:150, frozen:true, hp:100, team:1, unitType:"track", unitClass:"aa"});
_root.attachMovie("red_aa", "unit26", 2226, {_x:270, _y:270, frozen:true, hp:100, team:1, unitType:"track", unitClass:"aa"});
_root.attachMovie("red_aa", "unit27", 2227, {_x:420, _y:270, frozen:true, hp:100, team:1, unitType:"track", unitClass:"aa"});
_root.attachMovie("red_infantry", "unit28", 2228, {_x:180, _y:60, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_fighter", "unit29", 2229, {_x:0, _y:300, hp:100, team:1, unitType:"air", unitClass:"fighter"});
_root.attachMovie("red_fighter", "unit30", 2230, {_x:0, _y:330, hp:100, team:1, unitType:"air", unitClass:"fighter"});
_root.attachMovie("red_fighter", "unit31", 2231, {_x:0, _y:360, hp:100, team:1, unitType:"air", unitClass:"fighter"});
_root.attachMovie("red_tank", "unit32", 2232, {_x:0, _y:60, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_tank", "unit33", 2233, {_x:570, _y:240, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.fow = false;
break;
case 12 :
_root.attachMovie("red_infantry", "unit25", 2225, {_x:60, _y:30, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit25", 2225, {_x:60, _y:30, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_tank", "unit26", 2226, {_x:150, _y:180, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_tank", "unit27", 2227, {_x:180, _y:180, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_apc", "unit0", 2200, {_x:510, _y:240, hp:100, team:0, unitType:"track", unitClass:"apc"});
_root.attachMovie("blue_apc", "unit1", 2201, {_x:540, _y:240, hp:100, team:0, unitType:"track", unitClass:"apc"});
_root.attachMovie("blue_infantry", "unit2", 2202, {_x:540, _y:180, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
break;
case 13 :
_root.attachMovie("blue_infantry", "unit4", 2204, {_alpha:0, _x:-30, _y:0, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_infantry", "unit5", 2205, {_alpha:0, _x:-30, _y:0, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_apc", "unit0", 2200, {inside:_root.unit4, _x:480, _y:180, hp:100, team:0, unitType:"track", unitClass:"apc"});
_root.attachMovie("blue_apc", "unit1", 2201, {inside:_root.unit5, _x:480, _y:240, hp:100, team:0, unitType:"track", unitClass:"apc"});
_root.attachMovie("blue_rocket", "unit2", 2202, {_x:540, _y:180, hp:100, team:0, unitType:"track", unitClass:"rocket"});
_root.attachMovie("blue_rocket", "unit3", 2203, {_x:540, _y:240, hp:100, team:0, unitType:"track", unitClass:"rocket"});
_root.attachMovie("blue_rocketinf", "unit6", 2206, {_x:510, _y:150, hp:100, team:0, unitType:"foot", unitClass:"rocketinf"});
_root.attachMovie("blue_rocketinf", "unit7", 2207, {_x:510, _y:270, hp:100, team:0, unitType:"foot", unitClass:"rocketinf"});
_root.attachMovie("blue_tank", "unit8", 2208, {_x:510, _y:180, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_tank", "unit9", 2209, {_x:510, _y:240, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_helicopter", "unit10", 2210, {_x:540, _y:180, hp:100, team:0, unitType:"air", unitClass:"helicopter"});
_root.attachMovie("blue_helicopter", "unit11", 2211, {_x:540, _y:180, hp:100, team:0, unitType:"air", unitClass:"helicopter"});
_root.attachMovie("red_infantry", "unit25", 2225, {_x:0, _y:180, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.t124.city_owner = 1;
_root.t124.gotoAndStop(3);
_root.t126.city_owner = 1;
_root.t126.gotoAndStop(3);
_root.t164.city_owner = 1;
_root.t164.gotoAndStop(3);
_root.t166.city_owner = 1;
_root.t166.gotoAndStop(3);
break;
case 14 :
_root.t61.city_owner = 1;
_root.t61.gotoAndStop(3);
_root.t55.city_owner = 1;
_root.t55.gotoAndStop(3);
_root.t196.city_owner = 1;
_root.t196.gotoAndStop(3);
_root.attachMovie("red_rocket", "unit25", 2225, {_x:210, _y:30, hp:100, team:1, unitType:"track", unitClass:"rocket"});
_root.attachMovie("red_rocket", "unit26", 2226, {_x:390, _y:30, hp:100, team:1, unitType:"track", unitClass:"rocket"});
_root.attachMovie("blue_rocketinf", "unit0", 2200, {_x:120, _y:360, hp:100, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("blue_rocketinf", "unit1", 2201, {_x:150, _y:330, hp:100, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("blue_rocketinf", "unit2", 2202, {_x:150, _y:390, hp:100, team:0, unitType:"foot", unitClass:"rocket infantry"});
_root.attachMovie("blue_tank", "unit3", 2203, {_x:180, _y:390, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_tank", "unit4", 2204, {_x:210, _y:390, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_tank", "unit5", 2205, {_x:240, _y:390, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_tank", "unit6", 2206, {_x:180, _y:360, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_art", "unit7", 2207, {_x:210, _y:360, hp:100, team:0, unitType:"track", unitClass:"artillery"});
_root.attachMovie("blue_art", "unit8", 2208, {_x:240, _y:360, hp:100, team:0, unitType:"track", unitClass:"artillery"});
break;
case 15 :
_root.t118.city_owner = 1;
_root.t118.gotoAndStop(3);
_root.t158.city_owner = 1;
_root.t158.gotoAndStop(3);
_root.t38.city_owner = 1;
_root.t38.gotoAndStop(3);
_root.t238.city_owner = 1;
_root.t238.gotoAndStop(3);
_root.attachMovie("blue_rocketinf", "unit8", 2208, {_alpha:0, _x:-30, _y:0, hp:100, team:0, unitType:"foot", unitClass:"rocketinf"});
_root.attachMovie("blue_rocketinf", "unit9", 2209, {_alpha:0, _x:-30, _y:0, hp:100, team:0, unitType:"foot", unitClass:"rocketinf"});
_root.attachMovie("blue_rocketinf", "unit10", 2210, {_alpha:0, _x:-30, _y:0, hp:100, team:0, unitType:"foot", unitClass:"rocketinf"});
_root.attachMovie("blue_rocketinf", "unit11", 2211, {_alpha:0, _x:-30, _y:0, hp:100, team:0, unitType:"foot", unitClass:"rocketinf"});
_root.attachMovie("blue_rocketinf", "unit12", 2212, {_alpha:0, _x:-30, _y:0, hp:100, team:0, unitType:"foot", unitClass:"rocketinf"});
_root.attachMovie("blue_rocketinf", "unit13", 2213, {_alpha:0, _x:-30, _y:0, hp:100, team:0, unitType:"foot", unitClass:"rocketinf"});
_root.attachMovie("blue_rocketinf", "unit14", 2214, {_alpha:0, _x:-30, _y:0, hp:100, team:0, unitType:"foot", unitClass:"rocketinf"});
_root.attachMovie("blue_rocketinf", "unit15", 2215, {_alpha:0, _x:-30, _y:0, hp:100, team:0, unitType:"foot", unitClass:"rocketinf"});
_root.attachMovie("blue_lander", "unit0", 2200, {inside:_root.unit8, _x:90, _y:150, hp:100, team:0, unitType:"sea", unitClass:"lander"});
_root.attachMovie("blue_lander", "unit1", 2201, {inside:_root.unit9, _x:90, _y:180, hp:100, team:0, unitType:"sea", unitClass:"lander"});
_root.attachMovie("blue_lander", "unit2", 2202, {inside:_root.unit10, _x:30, _y:90, hp:100, team:0, unitType:"sea", unitClass:"lander"});
_root.attachMovie("blue_lander", "unit3", 2203, {inside:_root.unit11, _x:60, _y:300, hp:100, team:0, unitType:"sea", unitClass:"lander"});
_root.attachMovie("blue_lander", "unit4", 2204, {inside:_root.unit12, _x:60, _y:270, hp:100, team:0, unitType:"sea", unitClass:"lander"});
_root.attachMovie("blue_lander", "unit5", 2205, {inside:_root.unit13, _x:150, _y:180, hp:100, team:0, unitType:"sea", unitClass:"lander"});
_root.attachMovie("blue_lander", "unit6", 2206, {inside:_root.unit14, _x:150, _y:210, hp:100, team:0, unitType:"sea", unitClass:"lander"});
_root.attachMovie("blue_lander", "unit7", 2207, {inside:_root.unit15, _x:30, _y:60, hp:100, team:0, unitType:"sea", unitClass:"lander"});
break;
case 16 :
_root.fow = true;
_root.attachMovie("blue_infantry", "unit0", 2200, {_x:510, _y:60, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit25", 2225, {_x:60, _y:210, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.fow = true;
break;
case 17 :
_root.fow = false;
_root.attachMovie("red_rocket", "unit25", 2225, {_x:330, _y:120, hp:100, team:1, unitType:"track", unitClass:"rocket"});
_root.attachMovie("red_rocket", "unit26", 2226, {_x:330, _y:240, hp:100, team:1, unitType:"track", unitClass:"rocket"});
_root.attachMovie("red_rocket", "unit27", 2227, {_x:240, _y:330, hp:100, team:1, unitType:"track", unitClass:"rocket"});
_root.attachMovie("red_rocket", "unit28", 2228, {_x:240, _y:30, hp:100, team:1, unitType:"track", unitClass:"rocket"});
_root.attachMovie("red_rocket", "unit29", 2229, {_x:120, _y:270, hp:100, team:1, unitType:"track", unitClass:"rocket"});
_root.attachMovie("red_rocket", "unit30", 2230, {_x:120, _y:120, hp:100, team:1, unitType:"track", unitClass:"rocket"});
_root.attachMovie("red_tank", "unit31", 2231, {_x:180, _y:90, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_tank", "unit32", 2232, {_x:180, _y:240, hp:100, team:1, unitType:"track", unitClass:"tank"});
_root.attachMovie("red_infantry", "unit33", 2233, {_x:30, _y:150, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit34", 2234, {_x:60, _y:150, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit35", 2235, {_x:60, _y:180, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit36", 2236, {_x:90, _y:150, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit37", 2237, {_x:90, _y:180, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_aa", "unit38", 2238, {_x:240, _y:120, hp:100, team:1, unitType:"track", unitClass:"aa"});
_root.attachMovie("red_aa", "unit39", 2239, {_x:210, _y:240, hp:100, team:1, unitType:"track", unitClass:"aa"});
_root.attachMovie("red_aa", "unit40", 2240, {_x:150, _y:180, hp:100, team:1, unitType:"track", unitClass:"aa"});
_root.attachMovie("blue_helicopter", "unit0", 2200, {_x:540, _y:150, hp:100, team:0, unitType:"air", unitClass:"helicopter"});
_root.attachMovie("blue_helicopter", "unit1", 2201, {_x:540, _y:210, hp:100, team:0, unitType:"air", unitClass:"helicopter"});
_root.attachMovie("blue_helicopter", "unit2", 2202, {_x:570, _y:120, hp:100, team:0, unitType:"air", unitClass:"helicopter"});
_root.attachMovie("blue_helicopter", "unit3", 2203, {_x:570, _y:240, hp:100, team:0, unitType:"air", unitClass:"helicopter"});
_root.attachMovie("blue_tank", "unit4", 2204, {_x:570, _y:150, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_tank", "unit5", 2205, {_x:570, _y:210, hp:100, team:0, unitType:"track", unitClass:"tank"});
_root.attachMovie("blue_infantry", "unit6", 2206, {_x:570, _y:180, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_infantry", "unit7", 2207, {_alpha:0, _x:-30, _y:0, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("blue_apc", "unit8", 2208, {inside:_root.unit7, _x:510, _y:180, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.fow = false;
break;
case 18 :
_root.fow = true;
_root.attachMovie("blue_infantry", "unit0", 2200, {_x:390, _y:390, hp:100, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit25", 2225, {_x:180, _y:0, hp:100, team:1, unitType:"foot", unitClass:"infantry"});
_root.fow = true;
}
}
}
_root.map = new Array();
if (_root.mission == 0) {
_root.map.push(0, 0, 0, 0, 0, 11, 10, 10, 10, 10, 10, 11, 0, 0, 1, 1, 2, 2, 2, 2, 0, 0, 0, 25, 25, 0, 0, 11, 11, 10, 10, 11, 0, 0, 1, 1, 2, 2, 2, 2, 0, 0, 0, 0, 0, 25, 0, 0, 0, 11, 11, 11, 0, 0, 1, 1, 2, 21, 2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 6, 0, 0, 0, 0, 0, 0, 0, 2, 2, 0, 0, 2, 2, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 15, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 21, 2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 0, 0);
}
if (_root.mission == 1) {
_root.map.push(1, 1, 1, 1, 30, 30, 30, 30, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 30, 30, 10, 10, 10, 10, 10, 0, 0, 10, 0, 10, 10, 10, 10, 1, 1, 1, 1, 1, 30, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 10, 10, 10, 1, 1, 1, 30, 30, 10, 16, 17, 0, 0, 7, 3, 3, 3, 6, 0, 0, 0, 0, 10, 30, 30, 30, 1, 1, 0, 10, 3, 3, 3, 8, 10, 10, 10, 4, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 10, 10, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 30, 10, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 9, 3, 3, 3, 3, 3, 1, 1, 1, 1, 1, 1, 0, 1, 0, 0, 0, 0, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 7, 3, 3, 3, 3, 3, 8, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 4, 15, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
}
if (_root.mission == 2) {
_root.map.push(2, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11, 0, 0, 0, 0, 0, 0, 10, 10, 0, 11, 10, 10, 10, 10, 10, 10, 10, 10, 11, 0, 0, 0, 0, 0, 0, 0, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 11, 11, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 10, 10, 10, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 11, 10, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 10, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 0, 11, 11, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 2);
}
if (_root.mission == 3) {
_root.map.push(1, 1, 1, 30, 30, 1, 1, 1, 4, 1, 30, 30, 1, 1, 1, 1, 1, 1, 30, 30, 1, 30, 1, 1, 30, 1, 30, 1, 5, 6, 30, 30, 30, 30, 1, 1, 1, 1, 30, 30, 1, 30, 30, 1, 1, 1, 30, 1, 1, 5, 6, 1, 1, 30, 1, 1, 30, 1, 1, 1, 1, 30, 1, 1, 1, 1, 1, 30, 1, 1, 4, 1, 1, 30, 1, 1, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 1, 4, 30, 30, 30, 1, 1, 1, 1, 30, 30, 30, 30, 1, 1, 30, 1, 1, 30, 1, 1, 4, 1, 30, 1, 1, 1, 1, 1, 1, 1, 1, 30, 1, 1, 1, 1, 1, 1, 1, 30, 4, 1, 1, 30, 1, 1, 1, 1, 1, 1, 30, 1, 1, 1, 1, 1, 1, 30, 30, 30, 4, 1, 1, 30, 30, 1, 1, 30, 30, 30, 1, 1, 30, 1, 1, 1, 30, 7, 3, 3, 9, 3, 3, 3, 3, 3, 3, 3, 3, 3, 1, 7, 3, 3, 3, 3, 3, 8, 30, 30, 1, 1, 1, 30, 30, 1, 1, 1, 30, 1, 1, 4, 1, 30, 30, 30, 1, 1, 1, 30, 1, 1, 30, 30, 30, 1, 1, 30, 1, 1, 1, 4, 1, 30, 30, 1, 1, 1, 1, 1, 1, 30, 1, 1, 1, 1, 30, 30, 30, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 1, 1, 1, 1, 1, 1);
}
if (_root.mission == 4) {
_root.map.push(10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 4, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 0, 0, 0, 10, 10, 10, 0, 0, 0, 4, 50, 0, 10, 3, 3, 3, 3, 3, 6, 11, 0, 0, 0, 0, 10, 10, 0, 0, 0, 4, 0, 0, 10, 10, 10, 18, 11, 11, 4, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 10, 10, 0, 0, 0, 11, 4, 11, 15, 0, 0, 0, 0, 0, 0, 0, 15, 4, 18, 0, 10, 10, 0, 0, 0, 11, 5, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 9, 3, 3, 3, 10, 10, 0, 0, 0, 11, 11, 11, 0, 4, 0, 11, 20, 20, 20, 20, 4, 20, 20, 20, 10, 10, 10, 0, 0, 0, 0, 0, 0, 4, 0, 11, 2, 2, 2, 2, 4, 2, 2, 2, 10, 10, 0, 0, 0, 0, 0, 0, 0, 4, 15, 11, 2, 2, 2, 0, 4, 2, 2, 2, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 2, 2, 0, 0, 4, 0, 2, 2, 10, 15, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 2, 0, 0, 15, 4, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 10, 2, 0, 0, 18, 4, 15, 0, 0, 10, 10, 0, 18, 51, 0, 10, 10, 0, 0, 10, 10, 2, 2, 2, 0, 4, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 2, 2, 2, 2, 4, 0, 0, 0);
}
if (_root.mission == 5) {
_root.map.push(7, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 6, 4, 11, 11, 0, 0, 0, 11, 25, 0, 0, 0, 4, 0, 0, 15, 0, 0, 15, 0, 4, 4, 25, 11, 0, 0, 0, 0, 0, 0, 11, 0, 4, 0, 0, 0, 0, 0, 0, 0, 4, 4, 0, 0, 0, 0, 11, 0, 0, 0, 0, 0, 4, 10, 10, 10, 10, 10, 10, 10, 4, 4, 11, 0, 0, 0, 25, 0, 0, 0, 0, 0, 4, 0, 11, 11, 11, 11, 11, 10, 4, 4, 3, 3, 3, 3, 3, 6, 0, 0, 11, 0, 4, 0, 0, 0, 0, 0, 0, 18, 4, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 0, 0, 0, 16, 17, 0, 18, 4, 4, 20, 20, 20, 20, 20, 4, 20, 20, 20, 20, 4, 0, 0, 0, 0, 0, 0, 18, 4, 4, 11, 2, 2, 21, 2, 4, 2, 2, 2, 0, 4, 0, 11, 11, 11, 11, 11, 10, 4, 4, 0, 11, 2, 2, 2, 4, 2, 2, 0, 0, 4, 10, 10, 10, 10, 10, 10, 10, 4, 4, 0, 0, 11, 11, 11, 4, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 4, 4, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 4, 4, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 4, 0, 0, 15, 0, 0, 15, 0, 4, 5, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 8);
}
if (_root.mission == 6) {
_root.map.push(0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 0, 0, 0, 11, 2, 21, 2, 11, 11, 11, 11, 11, 11, 11, 11, 21, 2, 2, 2, 21, 0, 11, 0, 0, 2, 2, 2, 11, 7, 3, 3, 3, 3, 3, 6, 11, 2, 2, 2, 2, 0, 0, 0, 2, 2, 2, 2, 11, 4, 11, 0, 0, 0, 11, 4, 11, 11, 11, 11, 11, 2, 2, 2, 2, 2, 2, 2, 11, 4, 0, 0, 11, 0, 0, 4, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 21, 2, 11, 4, 11, 0, 0, 0, 11, 5, 3, 3, 3, 3, 3, 11, 11, 11, 11, 11, 11, 11, 11, 4, 11, 0, 0, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 3, 3, 8, 0, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 8, 11, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 10, 10, 0, 10, 0, 0, 0, 11, 0, 0, 10, 0, 0, 11, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 10, 0, 0, 10, 10, 10, 10, 10, 10, 10);
}
if (_root.mission == 7) {
_root.map.push(15, 4, 15, 15, 4, 15, 15, 4, 15, 15, 4, 23, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 9, 23, 2, 2, 2, 2, 22, 0, 23, 2, 15, 4, 15, 15, 4, 15, 15, 4, 15, 15, 4, 23, 2, 2, 2, 2, 22, 0, 23, 2, 15, 4, 15, 15, 4, 15, 15, 4, 15, 15, 4, 23, 2, 2, 2, 22, 0, 0, 0, 23, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 8, 23, 2, 22, 0, 7, 3, 3, 6, 23, 15, 4, 15, 15, 4, 15, 15, 4, 15, 15, 23, 2, 22, 0, 0, 4, 15, 15, 4, 23, 15, 4, 15, 15, 4, 15, 15, 4, 15, 23, 2, 2, 2, 2, 22, 9, 6, 15, 4, 0, 3, 3, 3, 3, 3, 3, 3, 9, 3, 3, 3, 3, 3, 3, 3, 3, 9, 15, 4, 23, 15, 4, 15, 15, 4, 15, 15, 4, 15, 23, 2, 2, 2, 2, 22, 5, 3, 3, 8, 23, 15, 4, 15, 15, 4, 15, 15, 4, 15, 15, 23, 2, 2, 2, 2, 22, 0, 0, 23, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 6, 23, 2, 2, 2, 2, 22, 0, 23, 2, 15, 4, 15, 15, 4, 15, 15, 4, 15, 15, 4, 23, 2, 2, 2, 2, 22, 0, 23, 2, 15, 4, 15, 15, 4, 15, 15, 4, 15, 15, 4, 23, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 8, 23, 2, 2, 2, 2, 2, 2, 2, 2);
}
if (_root.mission == 8) {
_root.map.push(73, 73, 73, 73, 73, 4, 73, 73, 73, 73, 73, 73, 73, 73, 73, 73, 73, 73, 73, 73, 73, 70, 73, 70, 72, 4, 73, 70, 70, 73, 73, 70, 70, 73, 70, 70, 70, 73, 70, 73, 70, 70, 70, 70, 72, 4, 73, 70, 70, 70, 70, 70, 70, 72, 72, 70, 70, 70, 70, 73, 71, 70, 70, 71, 71, 4, 72, 70, 70, 72, 70, 70, 70, 70, 70, 70, 73, 70, 70, 70, 0, 71, 71, 0, 11, 4, 72, 71, 71, 70, 70, 70, 71, 71, 71, 70, 70, 70, 70, 70, 10, 10, 10, 0, 18, 4, 71, 0, 0, 71, 70, 71, 25, 0, 0, 71, 71, 70, 71, 71, 10, 51, 10, 0, 11, 4, 18, 0, 0, 0, 71, 0, 0, 0, 0, 0, 0, 71, 0, 0, 10, 4, 10, 10, 11, 4, 15, 15, 11, 11, 11, 11, 11, 11, 11, 11, 18, 11, 50, 11, 10, 5, 3, 3, 3, 9, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 10, 10, 10, 10, 11, 4, 15, 15, 11, 11, 11, 11, 11, 11, 11, 11, 16, 17, 11, 11, 0, 0, 0, 0, 11, 4, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 11, 11, 11, 4, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 8, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 11, 11, 11, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
}
if (_root.mission == 9) {
_root.map.push(2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 2, 2, 2, 21, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 21, 2, 22, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 21, 2, 2, 2, 2, 22, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 0, 2, 21, 2, 2, 2, 2, 2, 21, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 21, 22, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 21, 2, 2, 2, 2, 22, 0, 2, 2, 2, 2, 21, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 0);
}
if (_root.mission == 10) {
_root.map.push(10, 10, 10, 10, 10, 0, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 6, 0, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 10, 15, 11, 11, 11, 4, 0, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 10, 10, 10, 11, 11, 4, 0, 0, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 10, 10, 10, 11, 11, 4, 0, 0, 18, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 10, 10, 11, 11, 11, 4, 0, 0, 0, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 10, 11, 11, 11, 11, 4, 0, 0, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 10, 10, 11, 11, 11, 4, 0, 0, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 0, 0, 10, 11, 11, 4, 0, 18, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 0, 10, 11, 11, 7, 8, 0, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 10, 10, 10, 15, 4, 0, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 10, 0, 15, 15, 4, 15, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 21, 2, 2, 2, 10, 10, 0, 15, 4, 15, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 10, 10, 10, 10, 4, 0, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2);
}
if (_root.mission == 11) {
_root.map.push(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 10, 0, 0, 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 6, 0, 1, 1, 1, 10, 10, 0, 0, 1, 0, 0, 1, 11, 11, 11, 1, 1, 1, 1, 4, 0, 1, 1, 1, 1, 0, 0, 0, 1, 30, 0, 0, 0, 0, 11, 11, 11, 11, 11, 4, 0, 1, 1, 0, 0, 0, 1, 1, 1, 30, 30, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 1, 0, 0, 0, 0, 1, 1, 1, 30, 1, 30, 1, 1, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 1, 1, 1, 1, 1, 30, 30, 30, 30, 1, 1, 0, 18, 0, 0, 4, 0, 0, 0, 0, 1, 1, 1, 1, 1, 30, 1, 30, 30, 30, 1, 18, 16, 17, 0, 5, 3, 3, 3, 3, 3, 3, 3, 3, 3, 30, 1, 30, 30, 30, 30, 1, 18, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 30, 30, 30, 30, 1, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 1, 30, 30, 30, 1, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 30, 1, 30, 30, 1, 30, 30, 30, 30, 1, 30, 30, 30, 1, 30, 30, 1, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 1, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30);
}
if (_root.mission == 12) {
map.push(10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 51, 18, 0, 0, 10, 0, 0, 10, 7, 3, 3, 3, 3, 3, 6, 0, 10, 10, 10, 11, 18, 0, 0, 0, 0, 10, 10, 10, 4, 10, 10, 11, 11, 10, 4, 0, 0, 10, 10, 11, 0, 0, 0, 0, 0, 0, 10, 10, 4, 10, 11, 11, 11, 10, 4, 0, 0, 10, 10, 11, 0, 0, 0, 11, 0, 0, 10, 10, 4, 10, 10, 10, 10, 11, 4, 0, 0, 10, 10, 11, 0, 0, 11, 16, 17, 0, 11, 10, 5, 3, 3, 6, 10, 11, 4, 0, 10, 10, 3, 3, 3, 3, 3, 3, 3, 3, 6, 10, 18, 10, 10, 4, 10, 11, 4, 15, 50, 10, 10, 10, 0, 0, 0, 0, 0, 0, 4, 10, 0, 10, 10, 4, 10, 11, 5, 3, 3, 3, 10, 0, 0, 0, 0, 0, 0, 0, 4, 10, 10, 10, 0, 4, 10, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 4, 10, 10, 0, 0, 4, 10, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 4, 10, 10, 15, 18, 4, 10, 0, 0, 0, 0, 10, 10, 11, 0, 0, 0, 0, 0, 0, 5, 3, 3, 3, 3, 8, 10, 0, 0, 0, 0, 10, 10, 10, 11, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 10, 10, 11, 11, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10);
}
if (_root.mission == 13) {
_root.map.push(10, 10, 10, 10, 10, 10, 10, 4, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 4, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 10, 10, 10, 11, 11, 11, 11, 11, 4, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 10, 10, 11, 11, 11, 11, 11, 11, 4, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 10, 10, 11, 11, 11, 11, 11, 0, 4, 0, 0, 11, 11, 11, 11, 11, 11, 11, 11, 11, 10, 10, 11, 11, 11, 11, 0, 0, 4, 0, 0, 0, 0, 0, 11, 11, 11, 11, 11, 11, 10, 10, 11, 11, 11, 18, 15, 18, 4, 18, 15, 18, 0, 0, 0, 11, 11, 11, 11, 11, 10, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 10, 11, 11, 11, 18, 15, 18, 4, 18, 15, 18, 0, 0, 11, 11, 11, 11, 11, 11, 10, 10, 11, 11, 11, 11, 0, 0, 4, 0, 0, 0, 0, 11, 11, 11, 11, 11, 11, 11, 10, 10, 11, 11, 11, 11, 11, 0, 4, 0, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 10, 10, 11, 11, 11, 11, 11, 11, 4, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 10, 10, 11, 11, 11, 11, 11, 11, 4, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 10, 10, 10, 10, 10, 10, 10, 10, 4, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10);
}
if (_root.mission == 14) {
_root.map.push(30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 51, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 1, 30, 30, 30, 30, 30, 30, 30, 30, 0, 18, 30, 30, 30, 30, 3, 18, 30, 30, 30, 30, 1, 30, 1, 30, 30, 30, 30, 30, 1, 0, 3, 3, 3, 3, 1, 0, 30, 30, 30, 30, 1, 1, 1, 30, 30, 30, 30, 1, 1, 1, 30, 30, 30, 30, 1, 1, 1, 30, 30, 30, 1, 1, 1, 30, 30, 30, 1, 1, 1, 30, 30, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 1, 1, 1, 30, 30, 30, 30, 30, 30, 30, 30, 30, 1, 1, 1, 30, 1, 1, 1, 1, 1, 1, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 1, 1, 30, 1, 1, 1, 1, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 1, 1, 30, 1, 1, 1, 1, 1, 30, 30, 18, 0, 30, 30, 30, 30, 30, 30, 30, 30, 30, 1, 30, 1, 30, 1, 1, 1, 1, 1, 3, 3, 3, 3, 30, 30, 30, 30, 30, 30, 30, 1, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 18, 4, 1, 1, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 4, 0, 1, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30);
}
if (_root.mission == 15) {
_root.map.push(2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 4, 0, 0, 0, 0, 0, 4, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 4, 0, 0, 0, 0, 0, 4, 18, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 4, 0, 0, 15, 0, 0, 4, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 4, 0, 0, 15, 0, 0, 4, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 4, 0, 0, 0, 0, 0, 4, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 15, 9, 3, 3, 3, 3, 3, 8, 18, 0, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 15, 4, 0, 0, 0, 15, 0, 0, 51, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 4, 0, 0, 0, 15, 0, 0, 18, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 9, 3, 3, 3, 3, 3, 3, 3, 3, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 0, 4, 15, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 0, 4, 15, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 0, 4, 0, 0, 0, 0, 0, 0, 18, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0);
}
if (_root.mission == 16) {
_root.map.push(0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 10, 10, 25, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 10, 10, 10, 0, 0, 0, 0, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 10, 10, 10, 0, 0, 0, 15, 50, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 10, 0, 0, 0, 0, 0, 16, 17, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 15, 15, 18, 15, 15, 0, 0, 0, 0, 20, 20, 10, 10, 0, 10, 0, 0, 0, 0, 0, 15, 15, 51, 15, 15, 0, 0, 0, 0, 0, 2, 10, 10, 10, 25, 0, 0, 0, 0, 0, 15, 15, 18, 15, 15, 0, 0, 0, 0, 0, 2, 2, 10, 10, 0, 10, 0, 0, 0, 0, 0, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 2, 2, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 10, 10, 25, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 10, 10, 0, 0, 0, 0, 0, 0, 16, 17, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 10, 10, 10, 10, 0, 0, 0);
}
if (_root.mission == 17) {
_root.map.push(30, 30, 30, 30, 30, 30, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 30, 30, 30, 30, 1, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 30, 30, 30, 30, 1, 1, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 30, 30, 30, 30, 1, 1, 1, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 30, 30, 30, 30, 1, 1, 1, 1, 30, 30, 30, 1, 1, 1, 1, 1, 1, 11, 30, 1, 1, 30, 30, 30, 1, 1, 1, 1, 1, 30, 30, 30, 1, 1, 1, 1, 11, 11, 30, 51, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 11, 50, 30, 1, 1, 30, 30, 30, 1, 1, 1, 1, 1, 30, 30, 30, 1, 1, 1, 1, 11, 11, 30, 30, 30, 30, 30, 30, 1, 1, 1, 1, 30, 30, 30, 1, 1, 1, 1, 1, 1, 11, 30, 30, 30, 30, 30, 30, 1, 1, 1, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 30, 30, 30, 30, 1, 1, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 30, 30, 30, 30, 1, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 30, 30, 30, 30, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 30, 30, 30, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
}
if (_root.mission == 18) {
_root.map.push(2, 2, 22, 0, 0, 15, 51, 0, 15, 0, 0, 0, 0, 16, 17, 0, 0, 23, 2, 2, 2, 2, 22, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 18, 23, 2, 2, 2, 2, 2, 22, 10, 0, 0, 0, 18, 0, 0, 0, 0, 0, 0, 0, 23, 2, 2, 2, 2, 10, 2, 22, 10, 10, 0, 0, 18, 0, 0, 0, 0, 0, 0, 0, 23, 2, 2, 2, 2, 10, 2, 2, 22, 10, 10, 4, 0, 0, 0, 0, 0, 4, 0, 0, 23, 2, 2, 2, 2, 10, 11, 2, 2, 2, 22, 4, 23, 2, 2, 2, 22, 4, 15, 2, 2, 2, 2, 2, 2, 10, 11, 2, 2, 2, 22, 4, 23, 2, 2, 2, 22, 4, 23, 2, 2, 2, 2, 2, 2, 10, 11, 2, 22, 10, 10, 4, 0, 23, 2, 2, 22, 4, 23, 2, 2, 2, 2, 2, 2, 10, 11, 22, 10, 10, 10, 0, 0, 0, 0, 0, 0, 4, 23, 2, 2, 2, 2, 2, 2, 10, 23, 22, 18, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 23, 2, 2, 2, 2, 2, 10, 23, 2, 22, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 23, 2, 2, 2, 2, 10, 11, 11, 22, 0, 0, 10, 16, 17, 0, 18, 0, 18, 0, 0, 23, 2, 2, 2, 2, 10, 25, 11, 22, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 18, 23, 2, 2, 2, 10, 10, 10, 22, 0, 0, 10, 10, 0, 0, 0, 15, 0, 50, 15, 0, 23, 2, 2, 2);
}
if (_root.mission == 30) {
_root.map.push(15, 15, 0, 0, 0, 11, 0, 15, 23, 2, 21, 2, 22, 10, 0, 25, 25, 23, 2, 21, 0, 51, 0, 0, 0, 11, 11, 23, 21, 2, 21, 22, 0, 0, 0, 0, 10, 0, 23, 2, 18, 0, 0, 0, 11, 0, 0, 23, 2, 2, 2, 2, 0, 0, 0, 0, 0, 23, 21, 2, 0, 0, 0, 11, 0, 0, 0, 0, 23, 2, 21, 2, 4, 2, 2, 2, 2, 2, 2, 2, 0, 0, 0, 10, 10, 0, 3, 3, 3, 3, 0, 23, 4, 2, 21, 2, 21, 2, 2, 2, 2, 2, 2, 2, 21, 2, 2, 20, 20, 20, 0, 0, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 21, 2, 2, 21, 2, 2, 22, 18, 0, 0, 23, 2, 2, 2, 0, 10, 10, 2, 2, 2, 2, 2, 2, 2, 2, 2, 22, 18, 0, 3, 3, 3, 3, 0, 0, 0, 0, 2, 2, 22, 0, 0, 3, 3, 3, 3, 3, 0, 0, 20, 20, 20, 20, 0, 0, 0, 11, 2, 2, 22, 10, 0, 20, 20, 20, 20, 20, 21, 2, 2, 2, 2, 0, 0, 0, 11, 11, 22, 0, 0, 0, 0, 10, 23, 2, 2, 2, 2, 2, 2, 2, 0, 0, 0, 11, 0, 0, 22, 0, 25, 25, 0, 0, 23, 2, 2, 21, 2, 2, 0, 0, 0, 0, 0, 0, 0, 18, 2, 2, 22, 0, 23, 2, 21, 2, 21, 2, 2, 2, 15, 0, 0, 0, 0, 0, 0, 50, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 0, 0, 0, 11, 11, 0, 15, 15);
}
if (_root.mission == 31) {
map.push(2, 2, 2, 2, 21, 2, 2, 2, 2, 2, 2, 2, 21, 2, 2, 21, 2, 2, 2, 2, 2, 21, 2, 2, 2, 2, 22, 0, 0, 0, 0, 0, 0, 23, 2, 2, 2, 2, 2, 2, 2, 21, 2, 2, 2, 22, 0, 10, 0, 0, 0, 0, 10, 0, 23, 2, 2, 2, 21, 2, 2, 2, 2, 2, 21, 22, 0, 10, 11, 0, 0, 11, 10, 0, 23, 2, 2, 2, 2, 2, 2, 22, 15, 3, 3, 3, 6, 25, 0, 11, 11, 0, 15, 7, 3, 3, 3, 15, 23, 2, 0, 18, 0, 0, 0, 0, 5, 3, 6, 0, 0, 7, 3, 8, 0, 0, 0, 0, 18, 0, 0, 50, 0, 0, 0, 0, 0, 0, 4, 16, 16, 4, 0, 0, 0, 0, 0, 0, 51, 0, 0, 18, 0, 0, 0, 0, 0, 0, 9, 3, 3, 9, 0, 0, 0, 0, 0, 0, 18, 0, 0, 0, 0, 0, 0, 0, 7, 3, 8, 0, 0, 5, 3, 6, 0, 0, 0, 0, 0, 0, 2, 22, 15, 3, 3, 3, 8, 15, 11, 0, 0, 11, 25, 5, 3, 3, 3, 15, 23, 2, 2, 21, 2, 2, 2, 22, 0, 10, 0, 11, 11, 0, 10, 0, 23, 2, 2, 2, 2, 2, 2, 2, 21, 2, 2, 22, 0, 10, 0, 0, 0, 0, 10, 0, 23, 2, 2, 2, 21, 2, 2, 2, 21, 2, 2, 2, 22, 0, 0, 0, 0, 0, 0, 23, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 21, 2, 21, 2, 2, 2, 2, 21, 21, 2, 2, 2, 2, 2, 2);
}
if (_root.mission == 32) {
map.push(1, 1, 1, 18, 1, 1, 1, 1, 1, 30, 30, 1, 1, 25, 30, 1, 1, 25, 1, 25, 1, 50, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 30, 1, 1, 1, 1, 30, 1, 1, 15, 1, 1, 18, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 1, 1, 1, 1, 1, 30, 1, 18, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 1, 30, 1, 1, 1, 1, 1, 1, 1, 1, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 25, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 30, 1, 1, 1, 1, 1, 1, 30, 25, 30, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 1, 1, 1, 1, 1, 1, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 1, 1, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 18, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 18, 1, 1, 1, 30, 1, 1, 30, 1, 30, 1, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 15, 25, 1, 30, 1, 1, 30, 1, 1, 1, 30, 1, 1, 1, 1, 1, 18, 1, 1, 51, 1, 1, 25, 1, 1, 30, 25, 1, 30, 1, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
}
if (_root.mission == 33) {
map.push(22, 15, 0, 50, 0, 18, 0, 23, 21, 22, 0, 0, 0, 23, 2, 2, 21, 2, 2, 2, 0, 0, 0, 4, 0, 0, 0, 23, 22, 0, 0, 15, 15, 15, 0, 23, 2, 2, 21, 2, 11, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 23, 2, 2, 10, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 10, 4, 0, 0, 10, 10, 18, 23, 2, 11, 0, 0, 4, 0, 0, 11, 0, 0, 0, 0, 0, 9, 3, 3, 3, 3, 3, 18, 23, 10, 11, 0, 4, 0, 11, 0, 0, 11, 0, 11, 0, 4, 15, 0, 10, 10, 0, 18, 23, 10, 11, 0, 5, 3, 6, 0, 11, 11, 0, 0, 0, 5, 6, 0, 0, 0, 0, 23, 2, 10, 0, 0, 0, 0, 4, 0, 0, 0, 11, 0, 0, 11, 4, 0, 10, 0, 0, 23, 2, 0, 0, 10, 0, 0, 4, 0, 11, 0, 0, 0, 7, 3, 8, 0, 0, 0, 0, 23, 2, 0, 0, 0, 0, 0, 4, 0, 0, 11, 0, 15, 15, 15, 0, 0, 23, 2, 2, 2, 2, 10, 0, 0, 10, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 2, 2, 2, 21, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 23, 2, 2, 2, 2, 21, 2, 2, 2, 2, 22, 0, 0, 0, 0, 4, 0, 0, 0, 0, 23, 21, 2, 2, 2, 2, 2, 21, 2, 2, 2, 22, 0, 15, 0, 51, 0, 18, 23, 2, 2, 2, 21, 2, 2, 2, 2, 2, 2, 2);
}
if (_root.mission == 34) {
map.push(2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 0, 0, 0, 2, 2, 0, 0, 0, 25, 15, 15, 25, 0, 0, 0, 2, 2, 0, 0, 0, 0, 0, 0, 10, 10, 0, 0, 0, 7, 3, 3, 6, 0, 0, 0, 10, 10, 0, 0, 0, 15, 0, 0, 10, 10, 0, 0, 0, 4, 0, 0, 4, 0, 0, 0, 10, 10, 0, 0, 15, 50, 18, 3, 3, 3, 3, 3, 3, 9, 15, 15, 9, 3, 3, 3, 3, 3, 3, 18, 51, 0, 0, 0, 10, 10, 0, 0, 0, 4, 0, 0, 4, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 10, 10, 0, 0, 0, 5, 3, 3, 8, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 2, 2, 0, 0, 0, 25, 15, 15, 25, 0, 0, 0, 2, 2, 0, 0, 0, 2, 2, 2, 2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2);
}
if (_root.mission == 35) {
map.push(10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 50, 4, 18, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 18, 4, 51, 10, 10, 10, 10, 10, 4, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 4, 10, 10, 10, 10, 10, 10, 4, 0, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 4, 10, 10, 10, 10, 10, 10, 4, 0, 0, 0, 0, 0, 11, 11, 0, 0, 0, 0, 0, 4, 10, 10, 10, 10, 10, 10, 4, 0, 0, 0, 0, 0, 11, 11, 0, 0, 0, 0, 0, 4, 10, 10, 10, 10, 10, 10, 4, 0, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 4, 10, 10, 10, 10, 10, 10, 4, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 4, 10, 10, 10, 10, 10, 10, 4, 0, 0, 0, 15, 10, 16, 17, 10, 15, 0, 0, 0, 4, 10, 10, 10, 1, 1, 1, 5, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 8, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
}
if (_root.mission == 36) {
map.push(15, 0, 0, 0, 18, 7, 3, 3, 3, 3, 3, 3, 3, 6, 18, 0, 0, 0, 0, 15, 10, 10, 0, 0, 0, 4, 20, 20, 20, 20, 20, 20, 20, 4, 0, 0, 0, 0, 10, 10, 0, 0, 0, 11, 0, 4, 2, 2, 2, 2, 2, 2, 2, 4, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 2, 2, 2, 2, 2, 2, 2, 4, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 3, 3, 6, 2, 2, 2, 2, 7, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 20, 20, 20, 20, 4, 2, 2, 2, 2, 4, 20, 20, 20, 20, 0, 0, 0, 50, 15, 0, 0, 0, 0, 0, 9, 3, 3, 3, 3, 9, 0, 0, 0, 0, 0, 15, 51, 18, 0, 0, 0, 0, 0, 0, 4, 20, 20, 20, 20, 4, 0, 0, 0, 0, 0, 0, 18, 0, 0, 0, 20, 20, 20, 20, 4, 2, 2, 2, 2, 4, 20, 20, 20, 20, 0, 0, 0, 3, 3, 3, 3, 3, 3, 3, 8, 2, 2, 2, 2, 5, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 11, 0, 4, 2, 2, 2, 2, 2, 2, 2, 2, 4, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 2, 2, 2, 2, 2, 2, 2, 2, 4, 0, 0, 0, 0, 0, 10, 10, 0, 0, 18, 5, 3, 3, 3, 3, 3, 3, 3, 3, 8, 18, 0, 0, 10, 10, 15, 0, 0, 0, 0, 2, 20, 20, 20, 20, 20, 20, 20, 20, 2, 0, 0, 0, 0, 15);
}
if (_root.mission == 37) {
map.push(70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 2, 2, 2, 21, 2, 70, 16, 51, 18, 70, 70, 15, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 2, 2, 21, 70, 70, 70, 70, 70, 70, 70, 70, 70, 73, 70, 73, 70, 15, 15, 70, 70, 70, 70, 2, 70, 70, 72, 70, 70, 70, 70, 73, 70, 70, 73, 70, 70, 73, 70, 70, 70, 70, 70, 70, 70, 70, 70, 72, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 73, 70, 70, 70, 70, 2, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 72, 70, 70, 70, 70, 70, 70, 70, 2, 2, 70, 70, 70, 70, 70, 70, 72, 70, 73, 70, 15, 70, 70, 70, 70, 70, 70, 70, 21, 2, 2, 71, 71, 70, 70, 70, 70, 70, 72, 73, 70, 70, 70, 70, 70, 70, 70, 70, 2, 2, 2, 2, 2, 71, 70, 72, 70, 72, 72, 70, 73, 70, 70, 70, 70, 72, 70, 70, 2, 2, 2, 2, 2, 2, 70, 70, 15, 70, 72, 72, 73, 70, 70, 70, 72, 70, 70, 70, 2, 2, 21, 2, 2, 21, 70, 70, 15, 70, 73, 70, 70, 70, 70, 70, 70, 70, 70, 70, 2, 2, 2, 2, 2, 2, 2, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 2, 2, 2, 2, 2, 2, 2, 2, 70, 70, 70, 70, 70, 70, 15, 70, 70, 18, 50, 16, 21, 2, 2, 2, 2, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70);
}
if (_root.mission == 38) {
map.push(2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 10, 51, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 15, 0, 0, 15, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 18, 11, 0, 0, 0, 0, 11, 18, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 2, 1, 1, 1, 1, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 2, 30, 1, 1, 1, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 2, 30, 1, 1, 30, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 2, 1, 1, 1, 30, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 2, 1, 1, 1, 1, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 18, 11, 0, 0, 0, 0, 11, 18, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 15, 0, 0, 15, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 50, 10, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2);
}
if (_root.mission == 39) {
map.push(10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 11, 11, 11, 11, 11, 11, 11, 11, 0, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 11, 11, 2, 2, 2, 2, 2, 2, 11, 11, 0, 0, 0, 0, 10, 10, 0, 0, 0, 11, 11, 2, 2, 2, 2, 2, 2, 2, 2, 11, 11, 0, 0, 0, 10, 10, 0, 0, 11, 11, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 11, 11, 0, 0, 10, 10, 18, 0, 11, 2, 2, 2, 2, 2, 10, 10, 2, 2, 2, 2, 2, 11, 0, 18, 10, 50, 0, 0, 18, 2, 2, 2, 2, 10, 16, 17, 10, 2, 2, 2, 2, 18, 0, 0, 51, 10, 18, 0, 11, 2, 2, 2, 2, 10, 11, 11, 10, 2, 2, 2, 2, 11, 0, 18, 10, 10, 0, 0, 11, 2, 2, 2, 2, 2, 10, 10, 2, 2, 2, 2, 2, 11, 0, 0, 10, 10, 0, 0, 11, 11, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 11, 11, 0, 0, 10, 10, 0, 0, 0, 11, 11, 2, 2, 2, 2, 2, 2, 2, 2, 11, 11, 0, 0, 0, 10, 10, 0, 0, 0, 0, 11, 11, 2, 2, 2, 2, 2, 2, 11, 11, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 11, 11, 11, 11, 11, 11, 11, 11, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10);
}
if (_root.mission == 40) {
map.push(2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 70, 73, 2, 2, 2, 2, 73, 73, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 70, 70, 70, 73, 2, 2, 70, 72, 73, 73, 2, 2, 2, 2, 2, 2, 2, 2, 2, 70, 51, 70, 70, 70, 18, 18, 70, 70, 72, 50, 73, 2, 2, 2, 2, 2, 2, 2, 2, 70, 18, 70, 70, 70, 70, 70, 70, 70, 72, 18, 73, 2, 2, 2, 2, 2, 2, 2, 2, 70, 70, 70, 70, 70, 70, 70, 70, 72, 72, 73, 73, 2, 2, 2, 2, 2, 2, 2, 2, 2, 70, 70, 70, 70, 70, 70, 70, 72, 73, 73, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 70, 70, 70, 70, 70, 72, 73, 73, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 70, 70, 70, 72, 73, 73, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 70, 72, 73, 73, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 73, 73, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 73, 73, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2);
}
if (_root.mission == 41) {
map.push(2, 11, 11, 11, 2, 2, 10, 10, 10, 2, 2, 11, 11, 11, 2, 2, 0, 0, 0, 2, 2, 11, 15, 0, 3, 3, 0, 18, 10, 3, 3, 0, 15, 0, 3, 3, 0, 18, 50, 2, 2, 11, 0, 11, 2, 2, 10, 10, 10, 2, 2, 11, 0, 11, 2, 2, 0, 0, 0, 2, 2, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 11, 0, 11, 2, 2, 11, 11, 11, 2, 2, 11, 0, 11, 2, 2, 11, 11, 11, 2, 2, 11, 15, 0, 3, 3, 0, 15, 0, 3, 3, 0, 15, 0, 3, 3, 0, 15, 11, 2, 2, 11, 11, 11, 2, 2, 11, 0, 11, 2, 2, 11, 11, 11, 2, 2, 11, 0, 11, 2, 2, 2, 2, 2, 2, 2, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 2, 2, 2, 0, 0, 0, 2, 2, 11, 0, 11, 2, 2, 10, 10, 10, 2, 2, 11, 0, 11, 2, 2, 51, 18, 0, 3, 3, 0, 15, 0, 3, 3, 10, 18, 0, 3, 3, 0, 15, 11, 2, 2, 0, 0, 0, 2, 2, 11, 11, 11, 2, 2, 10, 10, 10, 2, 2, 11, 11, 11, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2);
}
if (_root.mission == 99) {
i = 0;
while (i < 280) {
map.push(map99[i]);
i++;
}
}
function NoPlayerUnitsCondition() {
var _local2 = 0;
var _local3 = 0;
_local2 = 0;
while (_local2 < 25) {
if (_root["unit" + _local2].team == 0) {
_local3++;
}
_local2++;
}
if (_local3 == 0) {
_root.gotoAndPlay("gameover");
}
}
function NoEnemyUnitsCondition() {
if (_root.myEnemy.myUnits.length == 0) {
_root.gotoAndPlay("victory");
}
}
function LaserFire() {
var _local2 = new Array();
var _local3;
if (random(20) == 19) {
i = 0;
while (i < 25) {
if (_root["unit" + i] != undefined) {
if (_root["unit" + i]._alpha == 100) {
_local2.push(i);
}
}
i++;
}
_local3 = _local2[random(_local2.length)];
_root["unit" + myrand].removeMovieClip();
}
}
function HQCaptured() {
var _local2;
_local2 = 0;
while (_local2 < 280) {
if ((_root["t" + _local2].myName == "Allied HQ") && (_root["t" + _local2].city_owner != 0)) {
_root.gotoAndPlay("gameover");
}
if ((_root["t" + _local2].myName == "Chinese HQ") && (_root["t" + _local2].city_owner != 1)) {
_root.gotoAndPlay("victory");
}
_local2++;
}
}
function CheckEvents(nextDay) {
var _local2 = 0;
if (_root.mission <= 9) {
switch (int(_root.mission + 1)) {
case 1 :
NoEnemyUnitsCondition();
NoPlayerUnitsCondition();
if ((((_root.selectedUnit.team == 0) && (_root.day == 1)) && (_root.myAdvisor == undefined)) && (_root.phase == 0)) {
_root.attachMovie("advisor", "myAdvisor", 3100, {seq:11});
_root.phase = 1;
}
if (_root.phase == 1) {
_local2 = 1;
while (_local2 <= 4) {
if (_root["t" + int(_root["unit" + _local2].tile)].myName == "road") {
_root.attachMovie("advisor", "myAdvisor", 3100, {seq:16});
_root.phase = 2;
}
_local2++;
}
}
if (_root.phase == 2) {
_local2 = 1;
while (_local2 <= 4) {
if (_root["unit" + _local2].entrenched == true) {
_root.attachMovie("advisor", "myAdvisor", 3100, {seq:21});
_root.phase = 3;
}
_local2++;
}
}
if (_root.phase == 3) {
if ((_root.selectedUnit != undefined) && (_root.selectedUnit.team == 0)) {
_local2 = 1500;
while (_local2 < 1600) {
if (_root["m" + _local2].hitTest(_root.t133)) {
_root.attachMovie("advisor", "myAdvisor", 3100, {seq:25});
_root.phase = 4;
}
_local2++;
}
}
}
if ((_root.t133.city_hp < 200) && (_root.phase == 4)) {
_root.attachMovie("advisor", "myAdvisor", 3100, {seq:32});
_root.phase = 5;
}
if ((_root.t133.city_owner == 0) && (_root.phase == 5)) {
_root.attachMovie("advisor", "myAdvisor", 3100, {seq:34});
_root.phase = 6;
}
if ((_root.phase == 6) && (_root.selectedUnit.team == 0)) {
_local2 = 0;
while (_local2 < 10) {
if (_root["a" + _local2].owner.team == 1) {
_root.attachMovie("advisor", "myAdvisor", 3100, {seq:37});
_root.phase = 7;
break;
}
_local2++;
}
}
if (((_root.phase == 7) && (_root.intelUnit.team == 0)) && (_root.intelUnit.attacked == true)) {
_root.attachMovie("advisor", "myAdvisor", 3100, {seq:40});
_root.phase = 8;
}
break;
case 2 :
if (nextDay == true) {
if (_root.unit12.unitType == "air") {
_root.unit12._x = _root.unit12._x + 60;
_root.unit12.FindTile();
}
if (_root.unit12._x >= 600) {
gotoAndPlay ("victory");
}
if ((_root.unit12 == undefined) | (_root.unit11 == undefined)) {
gotoAndPlay ("gameover");
}
}
if (_root.unit11.tile == 67) {
_root.unit12.unitType = "air";
_root.unit12.gotoAndPlay("air");
_root.attachMovie("advisor", "myAdvisor", 3100, {seq:5});
_root.unit11._alpha = 0;
_root.unit11.team = 100;
_root.unit11._x = -30;
_root.unit11.FindTile();
}
break;
case 3 :
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
break;
case 4 :
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
break;
case 5 :
HQCaptured();
break;
case 6 :
if ((_root.cash >= 75000) && (_root.unit99._currentframe <= 4)) {
_root.launchDay = int(_root.day + 14);
_root.unit99.gotoAndPlay("burn");
_root.cash = int(_root.cash) - 75000;
_root.attachMovie("advisor", "myAdvisor", 3100, {seq:12});
}
if ((_root.launchDay == _root.day) && (true == nextDay)) {
_root.unit99.gotoAndPlay("air");
}
if ((nextDay == true) && (int(_root.day % 10) == 0)) {
_root.enemycash = 100000 /* 0x0186A0 */;
_root.selectedBuild = _root.t60;
_root.buildUnit("red_infantry", 1, "foot", "infantry", true);
_root.selectedBuild = _root.t80;
_root.buildUnit("red_infantry", 1, "foot", "infantry", true);
_root.selectedBuild = _root.t100;
_root.buildUnit("red_infantry", 1, "foot", "infantry", true);
_root.selectedBuild = _root.t160;
_root.buildUnit("red_tank", 1, "track", "tank", true);
_root.selectedBuild = _root.t180;
_root.buildUnit("red_tank", 1, "track", "tank", true);
_root.selectedBuild = _root.t200;
_root.buildUnit("red_tank", 1, "track", "tank", true);
_root.selectedBuild = _root.t5;
_root.buildUnit("red_helicopter", 1, "air", "helicopter", true);
_root.selectedBuild = _root.t265;
_root.buildUnit("red_helicopter", 1, "air", "helicopter", true);
}
break;
case 7 :
if (nextDay == true) {
LaserFire();
}
HQCaptured();
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
break;
case 8 :
HQCaptured();
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
break;
case 9 :
if (nextDay == true) {
LaserFire();
}
HQCaptured();
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
break;
case 10 :
_local2 = 28;
while (_local2 <= 33) {
if (_root["t" + _root["unit" + _local2].tile].waypoint == true) {
_root.gotoAndPlay("gameover");
}
_local2++;
}
_root.t17.waypoint = true;
_root.t37.waypoint = true;
_root.t57.waypoint = true;
_root.t77.waypoint = true;
_root.t96.waypoint = true;
_root.t116.waypoint = true;
_root.t137.waypoint = true;
_root.t157.waypoint = true;
_root.t177.waypoint = true;
_root.t197.waypoint = true;
_root.t217.waypoint = true;
_root.t237.waypoint = true;
_root.t256.waypoint = true;
_root.t276.waypoint = true;
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
}
}
if (_root.mission >= 10) {
switch (int(_root.mission + 1)) {
case 11 :
HQCaptured();
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
break;
case 12 :
HQCaptured();
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
break;
case 13 :
HQCaptured();
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
break;
case 14 :
HQCaptured();
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
break;
case 15 :
HQCaptured();
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
break;
case 16 :
HQCaptured();
NoPlayerUnitsCondition();
break;
case 17 :
HQCaptured();
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
break;
case 18 :
HQCaptured();
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
break;
case 19 :
HQCaptured();
NoPlayerUnitsCondition();
NoEnemyUnitsCondition();
}
}
if (_root.mission >= 30) {
HQCaptured();
}
}
function reset() {
var _local2;
_root.cash = 0;
_root.enemycash = 0;
_root.selectedUnit.Deselect();
_root.blocker.removeMovieClip();
_local2 = 0;
while (_local2 <= 290) {
_root["unit" + _local2].removeMovieClip();
_root["t" + _local2].removeMovieClip();
_local2++;
}
day = 1;
lock = false;
moved = false;
stopAllSounds();
play();
}
function buildMap() {
var _local2;
var _local4 = 0;
var _local5 = 0;
var _local7 = 100;
clearMap();
if (_root.fow == true) {
_local7 = 50;
}
_local2 = 0;
while (_local2 <= map.length) {
_root.attachMovie(map[_local2], "t" + _local2, _local2, {_alpha:_local7});
var _local3 = map[_local2];
if (_local3 == 0) {
_root["t" + _local2].myName = "grass";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].defenceBonus = 1;
}
if (_local3 == 1) {
_root["t" + _local2].myName = "desert";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].defenceBonus = 1;
}
if (_local3 == 2) {
_root["t" + _local2].myName = "sea";
_root["t" + _local2].byFoot = false;
_root["t" + _local2].byWheel = false;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = true;
_root["t" + _local2].defenceBonus = 1;
_root["t" + _local2].movementCost = 1;
}
if (_local3 == 20) {
_root["t" + _local2].myName = "sea";
_root["t" + _local2].byFoot = false;
_root["t" + _local2].byWheel = false;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = true;
_root["t" + _local2].defenceBonus = 1;
_root["t" + _local2].movementCost = 1;
}
if (_local3 == 21) {
_root["t" + _local2].myName = "sea";
_root["t" + _local2].byFoot = false;
_root["t" + _local2].byWheel = false;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = true;
_root["t" + _local2].defenceBonus = 1;
_root["t" + _local2].movementCost = 1;
}
if (_local3 == 22) {
_root["t" + _local2].myName = "coast";
_root["t" + _local2].byFoot = false;
_root["t" + _local2].byWheel = false;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = true;
_root["t" + _local2].defenceBonus = 1;
_root["t" + _local2].movementCost = 1;
}
if (_local3 == 23) {
_root["t" + _local2].myName = "coast";
_root["t" + _local2].byFoot = false;
_root["t" + _local2].byWheel = false;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = true;
_root["t" + _local2].defenceBonus = 1;
_root["t" + _local2].movementCost = 1;
}
if (_local3 == 24) {
_root["t" + _local2].myName = "coast";
_root["t" + _local2].byFoot = false;
_root["t" + _local2].byWheel = false;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = true;
_root["t" + _local2].defenceBonus = 1;
_root["t" + _local2].movementCost = 1;
}
if (_local3 == 26) {
_root["t" + _local2].myName = "coast";
_root["t" + _local2].byFoot = false;
_root["t" + _local2].byWheel = false;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = true;
_root["t" + _local2].defenceBonus = 1;
_root["t" + _local2].movementCost = 1;
}
if (_local3 == 23) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 24) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 25) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 4) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 3) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 4) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 5) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 6) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 7) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 8) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 9) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 26) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 27) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 28) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 9) {
_root["t" + _local2].myName = "road";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].priority = 1.5;
}
if (_local3 == 10) {
_root["t" + _local2].myName = "mountain";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = false;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 4;
_root["t" + _local2].defenceBonus = 4;
}
if (_local3 == 30) {
_root["t" + _local2].myName = "mountain";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = false;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 4;
_root["t" + _local2].defenceBonus = 4;
}
if (_local3 == 11) {
_root["t" + _local2].myName = "forest";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 2;
_root["t" + _local2].defenceBonus = 2;
}
if (_local3 == 15) {
_root["t" + _local2].myName = "city";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 3;
_root["t" + _local2].city = true;
}
if (_local3 == 16) {
_root["t" + _local2].myName = "airport";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 3;
_root["t" + _local2].airport = true;
_root["t" + _local2].city = true;
}
if (_local3 == 17) {
_root["t" + _local2].myName = "runway";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
}
if (_local3 == 18) {
_root["t" + _local2].myName = "factory";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 0;
_root["t" + _local2].city = true;
_root["t" + _local2].factory = true;
}
if (_local3 == 25) {
_root["t" + _local2].myName = "derrick";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 2;
_root["t" + _local2].defenceBonus = 3;
_root["t" + _local2].city = true;
_root["t" + _local2].derrick = true;
}
if (_local3 == 50) {
_root["t" + _local2].myName = "Allied HQ";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 4;
_root["t" + _local2].city = true;
_root["t" + _local2].city_owner = 0;
_root["t" + _local2].hq = true;
}
if (_local3 == 51) {
_root["t" + _local2].myName = "Chinese HQ";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 1;
_root["t" + _local2].defenceBonus = 4;
_root["t" + _local2].city = true;
_root["t" + _local2].city_owner = 1;
_root["t" + _local2].hq = true;
}
if (_local3 == 70) {
_root["t" + _local2].myName = "snow";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 2;
_root["t" + _local2].defenceBonus = 1;
}
if (_local3 == 71) {
_root["t" + _local2].myName = "snow";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 2;
_root["t" + _local2].defenceBonus = 1;
}
if (_local3 == 72) {
_root["t" + _local2].myName = "forest";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 2;
_root["t" + _local2].defenceBonus = 2;
}
if (_local3 == 73) {
_root["t" + _local2].myName = "mountain";
_root["t" + _local2].byFoot = true;
_root["t" + _local2].byWheel = true;
_root["t" + _local2].byAir = true;
_root["t" + _local2].bySea = false;
_root["t" + _local2].movementCost = 4;
_root["t" + _local2].defenceBonus = 4;
}
_root["t" + _local2]._x = _local4;
_root["t" + _local2]._y = int(_local5);
_local4 = _local4 + 30;
if (_local4 >= 600) {
_local4 = 0;
_local5 = int(_local5 + 30);
}
_local2++;
}
}
function getDistance(a, b) {
var _local7 = a._x;
var _local4 = b._x;
var _local5 = a._y;
var _local3 = b._y;
var _local2 = Math.abs(_local7 - _local4);
var _local1 = Math.abs(_local5 - _local3);
var _local6 = Math.sqrt((_local2 * _local2) + (_local1 * _local1));
return(_local6);
}
function getDistanceX(a, b) {
var _local4 = a._x;
var _local2 = b._x;
var _local1 = Math.abs(_local4 - _local2);
var _local3 = Math.sqrt(_local1 * _local1);
return(_local3);
}
function getDistanceY(a, b) {
var _local3 = a._y;
var _local2 = b._y;
var _local1 = Math.abs(_local3 - _local2);
var _local4 = Math.sqrt(_local1 * _local1);
return(_local4);
}
function VisableArea() {
var _local2;
var _local3;
j = 0;
while (j < 280) {
if (_root.fow == true) {
_root["t" + j]._alpha = 50;
} else {
_root["t" + j]._alpha = 100;
}
_root["t" + j].playerOn = false;
j++;
}
if (_root.fow == true) {
i = 0;
while (i < 100) {
if (_root["unit" + i].team == 0) {
row = int(_root["unit" + i]._y / 30);
col = int(_root["unit" + i]._x / 30);
tile = int((row * 20) + col);
switch (_root["unit" + i].los) {
case 1 :
_root["t" + tile]._alpha = 100;
checkEdge(tile, 1, true);
checkEdge(tile, -1, true);
checkEdge(tile, 20, true);
checkEdge(tile, -20, true);
break;
case 2 :
_root["t" + tile]._alpha = 100;
checkEdge(tile, 1, true);
checkEdge(tile, -1, true);
checkEdge(tile, 2);
checkEdge(tile, -2);
checkEdge(tile, -19);
checkEdge(tile, 19);
checkEdge(tile, -21);
checkEdge(tile, 21);
checkEdge(tile, 20, true);
checkEdge(tile, -20, true);
checkEdge(tile, 40);
checkEdge(tile, -40);
break;
case 3 :
_root["t" + tile]._alpha = 100;
checkEdge(tile, 1, true);
checkEdge(tile, -1, true);
checkEdge(tile, 2);
checkEdge(tile, -2);
checkEdge(tile, 3);
checkEdge(tile, -3);
checkEdge(tile, -18);
checkEdge(tile, 18);
checkEdge(tile, -19);
checkEdge(tile, 19);
checkEdge(tile, -21);
checkEdge(tile, 21);
checkEdge(tile, -22);
checkEdge(tile, 22);
checkEdge(tile, -39);
checkEdge(tile, 39);
checkEdge(tile, -41);
checkEdge(tile, 41);
checkEdge(tile, 20, true);
checkEdge(tile, -20, true);
checkEdge(tile, -40);
checkEdge(tile, 40);
checkEdge(tile, 60);
checkEdge(tile, -60);
break;
case 4 :
_root["t" + tile]._alpha = 100;
checkEdge(tile, 1, true);
checkEdge(tile, -1, true);
checkEdge(tile, 2);
checkEdge(tile, -2);
checkEdge(tile, 3);
checkEdge(tile, -3);
checkEdge(tile, 4);
checkEdge(tile, -4);
checkEdge(tile, -17);
checkEdge(tile, 17);
checkEdge(tile, -18);
checkEdge(tile, 18);
checkEdge(tile, -19);
checkEdge(tile, 19);
checkEdge(tile, -21);
checkEdge(tile, 21);
checkEdge(tile, -22);
checkEdge(tile, 22);
checkEdge(tile, -23);
checkEdge(tile, 23);
checkEdge(tile, -38);
checkEdge(tile, 38);
checkEdge(tile, -39);
checkEdge(tile, 39);
checkEdge(tile, -41);
checkEdge(tile, 41);
checkEdge(tile, -42);
checkEdge(tile, 42);
checkEdge(tile, -61);
checkEdge(tile, 61);
checkEdge(tile, -59);
checkEdge(tile, 59);
checkEdge(tile, 20, true);
checkEdge(tile, -20, true);
checkEdge(tile, -40);
checkEdge(tile, 40);
checkEdge(tile, 60);
checkEdge(tile, -60);
checkEdge(tile, -80);
checkEdge(tile, 80);
break;
case 5 :
_root["t" + tile]._alpha = 100;
checkEdge(tile, 1, true);
checkEdge(tile, -1, true);
checkEdge(tile, 2);
checkEdge(tile, -2);
checkEdge(tile, 3);
checkEdge(tile, -3);
checkEdge(tile, 4);
checkEdge(tile, -4);
checkEdge(tile, 5);
checkEdge(tile, -5);
checkEdge(tile, -16);
checkEdge(tile, 16);
checkEdge(tile, -17);
checkEdge(tile, 17);
checkEdge(tile, -18);
checkEdge(tile, 18);
checkEdge(tile, -19);
checkEdge(tile, 19);
checkEdge(tile, -21);
checkEdge(tile, 21);
checkEdge(tile, -22);
checkEdge(tile, 22);
checkEdge(tile, -23);
checkEdge(tile, 23);
checkEdge(tile, -24);
checkEdge(tile, 24);
checkEdge(tile, -37);
checkEdge(tile, 37);
checkEdge(tile, -38);
checkEdge(tile, 38);
checkEdge(tile, -39);
checkEdge(tile, 39);
checkEdge(tile, -41);
checkEdge(tile, 41);
checkEdge(tile, -42);
checkEdge(tile, 42);
checkEdge(tile, -43);
checkEdge(tile, 43);
checkEdge(tile, -62);
checkEdge(tile, 62);
checkEdge(tile, -61);
checkEdge(tile, 61);
checkEdge(tile, -59);
checkEdge(tile, 59);
checkEdge(tile, -58);
checkEdge(tile, 58);
checkEdge(tile, -79);
checkEdge(tile, 79);
checkEdge(tile, -81);
checkEdge(tile, 81);
checkEdge(tile, 20, true);
checkEdge(tile, -20, true);
checkEdge(tile, -40);
checkEdge(tile, 40);
checkEdge(tile, 60);
checkEdge(tile, -60);
checkEdge(tile, -80);
checkEdge(tile, 80);
checkEdge(tile, 100);
checkEdge(tile, -100);
}
}
i++;
}
}
l = 0;
while (l <= 99) {
if (_root["unit" + l].team == 0) {
_root["unit" + l].FindTile();
}
l++;
}
forestCleanup();
l = 0;
while (l <= 99) {
if (_root["unit" + l].team == 1) {
if (_root["t" + _root["unit" + l].tile]._alpha == 50) {
_root["unit" + l]._alpha = 0;
} else {
_root["unit" + l]._alpha = 100;
}
}
l++;
}
}
function checkEdge(tile, num, viewable) {
if (getDistanceX(_root["t" + int(tile + num)], _root["t" + tile]) <= 250) {
if ((_root["t" + int(tile + num)].myName == "forest") && (viewable == false)) {
_root["t" + int(tile + num)]._alpha = 50;
} else {
_root["t" + int(tile + num)]._alpha = 100;
}
}
}
function forestCleanup() {
i = 0;
while (i < 280) {
if (_root["t" + i].myName == "forest") {
if (((((_root["t" + int(i + 1)].playerOn == false) && (_root["t" + int(i - 1)].playerOn == false)) && (_root["t" + int(i - 20)].playerOn == false)) && (_root["t" + int(i + 20)].playerOn == false)) && (_root["t" + int(i)].playerOn == false)) {
_root["t" + i]._alpha = 50;
} else {
_root["t" + i]._alpha = 100;
}
}
i++;
}
}
function endmove() {
_root.moved = true;
_root.int_capturing.removeMovieClip();
_root.CheckEvents(true);
_root.wait.gotoAndPlay("open");
_root.attachMovie("blocker", "blocker", 3099);
_root.myEnemy.Assess();
}
function endturn() {
var _local2 = 0;
var _local3 = 0;
_root.moved = false;
i = 0;
while (i <= 280) {
if (_root["t" + i].city_owner == 0) {
if (_root["t" + i].city == true) {
j = 0;
while (j <= 50) {
if ((_root["unit" + j].tile == i) && (_root["unit" + j].team == 0)) {
_root["unit" + j].resupply();
_root["unit" + j].repair();
_root["unit" + j].refuel();
}
j++;
}
if (_root["t" + i].hq == false) {
_local2 = int(_local2) + 1000;
}
}
if (_root["t" + i].derrick == true) {
_local2 = int(_local2) + 3000;
}
}
if (_root["t" + i].city_owner == 1) {
if (_root["t" + i].city == true) {
j = 0;
while (j <= 100) {
if ((_root["unit" + j].tile == i) && (_root["unit" + j].team == 1)) {
_root["unit" + j].resupply();
_root["unit" + j].repair();
_root["unit" + j].refuel();
}
j++;
}
if (_root["t" + i].hq == false) {
_local3 = int(_local3) + 1000;
}
}
if (_root["t" + i].derrick == true) {
_local3 = int(_local2) + 3000;
}
}
i++;
}
_root.cash = int(_root.cash) + int(_local2);
_root.enemycash = int(_root.enemycash) + int(_local3);
tstat_player_cash = int(tstat_player_cash) + int(_local2);
tstat_com_cash = int(tstat_com_cash) + int(_local3);
_root.reStock();
_root.checkFuel();
_root.wait.gotoAndPlay("close");
_root.attachMovie("int_endday", "int_endday", 2950);
i = 0;
while (i < 100) {
_root["unit" + i].moves_left = _root["unit" + i].moves_total;
if ((_root["unit" + i]._alpha == 0) && (_root["unit" + i].team == 0)) {
_root["unit" + i].moves_left = 2;
}
_root["unit" + i].attacked = false;
i++;
}
_root.blocker.removeMovieClip();
_root.CheckEvents();
_root.day = _root.day + 1;
}
function reStock() {
var _local4;
var _local5;
var _local3;
var _local2;
_local3 = 0;
while (_local3 < 75) {
if (_root["unit" + _local3].unitClass == "apc") {
_local4 = _root["unit" + _local3].tile;
_local5 = _root["unit" + _local3].team;
_local2 = 0;
while (_local2 < 75) {
if (_root["t" + int(_local4 + 1)].hitTest(_root["unit" + _local2])) {
if (_root["unit" + _local2].team == _root["unit" + _local3].team) {
_root["unit" + _local2].refuel();
_root["unit" + _local2].resupply();
}
}
if (_root["t" + int(_local4 - 1)].hitTest(_root["unit" + _local2])) {
if (_root["unit" + _local2].team == _root["unit" + _local3].team) {
_root["unit" + _local2].refuel();
_root["unit" + _local2].resupply();
}
}
if (_root["t" + int(_local4 - 20)].hitTest(_root["unit" + _local2])) {
if (_root["unit" + _local2].team == _root["unit" + _local3].team) {
_root["unit" + _local2].refuel();
_root["unit" + _local2].resupply();
}
}
if (_root["t" + int(_local4 + 20)].hitTest(_root["unit" + _local2])) {
if (_root["unit" + _local2].team == _root["unit" + _local3].team) {
_root["unit" + _local2].refuel();
_root["unit" + _local2].resupply();
}
}
_local2++;
}
}
if (_root["unit" + _local3].unitClass == "carrier") {
_local4 = _root["unit" + _local3].tile;
_local5 = _root["unit" + _local3].team;
_local2 = 0;
while (_local2 < 75) {
if (_root["t" + int(_local4 + 1)].hitTest(_root["unit" + _local2])) {
if ((_root["unit" + _local2].team == _root["unit" + _local3].team) && (_root["unit" + _local2].unitType == "air")) {
_root["unit" + _local2].refuel();
_root["unit" + _local2].resupply();
}
}
if (_root["t" + int(_local4 - 1)].hitTest(_root["unit" + _local2])) {
if ((_root["unit" + _local2].team == _root["unit" + _local3].team) && (_root["unit" + _local2].unitType == "air")) {
_root["unit" + _local2].refuel();
_root["unit" + _local2].resupply();
}
}
if (_root["t" + int(_local4 - 20)].hitTest(_root["unit" + _local2])) {
if ((_root["unit" + _local2].team == _root["unit" + _local3].team) && (_root["unit" + _local2].unitType == "air")) {
_root["unit" + _local2].refuel();
_root["unit" + _local2].resupply();
}
}
if (_root["t" + int(_local4 + 20)].hitTest(_root["unit" + _local2])) {
if ((_root["unit" + _local2].team == _root["unit" + _local3].team) && (_root["unit" + _local2].unitType == "air")) {
_root["unit" + _local2].refuel();
_root["unit" + _local2].resupply();
}
}
_local2++;
}
}
_local3++;
}
}
function checkFuel() {
i = 0;
while (i < 75) {
if ((_root["unit" + i].unitType == "air") && (_root["unit" + i].fuel <= 0)) {
_root["unit" + i].removeMovieClip();
}
i++;
}
}
function buildUnit(unit, team, unitType, unitClass, override) {
var _local3 = false;
var _local9 = 0;
var _local8 = 25;
var _local2 = 0;
if (team == 1) {
_local9 = 25;
_local8 = 50;
} else {
_local9 = 0;
_local8 = 25;
}
_local2 = _local9;
while (_local2 < _local8) {
if (_root["unit" + _local2] == undefined) {
_root.attachMovie(unit, "unit" + _local2, int(2200 + _local2), {unitType:unitType, unitClass:unitClass});
_root["unit" + _local2]._x = _root.selectedBuild._x;
_root["unit" + _local2]._y = _root.selectedBuild._y;
_root["unit" + _local2].FindTile();
if (team == 0) {
_root["unit" + _local2].moves_left = 0;
_root["unit" + _local2].attacked = true;
}
_root["unit" + _local2].moved = true;
_root["unit" + _local2].team = team;
if (team == 0) {
if (_root.cash >= _root["unit" + _local2].cost) {
_root.cash = int(_root.cash) - _root["unit" + _local2].cost;
_local3 = true;
} else {
_root.attachMovie("int_nomoney", "int_nomoney", 3200);
_root["unit" + _local2].removeMovieClip();
_local3 = false;
}
} else {
if (((_root["unit" + _local2].unitType == "air") && (_root.selectedBuild.airport != true)) && (override != true)) {
_root["unit" + _local2].removeMovieClip();
_local3 = false;
return(_local3);
}
if (((_root["unit" + _local2].unitType == "sea") && (_root.selectedBuild.seaport != true)) && (override != true)) {
_root["unit" + _local2].removeMovieClip();
_local3 = false;
return(_local3);
}
if ((((_root["unit" + _local2].unitType == "track") | (_root["unit" + _local2].unitType == "foot")) && (_root.selectedBuild.factory != true)) && (override != true)) {
_root["unit" + _local2].removeMovieClip();
_local3 = false;
return(_local3);
}
if ((team == 1) && (int(_root.enemycash) >= _root["unit" + _local2].cost)) {
_root.enemycash = int(_root.enemycash) - int(_root["unit" + _local2].cost);
_local3 = true;
} else {
_root["unit" + _local2].removeMovieClip();
_local3 = false;
}
}
if (_local3 == true) {
if (team == 0) {
tstat_player_built = int(tstat_player_built) + 1;
} else {
tstat_com_built = int(tstat_com_built) + 1;
}
}
return(_local3);
}
_local2++;
}
}
function updateIntel() {
if (_root.intelUnit.unitType == "air") {
interface_mc.int_inside.t_type.text = "sky";
interface_mc.int_inside.feed.gotoAndStop("air");
interface_mc.int_inside.defencebonus_mc.gotoAndStop(0);
} else {
interface_mc.int_inside.defencebonus_mc.gotoAndStop(_root["t" + _root.intelUnit.tile].defenceBonus + 1);
interface_mc.int_inside.t_type.text = _root["t" + _root.intelUnit.tile].myName;
interface_mc.int_inside.feed.gotoAndStop(_root["t" + _root.intelUnit.tile].myName);
}
if (_root._quality == "LOW") {
interface_mc.int_inside.feed.gotoAndStop(1);
}
interface_mc.int_inside.v_moves.text = (_root.intelUnit.moves_left + " / ") + _root.intelUnit.moves_total;
interface_mc.int_inside.v_type.text = _root.intelUnit.unitClass;
interface_mc.int_inside.v_ammo.text = _root.intelUnit.ammo;
interface_mc.int_inside.v_fuel.text = _root.intelUnit.fuel;
}
ASProf.begin("init");
Mouse.hide();
attachMovie("cursor", "cursor", 4005);
startDrag (cursor, true);
_root.lock = false;
_root.moved = false;
tstat_player_turns = 0;
tstat_player_captured = 0;
tstat_player_time = 0;
tstat_player_cash = 0;
tstat_player_lost = 0;
tstat_player_built = 0;
reset();
_level0.t154.waypoint = true;
buildMap();
placeUnits();
VisableArea();
var myEnemy = new Enemy();
_root.attachMovie("advisor", "myAdvisor", 3100);
_root.attachMovie("interface_day", "interface_mc", 3101, {_x:600});
_root.interface_mc.int_inside.onRollOver = function () {
if (opt_menuslide == true) {
_root.interface_mc.gotoAndPlay(2);
updateIntel();
}
};
_root.interface_mc.int_inside.onRollOut = function () {
if (opt_menuslide == true) {
_root.interface_mc.gotoAndPlay(21);
}
};
_root.interface_mc.int_inside.onPress = function () {
if (_root.interface_mc._currentframe != 19) {
_root.interface_mc.gotoAndPlay(10);
} else {
_root.interface_mc.gotoAndPlay(20);
}
updateIntel();
};
_root.attachMovie("briefing" + int(_root.mission + 1), "briefing_mc", 5100);
briefing_mc.onPress = function () {
_root.briefing_mc.removeMovieClip();
stopAllSounds();
_root.bgm = new Sound();
_root.bgm.attachSound("bgm" + int(random(4) + 1));
_root.bgm.setVolume(_root.music_vol);
_root.bgm.start(0, 999);
};
if (_root.mission >= 30) {
var i = 0;
var blueHQ;
var redHQ;
i = 0;
while (i < 280) {
if (_root["t" + i].city_owner == 1) {
redHQ = _root["t" + i];
}
if (_root["t" + i].city_owner == 0) {
blueHQ = _root["t" + i];
}
i++;
}
_root.attachMovie("blue_infantry", "unit0", 2200, {_x:blueHQ._x, _y:blueHQ._y, team:0, unitType:"foot", unitClass:"infantry"});
_root.attachMovie("red_infantry", "unit25", 2225, {_x:redHQ._x, _y:redHQ._y, team:1, unitType:"foot", unitClass:"infantry"});
}
ASProf.end();
_root.bgm.start(0, 999);
Frame 42
if (_root.profiled != true) {
ASProf.profile("AClass");
ASProf.profile("_root.buildMap");
ASProf.profile("_root.CheckEvents");
ASProf.profile("_root.CheckEvents");
ASProf.profile("_root.VisibleArea");
ASProf.profile("_root.myEnemy.Assess");
ASProf.profile("_root.myEnemy.Think");
ASProf.profile("_root.myEnemy.MoveUnit");
ASProf.profileObject("AClass.prototype");
_root.profiled = true;
}
_root.output.text = ASProf.getFlatGraph();
var MovedUnit = 0;
var TotalUnit = 0;
var EnemyUnitsNotMoved = 0;
EnemyUnitsNotMoved = 0;
TotalUnit = 0;
MovedUnit = 0;
if (_root.myEnemy == undefined) {
myEnemy = new Enemy();
}
i = 0;
while (i < 100) {
if (((((_root.lock == false) && (_root.moved == true)) && (_root["unit" + i].team == 1)) && (_root["unit" + i].moved == false)) && (_root["unit" + i] != undefined)) {
if (_root.selectedUnit.my_target == undefined) {
_root.myEnemy.Assess();
}
_root.selectedUnit.Deselect();
_root.selectedUnit = _root["unit" + i];
_root.myEnemy.MoveUnit(_root["unit" + i]);
Called = int(Called) + 1;
}
if ((_root["unit" + i].team == 1) && (_root["unit" + i].moved == true)) {
MovedUnit++;
}
if ((_root["unit" + i].team == 1) && (_root["unit" + i] != undefined)) {
TotalUnit++;
}
if (_root["unit" + i].destination != undefined) {
_root["unit" + i].MoveAnim();
}
i++;
}
if (((int(MovedUnit) == int(TotalUnit)) && (_root.moved == true)) && (_root.int_capture_china == undefined)) {
i = 0;
while (i < 100) {
if (_root["unit" + i].team == 1) {
EnemyUnitsNotMoved++;
if (_root["unit" + i].moved == true) {
EnemyUnitsNotMoved--;
_root["unit" + i].moved = false;
}
}
i++;
}
if (EnemyUnitsNotMoved == 0) {
_root.moved = false;
_root.selectedUnit.Deselect();
_root.endturn();
}
}
CheckEvents();
Frame 43
gotoAndPlay ("main");
Frame 44
interface_mc.removeMovieClip();
_root.myGameData.data.gameComplete = true;
_root.myGameData.data.flush();
stop();
Frame 45
_root.attachMovie("int_victory", "int_victory", 3500);
var date_end = new Date();
tstat_player_time = int(date_end.getTime()) - int(date_start.getTime());
stat_player_built = int(stat_player_built) + int(tstat_player_built);
stat_player_lost = int(stat_player_lost) + int(tstat_player_lost);
stat_player_cash = int(stat_player_cash) + int(tstat_player_cash);
stat_player_time = int(stat_player_time) + int(tstat_player_time);
stat_player_captured = int(stat_player_captured) + int(tstat_player_captured);
stat_player_turns = int(stat_player_turns) + int(tstat_player_turns);
stop();
Frame 46
_root.interface_mc.removeMovieClip();
_root.int_spin.removeMovieClip();
var date_end = new Date();
tstat_player_time = int(date_end.getTime()) - int(date_start.getTime());
stat_player_built = int(stat_player_built) + int(tstat_player_built);
stat_player_lost = int(stat_player_lost) + int(tstat_player_lost);
stat_player_cash = int(stat_player_cash) + int(tstat_player_cash);
stat_player_time = int(stat_player_time) + int(tstat_player_time);
stat_player_captured = int(stat_player_captured) + int(tstat_player_captured);
stat_player_turns = int(stat_player_turns) + int(tstat_player_turns);
myGameData.data.sfx_vol = _root.sfx_vol;
myGameData.data.music_vol = _root.music_vol;
myGameData.data.stat_player_lost = int(_root.stat_player_lost);
myGameData.data.stat_player_built = int(_root.stat_player_built);
myGameData.data.stat_player_captured = int(_root.stat_player_captured);
myGameData.data.stat_player_cash = int(_root.stat_player_cash);
myGameData.data.stat_player_time = int(_root.stat_player_time);
myGameData.data.stat_lose = int(myGameData.data.stat_lose) + 1;
myGameData.data.flush();
_root.reset();
_root.clearMap();
stop();
Instance of Symbol 324 MovieClip "quit" in Frame 46
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
on (press) {
_root.gotoAndPlay("menu");
}
Instance of Symbol 324 MovieClip "retry" in Frame 46
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
on (press) {
_root.gotoAndPlay("init");
}
Frame 47
if (myGameData.data.playername != undefined) {
_root.stat_player_built = myGameData.data.stat_player_built;
_root.stat_player_captured = myGameData.data.stat_player_captured;
_root.stat_player_cash = myGameData.data.stat_player_cash;
_root.stat_player_lost = myGameData.data.stat_player_lost;
_root.stat_player_time = myGameData.data.stat_player_time;
}
i = 1;
while (i <= 22) {
if (myGameData.data["award" + i] == true) {
_root["award" + i]._alpha = 100;
}
i++;
}
stop();
var PlayTime;
var time;
var seconds;
var minutes;
var hours;
var tsec;
var tmin;
var thour;
gamepercent.text = int((_root.myGameData.data.mission / 18) * 100) + "%";
time = int(_root.stat_player_time / 1000);
hours = int(time / 3600);
time = int(time) - int(hours * 3600);
minutes = int(time / 60);
time = int(time) - int(minutes * 60);
seconds = int(time);
if (seconds < 10) {
tsec = "0" + seconds.toString();
} else {
tsec = seconds.toString();
}
if (minutes < 10) {
tmin = "0" + minutes.toString();
} else {
tmin = minutes.toString();
}
if (hours < 10) {
thour = "0" + hours.toString();
} else {
thour = hours.toString();
}
_root.playtime = (((thour + ":") + tmin) + ":") + tsec;
stop();
mainmenu.onRollOver = function () {
mainmenu.gotoAndPlay("over");
};
mainmenu.onRollOut = function () {
mainmenu.gotoAndPlay("out");
};
Instance of Symbol 1209 MovieClip "award22" in Frame 47
on (rollOver) {
_root.medalname.text = "Diamond";
_root.medaldesc.text = "This medal is awarded for beating campaign mode without losing a battle!";
}
Instance of Symbol 1212 MovieClip "award21" in Frame 47
on (rollOver) {
_root.medalname.text = "Victory";
_root.medaldesc.text = "This medal is awarded for defeating the Chinese and beating campaign mode";
}
Instance of Symbol 1215 MovieClip "award20" in Frame 47
on (rollOver) {
_root.medalname.text = "Overtime";
_root.medaldesc.text = "This medal is awarded for playing over 20 missions";
}
Instance of Symbol 1218 MovieClip "award19" in Frame 47
on (rollOver) {
_root.medalname.text = "WorldFund";
_root.medaldesc.text = "This medal is awarded for earning 2,500,000 or more in your career";
}
Instance of Symbol 1221 MovieClip "award18" in Frame 47
on (rollOver) {
_root.medalname.text = "SecureSky";
_root.medaldesc.text = "This medal is awarded for launching the stratofighter from Camp David";
}
Instance of Symbol 1224 MovieClip "award17" in Frame 47
on (rollOver) {
_root.medalname.text = "Watchdog";
_root.medaldesc.text = "This medal is awarded for liberating South Korea";
}
Instance of Symbol 1227 MovieClip "award16" in Frame 47
on (rollOver) {
_root.medalname.text = "Cleanup";
_root.medaldesc.text = "This medal is awarded for eliminating more than 30 enemies in a mission";
}
Instance of Symbol 1230 MovieClip "award15" in Frame 47
on (rollOver) {
_root.medalname.text = "Protector";
_root.medaldesc.text = "This medal is awarded for rescuing the VIP's from Allenfort";
}
Instance of Symbol 1233 MovieClip "award14" in Frame 47
on (rollOver) {
_root.medalname.text = "Speed";
_root.medaldesc.text = "This medal is awarded for a mission victory in under 20 days";
}
Instance of Symbol 1236 MovieClip "award13" in Frame 47
on (rollOver) {
_root.medalname.text = "Liberty";
_root.medaldesc.text = "This medal is awarded for capturing more than 100 buildings";
}
Instance of Symbol 1239 MovieClip "award12" in Frame 47
on (rollOver) {
_root.medalname.text = "Command";
_root.medaldesc.text = "This medal is awarded for loosing less than 5 units in a mission";
}
Instance of Symbol 1242 MovieClip "award11" in Frame 47
on (rollOver) {
_root.medalname.text = "Flawless";
_root.medaldesc.text = "This ribbon is awarded for not loosing any units in a mission";
}
Instance of Symbol 1245 MovieClip in Frame 47
on (rollOver) {
_root.medalname.text = "Striker";
_root.medaldesc.text = "This ribbon is awarded for completing the campaign in under 3 hours";
}
Instance of Symbol 1248 MovieClip "award8" in Frame 47
on (rollOver) {
_root.medalname.text = "Militarist";
_root.medaldesc.text = "This ribbon is awarded for building more than 200 units";
}
Instance of Symbol 1251 MovieClip "award6" in Frame 47
on (rollOver) {
_root.medalname.text = "Dedication";
_root.medaldesc.text = "This ribbon is awarded for playing for more than 2 hours";
}
Instance of Symbol 1254 MovieClip "award3" in Frame 47
on (rollOver) {
_root.medalname.text = "Provider";
_root.medaldesc.text = "This ribbon is awarded for earning over 25,000 cash in your career";
}
Instance of Symbol 1257 MovieClip "award2" in Frame 47
on (rollOver) {
_root.medalname.text = "Growth";
_root.medaldesc.text = "This ribbon is awarded for capturing over 50 buildings";
}
Instance of Symbol 1260 MovieClip "award9" in Frame 47
on (rollOver) {
_root.medalname.text = "Economist";
_root.medaldesc.text = "This ribbon is awarded for earning more than 1,000,000 cash";
}
Instance of Symbol 1263 MovieClip "award7" in Frame 47
on (rollOver) {
_root.medalname.text = "ArmsRace";
_root.medaldesc.text = "This ribbon is awarded for playing for building more than 100 units";
}
Instance of Symbol 1266 MovieClip "award5" in Frame 47
on (rollOver) {
_root.medalname.text = "CallToArms";
_root.medaldesc.text = "This ribbon is awarded for building more than 20 units in your career";
}
Instance of Symbol 1269 MovieClip "award4" in Frame 47
on (rollOver) {
_root.medalname.text = "Graduate";
_root.medaldesc.text = "This ribbon is awarded for completing the first mission";
}
Instance of Symbol 1272 MovieClip "award1" in Frame 47
on (rollOver) {
_root.medalname.text = "Expansion";
_root.medaldesc.text = "This ribbon is awarded for capturing over 200 buildings";
}
Instance of Symbol 324 MovieClip "%complete" in Frame 47
on (press) {
_root.mission = 30;
_root.sample.gotoAndPlay(1);
_root.map.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "ratio" in Frame 47
on (press) {
_root.mission = 30;
_root.sample.gotoAndPlay(1);
_root.map.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "score" in Frame 47
on (press) {
_root.mission = 30;
_root.sample.gotoAndPlay(1);
_root.map.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "playtime" in Frame 47
on (press) {
_root.mission = 30;
_root.sample.gotoAndPlay(1);
_root.map.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "player" in Frame 47
on (press) {
_root.mission = 30;
_root.sample.gotoAndPlay(1);
_root.map.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "honors" in Frame 47
on (press) {
_root.mission = 30;
_root.sample.gotoAndPlay(1);
_root.map.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "earnings" in Frame 47
on (press) {
_root.mission = 30;
_root.sample.gotoAndPlay(1);
_root.map.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "losses" in Frame 47
on (press) {
_root.mission = 30;
_root.sample.gotoAndPlay(1);
_root.map.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "created" in Frame 47
on (press) {
_root.mission = 30;
_root.sample.gotoAndPlay(1);
_root.map.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "captures" in Frame 47
on (press) {
_root.mission = 30;
_root.sample.gotoAndPlay(1);
_root.map.gotoAndPlay(1);
}
Instance of Symbol 324 MovieClip "mainmenu" in Frame 47
on (press) {
_root.gotoAndPlay("menu");
}
Frame 48
function buildCanvas() {
var _local2;
var _local3 = 0;
var _local4 = 0;
_local2 = 0;
while (_local2 < 280) {
_root.attachMovie("tile_holder", "t" + _local2, _local2);
_root["t" + _local2]._x = _local3;
_root["t" + _local2]._y = int(_local4);
_local3 = _local3 + 30;
if (_local3 >= 600) {
_local3 = 0;
_local4 = int(_local4 + 30);
}
_local2++;
}
}
function dump() {
var _local2;
_root.map99 = new Array();
string = "";
_local2 = 0;
while (_local2 < 280) {
_root.map99.push(_root["t" + _local2].me);
string = (string + _root["t" + _local2].me) + ", ";
_local2++;
}
_root.attachMovie("int_dump", "int_dump", 3750);
_root.int_dump.dump.text = string;
}
function placeTiles() {
var _local2;
var _local3;
var _local4;
var _local5;
_local4 = 430;
_local3 = 20;
_local2 = 0;
while (_local2 <= 100) {
_local5 = _local2.toString();
_root.attachMovie(_local5, "p" + _local2, 500 + _local2);
if (_root["p" + _local2] != undefined) {
_root["p" + _local2]._height = 10;
_root["p" + _local2]._width = 10;
_root["p" + _local2]._x = _local3;
_root["p" + _local2]._y = _local4;
_local3 = _local3 + 10;
}
if (_local3 > 600) {
_local3 = 0;
_local4 = _local4 + 10;
}
_local2++;
}
}
function ClearEditor() {
var _local2;
_local2 = 0;
while (_local2 < 280) {
_root["t" + _local2].removeMovieClip();
_root["p" + _local2].removeMovieClip();
_local2++;
}
}
buildCanvas();
placeTiles();
stop();
stopAllSounds();
var day = 1;
var lock = false;
_root.multiplayer = false;
stop();
Instance of Symbol 324 MovieClip "mainmenu" in Frame 48
on (press) {
_root.ClearEditor();
_root.gotoAndPlay("menu");
}
Frame 53
function joinRoom() {
var _local1 = new Object();
_local1.roomName = "Lobby";
_local1.zone = "Chat Area";
es.createRoom(_local1);
}
_root.multiplayer = true;
var es = ElectroServer.getInstance();
es.roomJoined = function (Results, myRoom) {
if (Results.success) {
msg.text = "Room Joined";
} else {
msg.text = Results.error;
}
};
es.loggedIn = function (success, error) {
if (success) {
joinRoom();
} else {
msg.text = error;
}
};
es.onConnection = function (success, error) {
if (success) {
msg.text = "Connected!";
} else {
msg.text = error;
}
};
es.setIP("127.0.0.1");
es.setPort(9875);
msg.text = "Connecting...";
es.connect();
stop();
Frame 54
_root.credits = 50;
stopAllSounds();
_root.bgm = new Sound();
_root.bgm.attachSound("racingbgm");
_root.bgm.setVolume(_root.music_vol);
_root.bgm.start(0, 999);
stop();
Frame 56
stop();
stopAllSounds();
_root.bgm = new Sound();
_root.bgm.attachSound("petbgm");
_root.bgm.setVolume(_root.music_vol);
_root.bgm.start(0, 999);
stop();
Frame 58
stopAllSounds();
_root.bgm = new Sound();
_root.bgm.attachSound("whack");
_root.bgm.setVolume(_root.music_vol);
_root.bgm.start(0, 999);
stop();
Symbol 3 MovieClip [fx_contrail_up] Frame 90
this.removeMovieClip();
Symbol 6 MovieClip [24] Frame 1
#initclip 1
Object.registerClass("24", Terrain);
#endinitclip
Symbol 17 MovieClip Frame 1
stop();
Symbol 17 MovieClip Frame 210
stop();
Symbol 1482 MovieClip [__Packages.Terrain] Frame 0
class Terrain extends MovieClip
{
var _name, byFoot, byWheel, byAir, bySea;
function Terrain () {
super();
}
function onPress() {
_root.intelUnit.Deselect();
_root.selectedUnit.Deselect();
_root.selectedTerrain = _name;
if (_root.lock == false) {
_root.selectedUnit.Deselect();
if ((factory == true) && (city_owner == 0)) {
_root.selectedBuild = this;
_root.attachMovie("int_factory", "int_factory", 3400, {_x:50, _y:50});
}
if ((airport == true) && (city_owner == 0)) {
_root.selectedBuild = this;
_root.attachMovie("int_airport", "int_factory", 3400, {_x:50, _y:50});
}
if ((seaport == true) && (city_owner == 0)) {
_root.selectedBuild = this;
_root.attachMovie("int_seaport", "int_factory", 3400, {_x:50, _y:50});
}
}
}
function Passable(unit) {
switch (unit.unitType) {
case "foot" :
if (byFoot == true) {
return(true);
}
return(false);
case "wheel" :
if (byWheel == true) {
return(true);
}
return(false);
case "track" :
if (byWheel == true) {
return(true);
}
return(false);
case "air" :
if (byAir == true) {
return(true);
}
return(false);
case "sea" :
if (bySea == true) {
return(true);
}
return(false);
}
}
var movementCost = 2;
var city = false;
var hq = false;
var factory = false;
var airport = false;
var seaport = false;
var derrick = false;
var city_owner = 2;
var city_hp = 200;
var priority = 1;
var owned = false;
var playerOn = false;
var built = false;
}
Symbol 1483 MovieClip [__Packages.Unit] Frame 0
class Unit extends MovieClip
{
var unit_mc, move_snd, attack_snd, attack_fx, move_fx, canAttackAir, canAttackGround, holdsInfantry, holdsVehicle, tile, _alpha, destination, waypoint_x, waypoint_y, _x, _y, gotoAndPlay, acost, bcost, ccost, dcost, attachMovie, inside, removeMovieClip;
function Unit (passed_mc) {
super();
unit_mc = passed_mc;
move_snd = new Sound(this);
attack_snd = new Sound(this);
switch (unitType) {
case "foot" :
move_snd.attachSound("infantry_move");
attack_snd.attachSound("scout_attack");
attack_fx = "fx_shot_mgun";
move_fx = "fx_footprints";
switch (unitClass) {
case "infantry" :
ap = 45;
infantry_ap = 55;
dp = 8;
los = 2;
moves_total = 4;
moves_left = 4;
canAttackAir = false;
canAttackGround = true;
cost = 1000;
break;
case "rocket infantry" :
attack_snd.attachSound("tank_attack");
attack_fx = "fx_shot_cannon";
ap = 85;
infantry_ap = 64;
air_ap = 35;
dp = 9;
los = 2;
moves_total = 4;
moves_left = 4;
canAttackAir = true;
canAttackGround = true;
cost = 3000;
}
break;
case "wheel" :
move_snd.attachSound("scout_move");
attack_snd.attachSound("scout_attack");
attack_fx = "fx_shot_mgun";
move_fx = "fx_tracks";
ap = 30;
infantry_ap = 40;
dp = 13;
los = 4;
moves_total = 6;
moves_left = 6;
canAttackAir = false;
canAttackGround = true;
cost = 3000;
switch (unitClass) {
case "truck" :
canAttack = false;
ap = 0;
los = 2;
moves_total = 3;
moves_left = 3;
break;
case "albatross" :
move_fx = "fx_contrail";
move_snd.attachSound("bomber_move");
canAttack = false;
ap = 0;
dp = 18;
los = 0;
moves_left = 2;
moves_total = 2;
}
break;
case "track" :
move_snd.attachSound("tank_move");
attack_snd.attachSound("tank_attack");
attack_fx = "fx_shot_cannon";
move_fx = "fx_tracks";
canAttackAir = false;
canAttackGround = true;
switch (unitClass) {
case "aa" :
attack_snd.attachSound("fighter_attack");
ap = 13;
infantry_ap = 118;
air_ap = 115;
dp = 15;
los = 2;
moves_left = 4;
moves_total = 4;
ammo = 25;
max_ammo = 25;
max_range = "aa";
canRetaliate = true;
canAttackAir = true;
canAttackGround = true;
cost = 4000;
break;
case "artillery" :
attack_snd.attachSound("art_attack");
ap = 115;
infantry_ap = 80;
dp = 20;
los = 2;
moves_left = 4;
moves_total = 4;
ammo = 15;
max_ammo = 15;
max_range = "artillery";
fullturn = true;
canRetaliate = false;
canAttackAir = false;
canAttackGround = true;
cost = 5000;
ranged = true;
break;
case "apc" :
attack_snd.attachSound("scout_attack");
attack_fx = "fx_shot_mgun";
infantry_ap = 38;
ap = 30;
dp = 23;
los = 2;
moves_total = 6;
holdsInfantry = true;
moves_left = 6;
canAttackAir = false;
canAttackGround = true;
cost = 4000;
break;
case "rocket" :
attack_snd.attachSound("rocket");
ap = 140;
infantry_ap = 120;
dp = 18;
los = 1;
ammo = 8;
max_ammo = 8;
moves_total = 4;
max_range = "rocket";
moves_left = 4;
fullturn = true;
canRetaliate = false;
canAttackAir = false;
canAttackGround = true;
cost = 8000;
ranged = true;
break;
case "tank" :
ap = 70;
infantry_ap = 70;
dp = 28;
los = 3;
ammo = 25;
max_ammo = 25;
moves_total = 5;
max_range = "standard";
moves_left = 5;
canAttackAir = false;
canAttackGround = true;
cost = 5000;
}
break;
case "air" :
move_snd.attachSound("fighter_move");
move_fx = "fx_contrail";
switch (unitClass) {
case "fighter" :
attack_snd.attachSound("fighter_attack");
attack_fx = "fx_shot_mgun";
ap = 50;
air_ap = 85;
dp = 25;
los = 5;
moves_total = 5;
moves_left = 5;
canAttackAir = true;
canAttackGround = false;
cost = 8000;
break;
case "bomber" :
move_snd.attachSound("bomber_move");
attack_snd.attachSound("bomber_attack");
attack_fx = "fx_shot_cannon";
ap = 150;
infantry_ap = 110;
dp = 24;
los = 1;
moves_total = 4;
moves_left = 4;
max_fuel = 12;
fuel = 12;
max_ammo = 4;
ammo = 4;
canAttackAir = false;
canAttackGround = true;
canRetaliate = false;
cost = 10000;
break;
case "transport" :
move_fx = null;
move_snd.attachSound("transport_move");
ap = 0;
dp = 20;
los = 3;
moves_total = 4;
moves_left = 4;
holdsInfantry = true;
canAttack = false;
cost = 5000;
break;
case "helicopter" :
move_fx = null;
move_snd.attachSound("transport_move");
ap = 70;
infantry_ap = 62;
air_ap = 30;
dp = 20;
los = 3;
moves_total = 4;
moves_left = 4;
canAttackAir = true;
canAttackGround = true;
cost = 6000;
}
break;
case "sea" :
switch (unitClass) {
case "lander" :
attack_snd.attachSound("tank_attack");
attack_fx = "fx_shot_cannon";
move_fx = "fx_ripple";
move_snd.attachSound("lander");
ap = 0;
infantry_ap = 0;
air_ap = 0;
dp = 20;
los = 2;
moves_total = 2;
moves_left = 2;
canAttackAir = false;
canAttackGround = false;
cost = 6000;
holdsInfantry = true;
holdsVehicle = true;
canRetaliate = false;
break;
case "submarine" :
attack_snd.attachSound("tank_attack");
attack_fx = "fx_shot_cannon";
move_fx = "fx_ripple";
move_snd.attachSound("sub");
ap = 90;
infantry_ap = 0;
air_ap = 0;
dp = 30;
los = 2;
moves_total = 4;
moves_left = 4;
canAttackAir = false;
canAttackGround = true;
cost = 10000;
holdsInfantry = false;
holdsVehicle = false;
canRetaliate = false;
break;
case "destroyer" :
attack_snd.attachSound("tank_attack");
attack_fx = "fx_shot_cannon";
move_fx = "fx_ripple";
move_snd.attachSound("ship");
ap = 60;
infantry_ap = 0;
air_ap = 40;
dp = 25;
los = 3;
moves_total = 6;
moves_left = 6;
canAttackAir = true;
canAttackGround = true;
cost = 8000;
holdsInfantry = false;
holdsVehicle = false;
break;
case "carrier" :
move_fx = "fx_ripple";
move_snd.attachSound("ship");
ap = 40;
infantry_ap = 0;
air_ap = 45;
dp = 30;
los = 5;
moves_total = 4;
moves_left = 4;
canAttackAir = true;
canAttackGround = true;
cost = 13000;
holdsInfantry = false;
holdsVehicle = false;
canRetaliate = false;
}
}
FindTile();
}
function ClearMovement() {
var _local3;
_local3 = 1500;
while (_local3 <= 1780) {
_root["m" + _local3].removeMovieClip();
_local3++;
}
x = 0;
while (x <= 100) {
_root["a" + x].removeMovieClip();
x++;
}
_local3 = 0;
while (_local3 <= 280) {
_root["t" + _local3].owned = false;
_local3++;
}
x = 1500;
_root.k = 0;
}
function FindMovement() {
AttachAdjacent(tile);
}
function AttachAdjacent(myTile, parent) {
AttachMovement(myTile - 1, parent);
AttachMovement(myTile + 1, parent);
AttachMovement(myTile + 20, parent);
AttachMovement(myTile - 20, parent);
}
function AttachMovement(myTile, parent) {
var _local5 = 100;
if (team != 0) {
_local5 = 0;
}
if (_root["t" + myTile].owned == false) {
x++;
_root["t" + myTile].owned = true;
_root["t" + myTile].owner = x;
if (_alpha >= 70) {
_root.attachMovie("m", "m" + x, x);
} else {
_root.attachMovie("m2", "m" + x, x);
}
_root["m" + x]._x = _root["t" + myTile]._x;
_root["m" + x]._y = _root["t" + myTile]._y;
_root["m" + x]._alpha = _local5;
_root["m" + x].parent = int(parent);
_root["m" + x].tile = myTile;
_root["m" + x].myOwner = this;
_root["m" + x].Check();
if (_root["m" + x] != undefined) {
if (int(_root["m" + x].routeCost) < int(moves_left)) {
AttachAdjacent(myTile, x);
}
}
} else {
var _local4 = 0;
if ((unitType == "air") && (_alpha > 0)) {
_local4 = int(_root["m" + parent].routeCost) + 1;
} else {
_local4 = int(_root["m" + parent].routeCost) + int(_root["t" + myTile].movementCost);
}
if (_local4 < int(_root["m" + int(_root["t" + myTile].owner)].routeCost)) {
_root["m" + int(_root["t" + myTile].owner)].removeMovieClip();
x++;
_root["t" + myTile].owned = true;
_root["t" + myTile].owner = x;
_root.attachMovie("m", "m" + x, x);
_root["m" + x]._x = _root["t" + myTile]._x;
_root["m" + x]._y = _root["t" + myTile]._y;
_root["m" + x]._alpha = _local5;
_root["m" + x].parent = int(parent);
_root["m" + x].Check();
if (_root["m" + x] != undefined) {
if (int(_root["m" + x].routeCost) < int(moves_left)) {
AttachAdjacent(myTile, x);
}
}
}
}
}
function Move(to) {
var _local4;
if (_root.lock == false) {
destination = to;
move_snd.setVolume(_root.sfx_vol);
move_snd.start(0, 20);
_root.lock = true;
waypoint_x = route_x.pop();
waypoint_y = route_y.pop();
}
}
function MoveAnim() {
move_snd.setVolume(_root.sfx_vol);
var _local6 = 0;
var _local3 = 2;
if (_root.fastmove == true) {
_local3 = 30;
}
if (destination != null) {
if (_x > waypoint_x) {
if ((_x % 30) == 0) {
_root.attachMovie(move_fx, "track" + random(1000), random(50) + 2100, {_x:_x, _y:_y, _alpha:_alpha});
}
_x = _x - _local3;
gotoAndPlay("right");
} else if (_x < waypoint_x) {
if ((_x % 30) == 0) {
_root.attachMovie(move_fx, "track" + random(1000), random(50) + 2100, {_x:_x, _y:_y, _alpha:_alpha});
}
_x = _x + _local3;
gotoAndPlay("left");
} else if (_x == waypoint_x) {
if (_y > waypoint_y) {
if ((_y % 30) == 0) {
_root.attachMovie(move_fx + "_up", "track" + random(1000), random(50) + 2100, {_x:_x, _y:_y, _alpha:_alpha});
}
_y = _y - _local3;
gotoAndPlay("up");
} else {
if ((_y % 30) == 0) {
_root.attachMovie(move_fx + "_up", "track" + random(1000), random(50) + 2100, {_x:_x, _y:_y, _alpha:_alpha});
}
_y = _y + _local3;
gotoAndPlay("down");
}
}
if ((_x == waypoint_x) && (_y == waypoint_y)) {
waypoint_x = route_x.pop();
waypoint_y = route_y.pop();
}
}
if (_x == destination._x) {
if (_y == destination._y) {
_root.VisableArea();
_root.m2099.removeMovieClip();
move_snd.stop();
_root.lock = false;
destination = null;
FindTile();
if ((_root["t" + tile].myName == "forest") & (team == 0)) {
_alpha = 80;
} else {
_alpha = 100;
}
if (team != 0) {
if (this == _root.selectedUnit) {
_root.myEnemy.AssessAttack(this);
_root.myEnemy.RunBuild();
}
}
if ((((unitType == "foot") && (team == 1)) && (_root["t" + int(tile)].city == true)) && (_root["t" + int(tile)].city_owner != 1)) {
goCapture();
} else {
moved = true;
Deselect();
}
}
}
}
function Deselect() {
if (team != 0) {
moved = true;
}
var _local3;
_local3 = 1500;
while (_local3 <= 1780) {
_root["m" + _local3].removeMovieClip();
_local3++;
}
_root.a0.removeMovieClip();
x = -1;
while (x <= 100) {
_root["a" + x].removeMovieClip();
x++;
}
_local3 = 0;
while (_local3 <= 280) {
_root["t" + _local3].owned = false;
_local3++;
}
x = 1500;
_root.k = 0;
_root.selectedUnit = null;
_root.int_selected.removeMovieClip();
_local3 = 0;
while (_local3 <= 15) {
_root["int_getIn" + _local3].removeMovieClip();
_local3++;
}
_root.getInDisplayed = 0;
_root.int_capture.removeMovieClip();
_root.int_getOut.removeMovieClip();
_root.int_dig.removeMovieClip();
_root.int_unDig.removeMovieClip();
acost = (bcost = (ccost = (dcost = 0)));
}
function FindTile() {
var _local3;
var _local4;
if (int(_x % 30) != 0) {
}
if (int(_y % 30) != 0) {
}
_local3 = int(_y / 30);
_local4 = int(_x / 30);
tile = int(_local3 * 20) + int(_local4);
if (team == 0) {
_root["t" + tile].playerOn = true;
}
}
function resupply() {
attachMovie("int_reload", "int_reload", 2950);
ammo = max_ammo;
}
function repair() {
attachMovie("int_repair", "int_repair", 2951);
if (hp <= 80) {
hp = int(hp) + 20;
} else {
hp = 100;
}
}
function refuel() {
attachMovie("int_refuel", "int_refuel", 2952);
fuel = max_fuel;
}
function FindAttack(safety) {
var _local4;
if (canAttack == true) {
_local4 = 0;
while (_local4 < 100) {
_root["a" + _local4].removeMovieClip();
_local4++;
}
_root.k = 0;
_local4 = 0;
switch (max_range) {
case "standard" :
AttachAttack(tile - 1, safety);
AttachAttack(tile + 1, safety);
AttachAttack(tile - 20, safety);
AttachAttack(tile + 20, safety);
break;
case "artillery" :
AttachAttack(tile - 2, safety);
AttachAttack(tile + 2, safety);
AttachAttack(tile - 3, safety);
AttachAttack(tile + 3, safety);
AttachAttack(tile - 40, safety);
AttachAttack(tile + 40, safety);
AttachAttack(tile - 60, safety);
AttachAttack(tile + 60, safety);
AttachAttack(tile - 39, safety);
AttachAttack(tile + 39, safety);
AttachAttack(tile - 41, safety);
AttachAttack(tile + 41, safety);
AttachAttack(tile - 18, safety);
AttachAttack(tile + 18, safety);
AttachAttack(tile - 22, safety);
AttachAttack(tile + 22, safety);
break;
case "rocket" :
AttachAttack(tile - 3, safety);
AttachAttack(tile + 3, safety);
AttachAttack(tile - 4, safety);
AttachAttack(tile + 4, safety);
AttachAttack(tile - 5, safety);
AttachAttack(tile + 5, safety);
AttachAttack(tile - 60, safety);
AttachAttack(tile + 60, safety);
AttachAttack(tile - 80, safety);
AttachAttack(tile + 80, safety);
AttachAttack(tile - 100, safety);
AttachAttack(tile + 100, safety);
AttachAttack(tile - 16, safety);
AttachAttack(tile - 17, safety);
AttachAttack(tile - 18, safety);
AttachAttack(tile - 39, safety);
AttachAttack(tile - 38, safety);
AttachAttack(tile - 37, safety);
AttachAttack(tile - 59, safety);
AttachAttack(tile - 58, safety);
AttachAttack(tile - 79, safety);
AttachAttack(tile - 24, safety);
AttachAttack(tile - 23, safety);
AttachAttack(tile - 22, safety);
AttachAttack(tile - 41, safety);
AttachAttack(tile - 42, safety);
AttachAttack(tile - 43, safety);
AttachAttack(tile - 61, safety);
AttachAttack(tile - 62, safety);
AttachAttack(tile - 81, safety);
AttachAttack(tile + 16, safety);
AttachAttack(tile + 17, safety);
AttachAttack(tile + 18, safety);
AttachAttack(tile + 39, safety);
AttachAttack(tile + 38, safety);
AttachAttack(tile + 37, safety);
AttachAttack(tile + 59, safety);
AttachAttack(tile + 58, safety);
AttachAttack(tile + 79, safety);
AttachAttack(tile + 24, safety);
AttachAttack(tile + 23, safety);
AttachAttack(tile + 22, safety);
AttachAttack(tile + 41, safety);
AttachAttack(tile + 42, safety);
AttachAttack(tile + 43, safety);
AttachAttack(tile + 61, safety);
AttachAttack(tile + 62, safety);
AttachAttack(tile + 81, safety);
break;
case "aa" :
AttachAttack(tile - 1, safety);
AttachAttack(tile + 1, safety);
AttachAttack(tile - 20, safety);
AttachAttack(tile + 20, safety);
AttachAttack(tile - 2, safety, true);
AttachAttack(tile + 2, safety, true);
AttachAttack(tile - 40, safety, true);
AttachAttack(tile + 40, safety, true);
AttachAttack(tile - 21, safety, true);
AttachAttack(tile + 19, safety, true);
AttachAttack(tile - 19, safety, true);
AttachAttack(tile + 21, safety, true);
}
}
}
function AttachAttack(i, safety, onlyAir) {
var _local3;
var _local5;
if (safety == true) {
_local5 = "attack_safe";
if (_root.getDistance(this, _root["t" + i]) < 300) {
_root.attachMovie(_local5, "a" + _root.k, int(2501 + _root.k), {_x:_root["t" + i]._x, _y:_root["t" + i]._y, owner:_root["unit" + _local3], by:_root.selectedUnit, safety:true});
}
_root.k++;
} else {
_local5 = "attack";
_local3 = 0;
while (_local3 <= 100) {
if ((((_root["unit" + _local3].tile == i) && (_root["unit" + _local3].team != team)) && (AttackValidate(_root["unit" + _local3]) == true)) && (_root.getDistance(_root["unit" + _local3], this) < 300)) {
if (fullturn == true) {
if ((moves_left == moves_total) && (attacked == false)) {
_root.attachMovie(_local5, "a" + _root.k, int(2501 + _root.k), {_x:_root["t" + i]._x, _y:_root["t" + i]._y, owner:_root["unit" + _local3], by:_root.selectedUnit});
_root.k++;
}
} else if (attacked == false) {
if (onlyAir != true) {
_root.attachMovie(_local5, "a" + _root.k, int(2501 + _root.k), {_x:_root["t" + i]._x, _y:_root["t" + i]._y, owner:_root["unit" + _local3], by:_root.selectedUnit});
_root.k++;
} else if (_root["unit" + _local3].unitType == "air") {
_root.attachMovie(_local5, "a" + _root.k, int(2501 + _root.k), {_x:_root["t" + i]._x, _y:_root["t" + i]._y, owner:_root["unit" + _local3], by:_root.selectedUnit});
_root.k++;
}
}
}
_local3++;
}
}
}
function AttackValidate(target) {
if (target.unitType == "air") {
if (canAttackAir == true) {
return(true);
}
return(false);
}
if (canAttackGround == true) {
return(true);
}
return(false);
}
function Attack(enemy) {
var _local4 = 0;
if (attacked == false) {
var _local5 = false;
attack_snd.setVolume(_root.sfx_vol);
attack_snd.start(0, 1);
enemy.attachMovie(attack_fx, "cannon", 4000);
_local4 = int(DamageCalc(enemy, true));
enemy.hp = int(enemy.hp) + int(_local4);
ammo = int(ammo) - 1;
moves_left = 0;
attacked = true;
moved = true;
if (enemy.hp <= 0) {
_root.Enemy.Assess();
_root.attachMovie("fx_blowup", "fx_blowup", 2980, {_x:enemy._x, _y:enemy._y});
if (enemy.team == 0) {
_root.tstat_player_lost = int(_root.tstat_player_lost) + 1;
} else {
_root.tstat_com_lost = int(_root.tstat_com_lost) + 1;
}
enemy.removeMovieClip();
_local5 = true;
_root.killedEnemies = int(_root.killedEnemies + 1);
_root.cursor.gotoAndPlay("normal");
}
if (((((_local5 == false) && (enemy.ammo > 0)) && (enemy.canRetaliate == true)) && (ranged == false)) && (enemy.canAttack == true)) {
attachMovie(enemy.attack_fx, "cannon", 4001);
_local4 = DamageCalc(this, false);
hp = int(hp) + int(_local4);
enemy.ammo = int(enemy.ammo) - 1;
if (hp <= 0) {
if (team == 0) {
_root.tstat_player_lost = int(_root.tstat_player_lost) + 1;
} else {
_root.tstat_com_lost = int(_root.tstat_com_lost) + 1;
}
_root.attachMovie("fx_blowup", "fx_blowup", 2981, {_x:_x, _y:_y});
Deselect();
inside.removeMovieClip();
removeMovieClip();
}
}
Deselect();
}
}
function DamageCalc(enemy, attacker) {
var _local3 = 0;
var _local5;
var _local6 = int(_root["t" + enemy.tile].defenceBonus * 0.66);
if (attacker == true) {
if (enemy.unitType == "air") {
_local5 = air_ap;
} else if (enemy.unitType == "foot") {
_local5 = infantry_ap;
} else {
_local5 = ap;
}
_local3 = int(enemy.dp - (_local5 * Math.ceil(hp / 100)));
_local3 = int(_local3 * ((90 + random(10)) / 100));
} else {
if (enemy.unitType == "air") {
_local5 = enemy.air_ap * 0.69;
} else if (enemy.unitType == "foot") {
_local5 = enemy.infantry_ap * 0.69;
} else {
_local5 = enemy.ap * 0.69;
}
_local3 = int(dp - (_local5 * Math.ceil(enemy.hp / 100)));
_local3 = int(_local3 * ((50 + random(30)) / 100));
}
if (enemy.unitType != "air") {
_local3 = int(_local3 / int(_local6 + 1));
}
if (_local3 >= 0) {
_local3 = -5;
}
return(_local3);
}
function onPress() {
if (_alpha > 0) {
var _local3 = new Sound();
_local3.attachSound("press");
_local3.setVolume = _root.sfx_vol;
_local3.start(0, 1);
_root.intelUnit = this;
_root.selectedUnit.Deselect();
_root.attachMovie("int_selected", "int_selected", 2199, {_x:_x, _y:_y});
if (_root.intelUnit.team != 0) {
FindAttack(true);
}
if ((_root.lock == false) && (_root.moved == false)) {
if (team == 0) {
x = 1500;
_root.selectedUnit = this;
_root.unitType = unitType;
FindMovement();
if (inside != undefined) {
_root.attachMovie("int_getOut", "int_getOut", 2903, {_x:_x, _y:_y, myType:"exit", myOwner:this});
}
if ((((unitType == "foot") && (attacked == false)) && (_root["t" + tile].city_owner != 0)) && (_root["t" + tile].city == true)) {
_root.attachMovie("int_capture", "int_capture", 2900, {_x:_x, _y:_y, myType:"capture", myOwner:_root["t" + tile]});
}
if (((unitType == "foot") && (moves_left == moves_total)) && (entrenched == false)) {
if ((((_root["t" + tile].city == false) && (_root["t" + tile].myName != "derrick")) && (_root["t" + tile].myName != "road")) && (_root["t" + tile].myName != "mountain")) {
_root.attachMovie("int_dig", "int_dig", 2904, {_x:_x, _y:_y, myType:"dig", myOwner:this});
}
}
FindAttack();
}
}
}
}
function goCapture() {
if ((((_root["t" + tile].city == true) && (attacked == false)) && (unitType == "foot")) && (_root["t" + tile].city_owner != team)) {
_root.lock = true;
if (_y < 200) {
_root.attachMovie("int_capture_china_south", "int_capture_china", 2900, {_x:_x, _y:_y, myType:"capture", myOwner:_root["t" + int(tile)]});
} else {
_root.attachMovie("int_capture_china", "int_capture_china", 2900, {_x:_x, _y:_y, myType:"capture", myOwner:_root["t" + int(tile)]});
}
attacked = true;
moves_left = 0;
}
}
var hp = 100;
var unitType = "foot";
var unitClass = "infantry";
var ap = 70;
var air_ap = 40;
var infantry_ap = 80;
var dp = 28;
var team = 0;
var moves_left = 4;
var moves_total = 4;
var attacked = false;
var cost = 1000;
var max_range = "standard";
var ranged = false;
var canAttack = true;
var los = 3;
var route_x = Array(6);
var route_y = Array(6);
var moved = false;
var ammo = 99;
var max_ammo = 99;
var fuel = 60;
var max_fuel = 60;
var x = 1500;
var entrenched = false;
var frozen = false;
var fullturn = false;
var canRetaliate = true;
}
Symbol 1484 MovieClip [__Packages.Movement] Frame 0
class Movement extends MovieClip
{
var myOwner, parent, _x, _y, hitTest, removeMovieClip, _alpha;
function Movement () {
super();
}
function onRelease() {
if (_root.lock == false) {
if (allowed == true) {
if (myOwner.entrenched == true) {
myOwner.dp = int(myOwner.dp) - 20;
myOwner.entrenched = false;
myOwner.int_trench.removeMovieClip();
}
move();
}
}
}
function move() {
var _local3 = parent;
_root.int_capture.removeMovieClip();
_root.attachMovie("mtarget", "m2099", 2099);
_root.m2099._x = _x;
_root.m2099._y = _y;
if (myOwner._alpha == 0) {
_root.selectedUnit = myOwner;
myOwner._alpha = 100;
_root.owner.inside = undefined;
_root.selectedUnit._x = _root.owner._x;
_root.selectedUnit._y = _root.owner._y;
_root.owner = null;
}
_root.selectedUnit.route_x.push(_x);
_root.selectedUnit.route_y.push(_y);
_local3 = int(parent);
while (_root["m" + _local3] != undefined) {
_root.selectedUnit.route_x.push(_root["m" + _local3]._x);
_root.selectedUnit.route_y.push(_root["m" + _local3]._y);
_local3 = int(_root["m" + _local3].parent);
}
_root.selectedUnit.Move(_root.m2099);
_root.selectedUnit.moves_left = int(_root.selectedUnit.moves_left) - int(routeCost);
_root.selectedUnit.fuel = int(_root.selectedUnit.fuel) - int(routeCost);
_root.selectedUnit.Deselect();
}
function Check() {
var _local3;
var _local8;
_local3 = 0;
while (_local3 <= 100) {
if (hitTest(_root["unit" + _local3]) && (_root["unit" + _local3].team != _root.selectedUnit.team)) {
removeMovieClip();
}
if ((_root["unit" + _local3].team == _root.selectedUnit.team) && (hitTest(_root["unit" + _local3]))) {
allowed = false;
_alpha = 0;
if (((_root["unit" + _local3].holdsInfantry == true) && (_root["unit" + _local3].inside == undefined)) && (_root.selectedUnit.unitType == "foot")) {
_root.attachMovie("int_getIn", "int_getIn" + _root.getInDisplayed, 2902 + _root.getInDisplayed, {_x:_root["unit" + _local3]._x, _y:_root["unit" + _local3]._y, myType:"enter", myOwner:_root["unit" + _local3]});
_root.getInDisplayed = _root.getInDisplayed + 1;
}
if ((((_root["unit" + _local3].holdsVehicle == true) && (_root["unit" + _local3].inside == undefined)) && (_root.selectedUnit.unitType != "air")) && (_root.selectedUnit.unitType != "sea")) {
_root.attachMovie("int_getIn", "int_getIn" + _root.getInDisplayed, 2902 + _root.getInDisplayed, {_x:_root["unit" + _local3]._x, _y:_root["unit" + _local3]._y, myType:"enter", myOwner:_root["unit" + _local3]});
_root.getInDisplayed = _root.getInDisplayed + 1;
}
}
_local3++;
}
_local3 = 0;
while (_local3 < 280) {
if (hitTest(_root["t" + _local3])) {
if (_root.selectedUnit.unitType == "air") {
cost = 1;
} else {
cost = int(_root["t" + _local3].movementCost);
}
routeCost = int(cost) + int(_root["m" + parent].routeCost);
if (myOwner.moves_left < routeCost) {
_root["t" + _local3].owned = false;
removeMovieClip();
}
if (_root["t" + _local3].Passable(myOwner) == false) {
_root["t" + _local3].owned = false;
removeMovieClip();
}
if (int(_root.getDistanceX(this, _root.selectedUnit)) > 390) {
_root["t" + _local3].owned = false;
removeMovieClip();
}
closeness = int(_root.getDistance(this, _root.selectedUnit.my_target));
}
_local3++;
}
}
var cost = 0;
var routeCost = 0;
var closeness = 100000;
var allowed = true;
}
Symbol 1485 MovieClip [__Packages.Interface] Frame 0
class Interface extends MovieClip
{
var myType, _y, myOwner, removeMovieClip;
function Interface () {
super();
}
function onPress() {
var _local3 = new Sound();
_local3.attachSound("hit");
_local3.setVolume = _root.sfx_vol;
_local3.start(0, 1);
switch (myType) {
case "capture" :
goCapture();
break;
case "enter" :
goEnter();
break;
case "exit" :
goExit();
break;
case "dig" :
goDig();
break;
case "undig" :
unDig();
}
}
function goCapture() {
_root.selectedUnit.attacked = true;
_root.selectedUnit.moves_left = 0;
if (_y < 90) {
_root.attachMovie("int_capturing_south", "int_capturing", 2901, {_x:_root.int_capture._x, _y:_root.int_capture._y, myOwner:myOwner});
} else {
_root.attachMovie("int_capturing", "int_capturing", 2901, {_x:_root.int_capture._x, _y:_root.int_capture._y, myOwner:myOwner});
}
}
function goEnter() {
_root.selectedUnit._alpha = 0;
_root.selectedUnit.moves_left = 0;
_root.selectedUnit.fired = true;
_root.selectedUnit._x = -30;
myOwner.inside = _root.selectedUnit;
_root.selectedUnit.Deselect();
}
function goExit() {
myOwner.ClearMovement();
_root.owner = myOwner;
myOwner.inside.tile = myOwner.tile;
myOwner.inside.FindMovement();
_root.int_getOut.removeMovieClip();
}
function goDig() {
myOwner.dp = int(myOwner.dp) + 20;
myOwner.moves_left = 0;
myOwner.attacked = true;
myOwner.entrenched = true;
myOwner.attachMovie("int_trench", "int_trench", 200);
myOwner.Deselect();
removeMovieClip();
}
function unDig() {
myOwner.dp = int(myOwner.dp) - 20;
myOwner.moves_left = 0;
myOwner.attacked = true;
myOwner.entrenched = false;
myOwner.int_trench.removeMovieClip();
myOwner.Deselect();
removeMovieClip();
}
}
Symbol 1486 MovieClip [__Packages.Attack] Frame 0
class Attack extends MovieClip
{
var owner, removeMovieClip, by, _y, _x;
function Attack () {
super();
if (owner._alpha <= 10) {
removeMovieClip();
}
if ((by.ranged == true) && (by.moves_left < by.moves_total)) {
removeMovieClip();
}
if (int(_root.getDistanceX(by, this) + int(_root.getDistanceY(by, this))) > 300) {
removeMovieClip();
}
if (owner.ammo <= 0) {
removeMovieClip();
}
}
function onPress() {
if (safety == false) {
_root.selectedUnit.moves_left = 0;
_root.selectedUnit.Attack(owner);
}
}
function onRollOver() {
if (safety == false) {
_root.attackScore = _root.selectedUnit.DamageCalc(owner, true) + "%";
_root.attachMovie("int_attackinfo", "int_attackinfo", 2940, {_x:_x, _y:_y});
}
}
function onRollOut() {
if (safety == false) {
_root.int_attackinfo.gotoAndPlay(11);
}
}
function onUnload() {
_root.int_attackinfo.gotoAndPlay(11);
}
var safety = false;
}
Symbol 1487 MovieClip [__Packages.MapEdit] Frame 0
class MapEdit extends MovieClip
{
var me, attachMovie;
function MapEdit () {
super();
}
function onPress() {
me = _root.selectedTerrain.slice(1);
attachMovie(me.toString(), "current", 2);
}
}
Symbol 1488 MovieClip [__Packages.Advisor] Frame 0
class Advisor extends MovieClip
{
var removeMovieClip;
function Advisor () {
super();
speech = this[(("d_map" + int(_root.mission + 1)) + "_") + seq];
_root.myAdvisor.char.gotoAndStop(this[(("f_map" + int(_root.mission + 1)) + "_") + seq]);
if (_root.myGameData.data.gameComplete == true) {
_root.myAdvisor.char.gotoAndStop("naked");
}
if (speech == undefined) {
speech = "I don't have any extra information on this mission. It's all down to you! Good Luck!";
}
if (this[(("d_map" + int(_root.mission + 1)) + "_") + int(seq + 1)] == undefined) {
_root.myAdvisor.myAdvance._alpha = 0;
}
}
function onPress() {
if (seq != "e") {
seq = seq + 1;
if (this[(("d_map" + int(_root.mission + 1)) + "_") + seq] != undefined) {
speech = this[(("d_map" + int(_root.mission + 1)) + "_") + seq];
_root.myAdvisor.char.gotoAndStop(this[(("f_map" + int(_root.mission + 1)) + "_") + seq]);
if (_root.myGameData.data.gameComplete == true) {
_root.myAdvisor.char.gotoAndStop("naked");
}
if (this[(("d_map" + int(_root.mission + 1)) + "_") + int(seq + 1)] == undefined) {
_root.myAdvisor.myAdvance._alpha = 0;
}
} else {
removeMovieClip();
}
} else {
removeMovieClip();
}
}
var d_map1_1 = "Greetings, Commander. I'm Lieutenant Maya. I'm here to give you the situation report.";
var d_map1_2 = "The news is grave, sir. Satellite images detect Chinese forces en-route to our borders.";
var d_map1_3 = "We're putting the entire US Military on Red Alert.";
var d_map1_4 = "Since you're the Commander nearest the invasion point, you're in charge right now.";
var d_map1_5 = "Wait...are you sure you're ready for this? You've only just got out of training...";
var d_map1_6 = "I know you passed out of the academy with flying colours, but I'm going to go over basic procedure";
var d_map1_7 = "We've assigned three Infantry units to your command. They show up as Blue on your tactical display.";
var d_map1_8 = "Everything in Blue is friendly. The Chinese or enemy units always show up as Red.";
var d_map1_9 = "Let's take a look at one of those units. Click on one of them.";
var d_map1_11 = "There. Those blue squares indicate the area a unit can reach, the numbers are the required 'movement points'";
var d_map1_12 = "Different terrains require different movement points. It's harder and slower to traverse mountains and forests";
var d_map1_13 = "Once all your units have moved, you should click END TURN to let the enemy move and refill your movement points";
var d_map1_14 = "Try ordering one of your units onto the road. You may have to click next and end the day to get there";
var d_map1_16 = "Very good. Units move faster on roads, so it's wise to use them if you want to get places quickly.";
var d_map1_17 = "The other available command to infantry is 'Dig In'";
var d_map1_18 = "'Dig In' can be used by clicking on infantry unit who hasn't moved or attacked yet on his turn.";
var d_map1_19 = "Try to 'Dig In' one of your other units, click the unit, then click the Dig indicator";
var d_map1_21 = "Digging In gives your troops better defence against attacking units. It will use up that unit's move.";
var d_map1_22 = "You can't Dig In after your infantry has moved, nor can you move until the turn after your Infantry Dug In.";
var d_map1_23 = "For now, let's just move the infantry across the bridge to meet the enemy.";
var d_map1_25 = "Oh, yes...Cities. Send an Infantry unit onto that square, and Capture the city.";
var d_map1_26 = "To capture just click the blue flag that appears once your unit is on the city";
var d_map1_27 = "For an Infantry with full HP, capturing a property takes two issues of the Capture command";
var d_map1_28 = "Only Infantry and Rocket Infantry units can capture buildings!";
var d_map1_29 = "Oh...Rocket Inf? You don't have any right now. Don't worry about that. I'll explain them when you see them.";
var d_map1_30 = "Capture that city on your next turn. Cities in your control give you money, and refuel, heal and rearm any units inside it.";
var d_map1_32 = "Almost! Try capturing again next turn, I'm sure you'll takeover the city then!";
var d_map1_34 = "Well done! That city has been reclaimed for the United States. Now, send your men over to the area adjacentto the enemy units.";
var d_map1_35 = "They'll move to you too, so no rush. Once we get there it's time for a little payback!";
var d_map1_37 = "You see that red pulse? That is the Attack reticle.";
var d_map1_38 = "Click the attack reticle to attack the unit it's aiming at! Attacking will use all that units remaining turns!";
var d_map1_40 = "Both your troops and the enemy troops took damage. However, because you attacked, you came off best";
var d_map1_41 = "The more stars in the Terrain Info bar, the less damage your unit will take when under fire.";
var d_map1_42 = "Mountains and Cities give the best defence, and Roads the worst. So it's a trade-off between mobility and defence.";
var d_map1_43 = "I believe I've said enough for this mission. Go ahead and destroy the enemy.";
var d_map1_e = "The scouts were destroyed before they could gain any additional reconnaisance. Well done!";
var d_map2_1 = "OK! Get that truck to the runway! Get those VIPs to safety!";
var d_map2_2 = "The enemy has deployed some Anti-Air units, be sure to deal with these before launch!";
var d_map2_3 = "Remember, if the truck or albatross are destroyed it's mission failiure!";
var d_map2_5 = "The VIP's managed to get onboard the Albatross. It's finally airborne, defend it at all costs!";
var d_map2_e = "The VIP's were extracted from the area shaken but unharmed, Great job commander!";
var d_map3_1 = "Sir! It looks like the enemy have primarily deployed armored tanks.";
var d_map3_2 = "We're going to assign you with five rocket infantry squadrons to help you handle this threat";
var d_map3_3 = "I know you haven't handled Rocket infantry before, but they behave just like regular infantry...";
var d_map3_4 = "... except they pack a much larger punch with their rocket launchers!";
var d_map3_5 = "You should have more than enough firepower to deal with the Chinese here, use terrain to your advantage";
var d_map3_6 = "Be very careful with forests, the enemy can hide in them and you wont see them until your adjacent!";
var d_map3_e = "Astounding! You almost single-handedly wiped out the threat to the Southern states!";
var d_map4_1 = "I'm really sorry about you having to handle this mission sir!";
var d_map4_2 = "We've lost radar and satellite coverage to this part of the country, so you're fighting blind";
var d_map4_3 = "Basically, you can't see enemies until they are much nearer your units than usual";
var d_map4_4 = "Considering we're battling artillery, who can fire further than your infantry can see this is a major obstacle";
var d_map4_5 = "To top it all off, our army is massively overstretched, so your team out there isn't as hefty as I'd like";
var d_map4_6 = "Command has every faith that if you take this mission carefully you'll be able to pull it off... Good luck!";
var d_map4_e = "You're quickly becoming the best the US has in this war. Keep it up!";
var d_map5_1 = "They're pushing hard at the Texan border sir, they've even established a base on the outskirts";
var d_map5_2 = "The bad news is we don't have a waiting force ready for you to commands... ";
var d_map5_3 = "...Most of the US army is now heading to Pennsylvania to help defend what could be the turning point for us";
var d_map5_4 = "However, the good news is the area is rich with resources and has a healthy military standing";
var d_map5_5 = "So you should be able to build your own force, you can do this by clicking on the FACTORY at any time";
var d_map5_6 = "To win this mission you just have to capture the Chinese base headquarters";
var d_map5_e = "You secured the Texan border, Congratulations! The President would like a word with you";
var d_map6_1 = "Throughout the war the Chinese haved been striking us and our satellites with an orbital laser cannon";
var d_map6_2 = "This technology has fielded them an incredible advantage from day one, it's time for us to turn the tables";
var d_map6_3 = "We're launching a highly modified stratofigther into orbit from Camp David";
var d_map6_4 = "And you've been picked to ensure it's successful launch!";
var d_map6_5 = "Unfortunatly the nearby oil derricks and factories were abandoned before it was complete";
var d_map6_6 = "We need you to stockpile 75,000 cash to fund the final launch of the stratofighter";
var d_map6_7 = "After you have earned this amount a 14 day burn-in period is required before we can launch";
var d_map6_8 = "I strongly advise you capture the oil derricks and minimize spending on your army where possible";
var d_map6_9 = "Also, our sattellites can confirm a new wave of enemy troops will arrive every 10 turns";
var d_map6_10 = "This is the one and only opportunity we have to remove Chinese advantage, godspeed Commander!";
var d_map6_12 = "The stratofighter burn in has started thanks to your help raising the funding!";
var d_map6_13 = "Launch will commence in 14 days, keep the stratofighter safe!";
var d_map6_e = "What the!? Camp David has been obliterated! It seems you got the Stratofighter in the air just in time!";
var d_map7_1 = "Those damn reds have reached one of our main military bases near Ohio's southern border. You were closest...so you're in charge.";
var d_map7_2 = "This is a straight fight with everything our military could throw into Ohio, against everything they could.";
var d_map7_3 = "Be sure not to let your supply lines fall behind, or your all-important tanks could run out of fuel";
var d_map7_4 = "And you've been picked to ensure it's successful launch!";
var d_map7_5 = "Oh, and also...the enemy's orbital satellite is poised over Ohio right now. Be careful-they may shoot!";
var d_map7_e = "Nice work, Commander. The enemy's totally in awe of your attack. You crushed 'em good and proper!";
var d_map8_1 = "Wilde? Commander Wilde, are you there?";
var d_map8_2 = "No! They've dropped paratroopers and TANKS! into New York City...";
var d_map8_3 = "I hate to order artillery bombardment into our wonderful New York, but needs must.";
var d_map8_4 = "And we need those Chinese out of the city as quickly as possible, before they can mass and attack our front line from behind.";
var d_map8_e = "That's it! All enemy forces dead or captured. The Big Apple is ripe with good old American spirit!";
var d_map9_1 = "This is it, Commander. The first major chance to kick back against the Chinese";
var d_map9_2 = "We managed to surprise them in New York and other parts of the northern states";
var d_map9_3 = "They're trying to regroup and come at us again";
var d_map9_4 = "Smash that entire Army, and an end to this war could be within sight";
var d_map9_5 = "This is it, Commander. The first major chance to kick back against the Chinese";
var d_map9_6 = "Oh, just one more thing...they're still keeping that big eye in the sky on you. Be careful, they may shoot";
var d_map9_e = "Excellent work, Commander. What's left of the 3rd Army is in full retreat across America";
var d_map10_1 = "The Chinese are trying to deploy a second wave of troops, escorted by God knows how many ships and subs.";
var d_map10_2 = "We simply have to secure the coastline, and not let too many of their landing craft get to ground.";
var d_map10_3 = "Don't worry, Commander. I'll be with you all the way.";
var d_map10_e = "The only part of USA they'll invade now is the bottom of our territorial waters.";
var d_map11_1 = "What are you doing? We need you here on land! This battle isn't authorsed!";
var d_map11_2 = "So you say there's a whole second reserve force at anchor here? hmm if we can destroy them, They'll will be as good as ours.";
var d_map11_3 = "Alright...do it. But be quick. We need the you in Oklahoma.";
var d_map11_e = "With that victory, the Chinese forces are suffocating in the footholds they still have in America... it's only a matter of time.";
var d_map12_1 = "Your mission here is to reclaim the airbase and use it to help you break into New Mexico.";
var d_map12_2 = "It won't be easy. The AFB is heavily defended, and there are SAMs all over the place.";
var d_map12_3 = "But after what we've seen of you, I think you're more than capable. Good luck, sir.";
var d_map12_e = "Well done, sir. With the skies firmly in our grasp, we can now begin to reclaim the southern states with all due haste.";
var d_map13_1 = "Sir, General Zhao is in command of this army. He's one of the most feared generals China has to offer";
var d_map13_2 = "Just be careful, and watch your back! Good Luck!";
var d_map13_e = "Good work sir! I must say your conduct is exemplary.";
var d_map14_1 = "The enemy controls the factories in this area, which means he has a sustained fighting force";
var d_map14_2 = "You are going to have to take your initial deployment before they know what's hit them!";
var d_map14_3 = "Best of luck! but act fast, if the enemy gets a chance to respond your strike team wont have a chance!";
var d_map14_e = "We've got the remainder of the Chinese on the run. We're at the Idaho Rockies in the north...only a few more Chinese-held states are left to reclaim.";
var d_map15_1 = "The enemy have a bunch of outposts stationed up here. The mountain pass will be treacherous, and force our units into a bottleneck.";
var d_map15_2 = "But we have a group of artillery in position. They should help make it a little easier.";
var d_map15_3 = "My advice would be to take each one in turn, starting with the nearest, and seize the production facility to keep an army going.";
var d_map15_4 = "Good Luck!";
var d_map15_e = "The destruction of those outposts will be a real blow to the ailing Chinese forces. They've now got no real foothold to the north";
var d_map16_1 = "This might seem strange, Sir, but we're planning to establish a beachhead in California...";
var d_map16_2 = "They've got resistance waiting on the coast, though. You'll need to get the landers in quickly";
var d_map16_3 = "Act fast, and good luck!";
var d_map16_e = "Good work, you two. The Chinese have deployed more of their special paratroops all across California and Nevada. They REALLY aren't giving up.";
var d_map17_1 = "They're training their missile bases on your advancing forces through California.";
var d_map17_2 = "They also dropped in a whole bunch of units before our SAMs could get into range. They're sure to drop more, though.";
var d_map17_3 = "Capture the enemy base, and smash the units already there.";
var d_map17_4 = "Watch the radius of attack available to the enemy! You will have to plan your attack very carefully to succeed";
var d_map17_e = "Sir. The last remaining OpFor are dug in around the Nevada missile bases. And by God, they don't plan to move.";
var d_map18_1 = "China has hacked the nuclear access codes, we've got to capture their base ASAP!";
var d_map18_2 = "This is all we could scrape together...all the other units are way out of range. It'll be too late by the time they arrive.";
var d_map18_3 = "We're going to have to punch through the defence, and recapture that missile base before it launches!";
var d_map18_e = "Damn, that was close...but the USA is safe - Just one more mission. The Chinese will surrender after this last move. They'll have no choice.";
var d_map19_1 = "The Chinese and North Koreans steamrolled the South at the same time as they threw their forces at the States. ";
var d_map19_2 = "They didn't have a choice...the missile bases there would have let us pulverise China in retaliation for the invasion.";
var d_map19_3 = "Use your infantry to secure that airbase, then combine infantry with aerial attack to reclaim South Korea";
var d_map19_4 = "After that, the Chinese will be firmly put back in Pandora's Box.";
var d_map19_5 = "Be warned the enemy have a huge resource advantage being so close to their home soil";
var d_map19_6 = "Best of luck commander! Lets end this!";
var d_map19_e = "The Chinese have retreated from South Korea. We are getting word that China has surrended.";
var seq = 1;
var speech = "";
}
Symbol 1489 MovieClip [__Packages.Enemy] Frame 0
class Enemy extends MovieClip
{
var myMode, myHQ;
function Enemy () {
super();
Assess();
}
function Assess(single) {
var _local3;
markedUnit = new Array();
comPower = 0;
comHealth = 0;
playerHealth = 0;
playerPower = 0;
myUnits = new Array();
myFactories = new Array();
myAirports = new Array();
mySeaports = new Array();
var _local4 = 0;
var _local6 = 0;
var _local8 = 0;
var _local5 = 0;
var _local7 = 0;
var _local9;
_local3 = 0;
while (_local3 < 100) {
if (_root["unit" + _local3].team == 1) {
if (_root["unit" + _local3] != undefined) {
myUnits.push(_local3);
}
}
_local3++;
}
_local3 = 0;
while (_local3 < 99) {
if (_root["unit" + _local3].team != 0) {
comPower = comPower + int(_root["unit" + _local3].ap);
comHealth = comHealth + int(_root["unit" + _local3].hp);
} else {
playerHealth = playerHealth + int(_root["unit" + _local3].hp);
playerPower = playerPower + int(_root["unit" + _local3].ap);
}
_local3++;
}
_local3 = 0;
while (_local3 < 280) {
if ((_root["t" + _local3].hq == true) && (_root["t" + _local3].city_owner == 1)) {
_local9 = _root["t" + _local3].hq;
}
if ((_root["t" + _local3].city_owner == 1) && (_root["t" + _local3].factory == true)) {
myFactories.push(_root["t" + _local3]);
}
if ((_root["t" + _local3].city_owner == 1) && (_root["t" + _local3].airport == true)) {
myAirports.push(_root["t" + _local3]);
}
if ((_root["t" + _local3].city_owner == 1) && (_root["t" + _local3].seaport == true)) {
mySeaports.push(_root["t" + _local3]);
}
if ((_root["t" + _local3].airport == true) && (_root["t" + _local3].city_owner != 1)) {
_local6++;
}
if ((_root["t" + _local3].seaport == true) && (_root["t" + _local3].city_owner != 1)) {
_local5++;
}
if ((_root["t" + _local3].derrick == true) && (_root["t" + _local3].city_owner != 1)) {
_local7++;
}
if ((_root["t" + _local3].city == true) && (_root["t" + _local3].city_owner != 1)) {
_local4++;
}
if ((_root["t" + _local3].factory == true) && (_root["t" + _local3].city_owner != 1)) {
_local8++;
}
_local3++;
}
if (((comHealth + comPower) > ((playerHealth + playerPower) + 1000)) && (random(100) > 10)) {
myMode = "attack";
} else if (((((_local8 > 0) | (_local4 > 0)) | (_local7 > 0)) | (_local5 > 0)) | (_local6 > 0)) {
myMode = "capture";
} else {
myMode = "defend";
}
if (single == undefined) {
Think();
}
}
function Think() {
var _local3;
var _local4;
_local3 = 0;
while (_local3 < myUnits.length) {
if (_root.lock == false) {
_root["unit" + myUnits[_local3]].my_target = DecideTarget(myUnits[_local3]);
if (_root["unit" + myUnits[_local3]].my_target == undefined) {
_root["unit" + myUnits[_local3]].my_target = DecideWaypoint(myUnits[_local3]);
}
}
_local3++;
}
RunBuild();
}
function RunBuild() {
var _local4;
var _local3;
var _local5 = false;
_local4 = 0;
while (_local4 < myFactories.length) {
_local3 = 0;
while (_local3 < 100) {
if (myFactories[_local4].hitTest(_root["unit" + _local3])) {
_local5 = true;
}
_local3++;
}
if (_local5 == false) {
_root.selectedBuild = myFactories[_local4];
DecideBuild();
}
_local4++;
}
}
function DecideWaypoint(unit) {
var _local8;
var _local3;
var _local4 = 0;
var _local5 = 1000000 /* 0x0F4240 */;
var _local6;
_local3 = 0;
while (_local3 < 280) {
if (_root["t" + _local3].waypoint == true) {
_local6 = int(_root.getDistanceX(_root["unit" + unit], _root["t" + _local3]) + _root.getDistanceY(_root["unit" + unit], _root["t" + _local3]));
_local4 = int(_local6) + int(markedUnit[_local3] * 1.55);
if (_local4 < _local5) {
_local5 = _local4;
markedUnit[_local3] = int(markedUnit[_local3]) + 1;
_local8 = _root["t" + _local3];
}
}
_local3++;
}
if (_local8 == undefined) {
_local8 = _root["unit" + DecideAttack(unit)];
}
return(_local8);
}
function DecideAttack(unit) {
var _local3;
var _local5 = 0;
var _local7 = 1000000 /* 0x0F4240 */;
var _local12;
var _local8;
var _local9;
var _local11;
var _local10;
var _local4;
_local3 = 0;
while (_local3 < 50) {
if (((_root["unit" + _local3].team != 1) && (_root["unit" + _local3]._alpha > 90)) && (_root["unit" + unit].AttackValidate(_root["unit" + _local3]) == true)) {
_local8 = int(_root.getDistanceX(_root["unit" + unit], _root["unit" + _local3]) + _root.getDistanceY(_root["unit" + unit], _root["unit" + _local3]));
_local9 = int(_root["unit" + _local3].hp);
_local11 = int(_root["unit" + _local3].ap);
_local10 = int(_root["unit" + _local3].dp);
if (int(markedUnit[_local3]) > 0) {
if (_root.selectedUnit.my_target == _root["unit" + _local3]) {
_local4 = int(markedUnit[_local3] + 1) * 2.56;
} else {
_local4 = int(markedUnit[_local3] + 1) * 2.11;
}
} else {
_local4 = 1;
}
if ((_root["unit" + _local3].unitType == "foot") && (_root.getDistance(_root["unit" + _local3], myHQ) < 400)) {
_local4 = int(markedUnit[_local3] + 1) * 0.3;
}
_local5 = int(((_local8 * _local9) + (_local11 * _local10)) * _local4);
if (_local5 < _local7) {
_local7 = _local5;
markedUnit[_local3] = int(markedUnit[_local3]) + 1;
_local12 = _root["unit" + _local3];
}
}
_local3++;
}
return(_local12);
}
function DecideTarget(unit) {
var _local3;
var _local5 = 0;
var _local7 = 100000 /* 0x0186A0 */;
var _local9;
var _local8;
var _local11;
var _local4;
var _local12;
var _local10;
if ((myMode == "capture") && (_root["unit" + unit].unitType == "foot")) {
_local3 = 0;
while (_local3 < 280) {
if ((_root["t" + _local3].city == true) && (_root["t" + _local3].city_owner != 1)) {
_local4 = 2.5;
if (_root["t" + _local3].factory == true) {
_local4 = 1.5;
}
if (_root["t" + _local3].airport == true) {
_local4 = 1.4;
}
if (_root["t" + _local3].hq == true) {
_local4 = 1.1;
}
if (_root["t" + _local3].derrick == true) {
_local4 = 1.5;
}
if (_root["t" + _local3].seaport == true) {
_local4 = 1.7;
}
_local8 = int(_root.getDistanceX(_root["unit" + unit], _root["t" + _local3]) + _root.getDistanceY(_root["unit" + unit], _root["t" + _local3]));
_local5 = int(_local8 * _local4) + int(markedUnit[_local3] * 1000);
if (_local5 < _local7) {
_local7 = _local5;
markedUnit[_local3] = int(markedUnit[_local3]) + 1;
_local9 = _root["t" + _local3];
}
}
_local3++;
}
} else {
_local9 = DecideAttack(unit);
}
return(_local9);
}
function AssessAttack(unit) {
var _local2 = 0;
var _local5 = 0;
var _local4 = new Array();
var _local7;
var _local6 = 0;
unit.x = 1500;
_root.k = 0;
unit.FindAttack();
_local2 = 0;
while (_local2 < 50) {
if ((_root["a" + _local2].owner == unit.my_target) && (unit == _root["a" + _local2].by)) {
_local5 = 250;
_local4[_local2] = (int(_local4[_local2]) + _local5) + int(100 - _root["a" + _local2].owner.hp);
}
if ((int(_root["a" + _local2].owner.team) != 1) && (unit == _root["a" + _local2].by)) {
_local5 = 200;
_local4[_local2] = (int(_local4[_local2]) + _local5) + int(100 - _root["a" + _local2].owner.hp);
}
if ((_local4[_local2] >= _local6) && (_root["a" + _local2] != undefined)) {
_local6 = _local4[_local2];
_local7 = _root["a" + _local2].owner;
}
_local2++;
}
if (int(_local6) >= 50) {
unit.Attack(_local7);
unit.attacked = true;
unit.moved = true;
unit.moves_left = 0;
unit.Deselect();
}
}
function MoveUnit(unit) {
var _local3;
var _local5;
var _local4;
var _local6;
_root.selectedUnit = unit;
AssessAttack(unit);
_root.selectedUnit = unit;
unit.goCapture();
_root.selectedUnit = unit;
if (unit.attacked == false) {
_local3 = 0;
while (_local3 < 100) {
if (_root["a" + _local3].owner.team != 1) {
if (_root.selectedUnit.DamageCalc(_root["a" + _local3], true) >= 10) {
_root.selectedUnit.Attack(_root["a" + _local3].owner);
_root.selectedUnit.moved = true;
_root.selectedUnit.moves_left = 0;
_root.selectedUnit.Deselect();
break;
}
}
_local3++;
}
}
_root.selectedUnit = unit;
if (_root.selectedUnit.frozen == true) {
_root.selectedUnit.moved = true;
_root.selectedUnit.attacked = true;
_root.selectedUnit.moves_left = 0;
}
_root.selectedUnit = unit;
if (_root.selectedUnit.my_target == undefined) {
_root.selectedUnit.attacked = true;
}
if (_root.selectedUnit.attacked == false) {
_root.selectedUnit.FindMovement();
_local3 = 1500;
while (_local3 < 1600) {
if (_root["m" + _local3].allowed == true) {
if (_root["m" + _local3] != undefined) {
_local4 = int(_root["m" + _local3].closeness);
if (_local4 <= _local5) {
_local5 = int(_local4);
_local6 = _root["m" + _local3];
}
}
}
_local3++;
}
if (_local6 != undefined) {
_root.selectedUnit.route_x.push(_local6._x);
_root.selectedUnit.route_y.push(_local6._y);
_local3 = int(_local6.parent);
while (_root["m" + _local3] != undefined) {
_root.selectedUnit.route_x.push(_root["m" + _local3]._x);
_root.selectedUnit.route_y.push(_root["m" + _local3]._y);
_local3 = int(_root["m" + _local3].parent);
}
_root.selectedUnit.Move(_local6);
}
}
}
function FindEnemyUnits() {
var _local3 = 0;
playerUnits = new Array();
_local3 = 0;
while (_local3 <= 50) {
if (_root["unit" + _local3].team != 1) {
switch (_root["unit" + _local3].unitType) {
case "foot" :
playerUnits.infantry = int(playerUnits.infantry) + 1;
break;
case "air" :
playerUnits.air = int(playerUnits.air) + 1;
break;
case "track" :
switch (_root["unit" + _local3].unitClass) {
case "aa" :
playerUnits.AA = int(playerUnits.AA) + 1;
break;
case "sam" :
playerUnits.AA = int(playerUnits.AA) + 1;
playerUnits.AA = int(playerUnits.AA) + 1;
break;
case "artillery" :
playerUnits.range = int(playerUnits.range) + 1;
break;
case "rocket launcher" :
playerUnits.range = int(playerUnits.range) + 1;
break;
case "tank" :
playerUnits.armor = int(playerUnits.armor) + 1;
}
break;
case "wheel" :
playerUnits.wheel = int(playerUnits.wheel) + 1;
break;
case "sea" :
playerUnits.sea = int(playerUnits.sea) + 1;
}
} else {
switch (_root["unit" + _local3].unitType) {
case "foot" :
playerUnits.infantry = int(playerUnits.infantry) - 1;
break;
case "air" :
playerUnits.air = int(playerUnits.air) - 1;
break;
case "track" :
switch (_root["unit" + _local3].unitClass) {
case "aa" :
playerUnits.AA = int(playerUnits.AA) - 1;
break;
case "sam" :
playerUnits.AA = int(playerUnits.AA) - 1;
playerUnits.AA = int(playerUnits.AA) - 1;
break;
case "artillery" :
playerUnits.range = int(playerUnits.range) - 1;
break;
case "rocket launcher" :
playerUnits.range = int(playerUnits.range) - 1;
break;
case "tank" :
playerUnits.armor = int(playerUnits.armor) - 1;
}
break;
case "wheel" :
playerUnits.wheel = int(playerUnits.wheel) - 1;
break;
case "sea" :
playerUnits.sea = int(playerUnits.sea) - 1;
}
}
_local3++;
}
}
function DecideBuild() {
var _local2;
var _local3 = 0;
_local2 = PlayerMainUnit();
BuildBestCounter(_local2);
}
function PlayerMainUnit() {
var _local2 = "staple";
var _local3 = 0;
FindEnemyUnits();
if (playerUnits.infantry > _local3) {
_local2 = "infantry";
}
if (playerUnits.AA > _local3) {
_local2 = "AA";
}
if (playerUnits.range > _local3) {
_local2 = "range";
}
if (playerUnits.armor > _local3) {
_local2 = "armor";
}
if (playerUnits.wheel > _local3) {
_local2 = "wheel";
}
if (playerUnits.sea > _local3) {
_local2 = "sea";
}
if (playerUnits.air > _local3) {
_local2 = "air";
}
return(_local2);
}
function BuildBestCounter(unit2Counter) {
var _local3;
var _local2 = random(12);
switch (unit2Counter) {
case "infantry" :
if (_local2 < 4) {
_root.buildUnit("red_infantry", 1, "foot", "infantry");
} else if (_local2 < 7) {
_root.buildUnit("red_rocketinf", 1, "foot", "rocket infantry");
} else {
_root.buildUnit("red_aa", 1, "track", "aa");
}
break;
case "armor" :
if (_local2 < 7) {
_root.buildUnit("red_rocketinf", 1, "foot", "rocket infantry");
} else if (_local2 < 10) {
_root.buildUnit("red_tank", 1, "track", "tank");
} else {
_root.buildUnit("red_art", 1, "track", "artillery");
}
break;
case "AA" :
if (_local2 < 5) {
_local3 = "tank";
} else if (_local3 < 10) {
_root.buildUnit("red_art", 1, "track", "artillery");
} else {
_root.buildUnit("red_rocket", 1, "track", "rocket");
}
break;
case "range" :
if (_local2 < 5) {
_root.buildUnit("red_helicopter", 1, "air", "helicopter");
} else {
_root.buildUnit("red_bomber", 1, "air", "bomber");
}
break;
case "wheel" :
if (_local2 < 5) {
_root.buildUnit("red_tank", 1, "track", "tank");
} else {
_root.buildUnit("red_rocketinf", 1, "foot", "rocket infantry");
}
break;
case "air" :
if (_local2 < 5) {
_root.buildUnit("red_aa", 1, "track", "aa");
}
if (_local2 < 8) {
_root.buildUnit("red_fighter", 1, "air", "fighter");
} else {
_root.buildUnit("red_sam", 1, "track", "sam");
}
break;
case "staple" :
if (_local2 < 4) {
_root.buildUnit("red_tank", 1, "track", "tank");
} else if (_local2 < 7) {
_root.buildUnit("red_infantry", 1, "foot", "infantry");
} else {
_root.buildUnit("red_rocketinf", 1, "foot", "rocket infantry");
}
}
}
var comPower = 0;
var comHealth = 0;
var playerHealth = 0;
var playerPower = 0;
var myUnits = new Array(50);
var myFactories = new Array(25);
var myAirports = new Array(25);
var mySeaports = new Array(25);
var markedUnit = new Array(280);
var playerUnits = new Array(50);
var myTypes = new Array(50);
}
Symbol 1490 MovieClip [__Packages.ElectroServer] Frame 0
class ElectroServer extends XMLSocket
{
static var _instance;
var buddyList, zone, connectionClosed, moderatorLabel, ip, port, inGame, myUser, username, password, configurationLoaded, pendingZone, pendingRoom, auto_join, joiningRoom, ConnectedToServer, onConnection, rawMessageReceived, onConnect, onXML, loggedIn, allZonesLoaded, userLocationLoaded, usersInRoomLoaded, buddyLoggedOut, buddyLoggedIn, configXML, userVariableUpdated, roomVariablesUpdated, roomJoined, userListUpdated, isGameMaster, usersRenumbered, moveReceived, messageReceived, onRoomsInZoneLoaded, zoneChanged, roomListUpdated, pluginMessageReceived, loggedInUserCountUpdated, onGetServerTime, zoneUpdated;
function ElectroServer () {
super();
buddyList = new Array();
zone = new Object();
zone.rooms = new Array();
}
function ValidateVersion(Major, Minor, Sub) {
var _local2 = true;
if ((MajorVersion > Major) || (isNaN(Major))) {
_local2 = false;
} else if ((MinorVersion > Minor) && (MajorVersion == Major)) {
_local2 = false;
} else if ((SubVersion > Sub) && (MinorVersion == Minor)) {
_local2 = false;
}
return(_local2);
}
function onClose() {
isConnected = false;
connectionClosed(true);
}
function removeBuddy(name) {
var _local2 = 0;
while (_local2 < buddyList.length) {
if (buddyList[_local2].username == name) {
buddyList.splice(_local2, 1);
break;
}
_local2++;
}
var _local5 = "DeleteFriend";
var _local4 = ("<FriendName>" + name) + "</FriendName>";
send(_local5, _local4);
}
function getUsersInRoom(zone, room) {
var _local3 = "GetUsersInRoom";
var _local2 = ((("<Zone>" + zone) + "</Zone><Room>") + room) + "</Room>";
send(_local3, _local2);
}
function getUserLocation(name) {
var _local3 = "GetUserLocation";
var _local2 = ("<UserName>" + name) + "</UserName>";
send(_local3, _local2);
}
function registerRawHandler(name) {
var _local3 = "RegisterRawHandler";
var _local2 = ("<Name>" + name) + "</Name>";
send(_local3, _local2);
}
function getBuddyList() {
return(buddyList);
}
function addBuddy(name) {
var _local3 = false;
var _local2 = 0;
while (_local2 < buddyList.length) {
if (buddyList[_local2].username == name) {
_local3 = true;
break;
}
_local2++;
}
if (!_local3) {
var _local4 = new Object();
_local4.isOnline = false;
_local4.username = name;
_local4.status = "offline";
_local4.label = (_local4.username + " ") + _local4.status;
buddyList.push(_local4);
var _local7 = "AddFriend";
var _local6 = ("<FriendName>" + name) + "</FriendName>";
send(_local7, _local6);
}
}
function close() {
super.close();
connectionClosed(false);
}
function getServerTime() {
var _local3 = "GetServerTime";
var _local2 = "";
send(_local3, _local2);
}
function getLoggedInUserCount() {
var _local3 = "GetLoggedInUserCount";
var _local2 = "";
send(_local3, _local2);
}
function setModeratorLabel(val, str) {
showModeratorLabel = val;
moderatorLabel = str;
if (str == undefined) {
moderatorLabel = " [Moderator]";
}
}
static function getInstance() {
if (_instance == null) {
_instance = new ElectroServer();
}
return(_instance);
}
function setDebug(val) {
debug = val;
}
function getDebug() {
return(debug);
}
function getIP() {
return(ip);
}
function getPort() {
return(port);
}
function setIP(tempIP) {
ip = tempIP;
}
function setPort(tempPort) {
port = tempPort;
}
function deleteRoomVariable(name) {
var _local3 = "DeleteRoomVariable";
var _local2 = ("<RoomVariable ><Name>" + name) + "</Name></RoomVariable>";
send(_local3, _local2);
}
function getRoomsInZone(tmp_zone) {
var _local3 = "GetRoomsInZone";
var _local2 = ("<Zone>" + tmp_zone) + "</Zone>";
send(_local3, _local2);
}
function changeRoomDetail(detail, value) {
var _local11 = "ChangeRoomDetails";
var _local4;
var _local3;
detail = detail.toLowerCase();
var _local6 = "";
if (detail == "description") {
_local4 = "ChangeDescription";
_local3 = "Description";
value.attributes.isGameRoom = true;
var _local9 = new Wddx();
var _local10 = ("<![CDATA[" + _local9.serialize(value)) + "]]>";
} else if (detail == "updatable") {
_local4 = "ChangeUpdatable";
_local3 = "Updatable";
var _local10 = value;
} else if (detail == "hidden") {
_local4 = "ChangeVisibility";
_local3 = "Hidden";
var _local10 = value;
} else if (detail == "capacity") {
_local4 = "ChangeCapacity";
_local3 = "Capacity";
if ((value == undefined) || (value == 0)) {
value = -1;
}
var _local10 = value;
} else if (detail == "password") {
_local4 = "ChangePasswordProtected";
_local3 = "Password";
var _local10 = value;
var _local7;
if (value == undefined) {
value = "";
}
if (value.length >= 1) {
_local7 = true;
} else {
_local7 = false;
}
_local6 = ("<IsProtected>" + _local7) + "</IsProtected>";
}
var _local8 = ((((((((("<MinorAction>" + _local4) + "</MinorAction>") + _local6) + "<") + _local3) + ">") + _local10) + "</") + _local3) + ">";
send(_local11, _local8);
}
function kick(name, reason) {
if (reason == undefined) {
reason = "";
}
var _local4 = "ModeratorCommand";
var _local2 = ((("<MinorAction>Kick</MinorAction><UserName>" + name) + "</UserName><Reason>") + reason) + "</Reason>";
send(_local4, _local2);
}
function ban(name, reason, expires) {
if (reason == undefined) {
reason = "";
}
if (expires == undefined) {
expires = "-1";
}
var _local5 = "ModeratorCommand";
var _local2 = ((((("<MinorAction>Ban</MinorAction><UserName>" + name) + "</UserName><Reason>") + reason) + "</Reason><Expires>") + expires) + "</Expires>";
send(_local5, _local2);
}
function createUserVariable(name, value) {
var _local3 = "UpdateUserVariable";
var _local2 = ((("<MinorAction>Create</MinorAction><Name>" + name) + "</Name><Data>") + value) + "</Data>";
send(_local3, _local2);
}
function getAllZones() {
send("GetAllZones", "");
}
function updateUserVariable(name, value) {
var _local3 = "UpdateUserVariable";
var _local2 = ((("<MinorAction>Update</MinorAction><Name>" + name) + "</Name><Data>") + value) + "</Data>";
send(_local3, _local2);
}
function deleteUserVariable(name, value) {
var _local3 = "UpdateUserVariable";
var _local2 = ("<MinorAction>Delete</MinorAction><Name>" + name) + "</Name>";
send(_local3, _local2);
}
function createRoomVariable(ob) {
var _local3 = ob.name;
var _local6 = ob.data;
var _local4 = ob.persistent;
var _local2 = ob.locked;
if (_local4 == undefined) {
_local4 = false;
}
if (_local2 == undefined) {
_local2 = false;
}
if (zone.myRoom.roomVariables[_local3] == undefined) {
var _local8 = "CreateRoomVariable";
var _local7 = ((((((("<RoomVariable Persistent=\"" + _local4) + "\" Locked=\"") + _local2) + "\" ><Name>") + _local3) + "</Name><Data><![CDATA[") + _local6) + "]]></Data></RoomVariable>";
} else {
var _local8 = "UpdateRoomVariable";
var _local7 = ((((("<RoomVariable Locked=\"" + _local2) + "\" ><Name>") + _local3) + "</Name><Data><![CDATA[") + _local6) + "]]></Data></RoomVariable>";
}
send(_local8, _local7);
}
function getZone() {
return(zone);
}
function sendMove(who, ob) {
var _local8 = new Wddx();
var _local6 = _local8.serialize(ob);
if (who.toLowerCase() == "all") {
var _local9 = "SendPublicMessage";
var _local7 = ("<Message><![CDATA[" + _local6) + "]]></Message><Variables><Variable><Name>Action</Name><Data>Move</Data></Variable><Variable><Name>MoveType</Name><Data>Public</Data></Variable></Variables>";
} else {
var _local9 = "SendPrivateMessage";
var _local4 = who;
var _local5 = "<Users>";
var _local2 = 0;
while (_local2 < _local4.length) {
var _local3 = _local4[_local2];
_local5 = _local5 + (("<User>" + _local3) + "</User>");
_local2++;
}
_local5 = _local5 + "</Users>";
var _local7 = ((_local5 + "<Message><![CDATA[") + _local6) + "]]></Message><Variables><Variable><Name>Action</Name><Data>Move</Data></Variable><Variable><Name>MoveType</Name><Data>Public</Data></Variable></Variables>";
}
send(_local9, _local7);
}
function pluginRequest(plugin, method, parameters) {
var _local5 = "ExecutePlugin";
var _local3 = "<Variables />";
if (parameters != undefined) {
_local3 = "<Variables>";
for (var _local4 in parameters) {
_local3 = _local3 + (((("<Variable><Name>" + _local4) + "</Name><Value>") + parameters[_local4]) + "</Value></Variable>");
}
_local3 = _local3 + "</Variables>";
}
var _local6 = (((("<Plugin>" + plugin) + "</Plugin><Method>") + method) + "</Method>") + _local3;
send(_local5, _local6);
}
function getRoomVariables() {
return(zone.myRoom.roomVariables);
}
function getRoomList() {
return(zone.rooms);
}
function getRoom() {
return(zone.myRoom);
}
function getUserList() {
return(zone.users);
}
function createGameRoom(roomOb) {
if (roomOb.attributes == undefined) {
roomOb.attributes = new Object();
}
roomOb.attributes.isGameRoom = true;
if (roomOb.updatable != true) {
roomOb.updatable = false;
}
roomOb.numbered = true;
createRoom(roomOb);
inGame = true;
}
function joinGame(room, password, type, zone) {
type = type.toLowerCase();
if ((type == "player") || (type == undefined)) {
var _local3 = true;
} else if (type == "spectator") {
var _local3 = false;
}
joinRoom(room, password, zone, _local3);
inGame = true;
}
function adminLogin(tempUsername, tempPassword) {
myUser.username = tempUsername;
if (tempPassword == undefined) {
tempPassword = "";
}
myUser.password = tempPassword;
username = myUser.username;
password = myUser.password;
var _local3 = "AdminLogin";
var _local2 = ((("<Name>" + myUser.username) + "</Name><Password>") + myUser.password) + "</Password>";
send(_local3, _local2);
}
function loadConfiguration() {
var _local3 = "LoadConfiguration";
var _local2 = "";
send(_local3, _local2);
}
function parseConfig(config) {
XML.prototype.ignoreWhite = true;
var _local3 = new XML(config);
var _local2 = new Object();
parseParameters(_local3.firstChild.childNodes, _local2);
configurationLoaded(_local2);
}
function sendMessage(type, message, users, variables) {
type = type.toLowerCase();
if ((type == "public") || (type == "all")) {
sendPublicMessage(message, users);
} else if (type == "private") {
sendPrivateMessage(message, users, variables);
}
}
function joinRoom(room, password, zoneName, numbered) {
var _local6 = "JoinRoom";
if (numbered == undefined) {
numbered = true;
}
if (password == undefined) {
password = "";
}
if (zoneName == undefined) {
zoneName = getZone().name;
if (zoneName == undefined) {
zoneName = "Chat Area";
}
}
pendingZone = zoneName;
pendingRoom = room;
inGame = false;
var _local3 = ((((((("<Zone><Name>" + zoneName) + "</Name><Room><Name>") + room) + "</Name><Password>") + password) + "</Password><Numbered>") + numbered) + "</Numbered></Room></Zone>";
send(_local6, _local3);
}
function createRoom(roomOb, auto) {
if ((auto == undefined) || (auto == "true")) {
auto = true;
} else {
auto = false;
}
auto_join = auto;
var _local34 = "CreateRoom";
var _local24 = roomOb.password;
var _local22 = roomOb.userVariablesEnabled;
var _local27 = roomOb.hidden;
var _local19 = roomOb.zone;
var _local30 = roomOb.roomName;
var _local26 = roomOb.numbered;
var _local25 = roomOb.capacity;
var _local20 = roomOb.description;
var _local14 = roomOb.roomVariables;
var _local29 = roomOb.updatable;
var _local13 = roomOb.plugins;
var _local23 = roomOb.FloodingFilterEnabled;
var _local28 = new Object();
if (_local20 == undefined) {
_local20 = roomOb.Description;
if (_local20 == undefined) {
_local20 = "";
}
}
if (_local23 == undefined) {
_local23 = false;
}
_local28.description = _local20;
if (roomOb.attributes != undefined) {
_local28.attributes = roomOb.attributes;
}
var _local32 = new Wddx();
var _local33 = _local32.serialize(_local28);
if (_local19 == undefined) {
_local19 = getZone().name;
if (_local19 == undefined) {
_local19 = "Chat Area";
}
}
if (_local29 == undefined) {
_local29 = true;
}
if (_local27 == undefined) {
_local27 = false;
}
if (_local25 == undefined) {
_local25 = -1;
}
if (_local26 == undefined) {
_local26 = false;
}
if (_local24 == undefined) {
_local24 = "";
}
if (_local22 == undefined) {
_local22 = false;
}
if (_local14 == undefined) {
var _local18 = "<RoomVariables/>";
} else {
var _local18 = "<RoomVariables>";
var _local8 = 0;
while (_local8 < _local14.length) {
var _local3 = _local14[_local8];
var _local9 = _local3.persistent;
var _local7 = _local3.locked;
var _local11 = _local3.name;
var _local12 = _local3.data;
if (_local9 == undefined) {
_local9 = false;
}
if (_local7 == undefined) {
_local7 = false;
}
var _local4 = ((("<RoomVariable Persistent=\"" + _local9) + "\" Locked=\"") + _local7) + "\">";
_local4 = _local4 + (("<Name>" + _local11) + "</Name>");
_local4 = _local4 + (("<Data><![CDATA[" + _local12) + "]]></Data>");
_local4 = _local4 + "</RoomVariable>";
_local18 = _local18 + _local4;
_local8++;
}
_local18 = _local18 + "</RoomVariables>";
}
if (_local13 == undefined) {
var _local17 = "<Plugins />";
} else {
var _local17 = "<Plugins>";
var _local8 = 0;
while (_local8 < _local13.length) {
var _local10 = _local13[_local8];
var _local11 = _local10.name;
var _local2 = _local10.variables;
if (_local2 == undefined) {
var _local5 = "<Variables />";
} else {
var _local5 = "<Variables>";
for (var _local16 in _local2) {
var _local6 = _local2[_local16];
_local5 = _local5 + (((("<Variable><Name>" + _local16) + "</Name><Value>") + _local6) + "</Value></Variable>");
}
_local5 = _local5 + "</Variables>";
}
_local17 = _local17 + (((("<Plugin><Name>" + _local11) + "</Name>") + _local5) + "</Plugin>");
_local8++;
}
_local17 = _local17 + "</Plugins>";
}
var _local31 = (((((((((((((((((((((("<Zone><Name>" + _local19) + "</Name><Room Updatable=\"") + _local29) + "\" Hidden=\"") + _local27) + "\" FloodingFilterEnabled=\"") + _local23) + "\" Numbered=\"") + _local26) + "\" UserVariablesEnabled=\"") + _local22) + "\"><Name>") + _local30) + "</Name><Password>") + _local24) + "</Password><Description><![CDATA[") + _local33) + "]]></Description><Capacity>") + _local25) + "</Capacity>") + _local18) + _local17) + "</Room></Zone>";
joiningRoom = true;
pendingRoom = _local30;
pendingZone = _local19;
inGame = false;
send(_local34, _local31);
}
function sendPublicMessage(message, variables) {
var _local7 = "SendPublicMessage";
var _local3 = "";
for (var _local5 in variables) {
var _local2 = variables[_local5].toString();
_local3 = _local3 + (((("<Variable><Name>" + _local5) + "</Name><Data><![CDATA[") + _local2) + "]]></Data></Variable>");
}
if (_local3 != "") {
_local3 = ("<Variables>" + _local3) + "</Variables>";
} else {
_local3 = "<Variables />";
}
var _local6 = (("<Message><![CDATA[" + message) + "]]></Message>") + _local3;
send(_local7, _local6);
}
function sendPrivateMessage(message, users, variables) {
var _local10 = "SendPrivateMessage";
var _local7 = "<Users>";
var _local8 = 0;
while (_local8 < users.length) {
var _local3 = users[_local8];
_local7 = _local7 + (("<User>" + _local3) + "</User>");
_local8++;
}
_local7 = _local7 + "</Users>";
var _local4 = "";
for (_local8 in variables) {
var _local2 = variables[_local8];
_local4 = _local4 + (((("<Variable><Name>" + _local8) + "</Name><Data><![CDATA[") + _local2) + "]]></Data></Variable>");
}
if (_local4 != "") {
_local4 = ("<Variables>" + _local4) + "</Variables>";
} else {
_local4 = "<Variables />";
}
var _local9 = (((_local7 + "<Message>") + message) + "</Message>") + _local4;
send(_local10, _local9);
}
function connectionResponse(success) {
ConnectedToServer = true;
if (!ConnectedToServer) {
connectionEstablished(false, "Could not establish a server connection");
}
}
function connectionEstablished(success, reason) {
if (success && (ConnectedToServer)) {
isConnected = true;
onConnection(true);
} else {
onConnection(false, reason);
}
}
function XMLReceived(info) {
var _local3 = info.toString().substr(0, 1) == "<";
if (_local3) {
parseXML(info);
} else {
rawMessageReceived(info.toString());
}
}
function parseXML(data) {
if (getDebug()) {
}
var _local2 = data.firstChild.childNodes;
var _local5 = _local2[0].firstChild.nodeValue;
var _local4 = _local2[1].childNodes;
var _local3 = new Object();
parseParameters(_local4, _local3);
applyAction(_local5, _local3);
}
function isArrayNodeName(nodeName) {
if (nodeNameList[nodeName]) {
return(true);
}
return(false);
}
function terminateHere(xmls) {
return((xmls.childNodes[0].hasChildNodes() ? false : true));
}
function send(action, parameters) {
var _local3 = ((("<XmlDoc><Action>" + action) + "</Action><Parameters>") + parameters) + "</Parameters></XmlDoc>";
if (getDebug()) {
}
super.send(_local3);
}
function sendRaw(str) {
super.send(str);
}
function parseParameters(info, parentOb) {
var _local5 = 0;
while (_local5 < info.length) {
var _local2 = info[_local5];
var _local8 = terminateHere(_local2);
var _local11 = _local2.nodeName;
if (parentOb instanceof Array) {
var _local6 = new Object();
parentOb.push(_local6);
_local6 = parentOb[parentOb.length - 1];
} else {
parentOb[_local11] = new Object();
var _local6 = parentOb[_local11];
}
for (var _local12 in _local2.attributes) {
if (_local6.attributes == undefined) {
_local6.attributes = new Object();
}
var _local3 = _local2.attributes[_local12];
if (!isNaN(Number(_local3))) {
_local3 = Number(_local3);
}
if (_local3.toLowerCase() == "true") {
_local3 = true;
} else if (_local3.toLowerCase() == "false") {
_local3 = false;
}
_local6.attributes[_local12] = _local3;
}
if (isArrayNodeName(_local11)) {
_local6[_local11] = new Array();
var _local6 = _local6[_local11];
}
if (_local8) {
var _local9 = _local2.firstChild.nodeValue;
if (((!isNaN(Number(_local9))) && (_local9 != undefined)) && (_local2.nodeName != "Message")) {
_local9 = Number(_local9);
}
_local6.value = _local9;
} else {
_local11 = _local2.nodeName;
var _local7 = _local2.childNodes;
parseParameters(_local7, _local6);
}
_local5++;
}
}
function login(tempUsername, tempPassword, variables) {
username = tempUsername;
if ((username == undefined) || (username == null)) {
username = "";
}
if (tempPassword == undefined) {
password = "";
} else {
password = tempPassword;
}
var _local5 = "Login";
var _local2 = ((("<Name>" + username) + "</Name><Password>") + password) + "</Password>";
if (variables != undefined) {
_local2 = _local2 + "<EventHandlerVariables>";
for (var _local4 in variables) {
_local2 = _local2 + "<EventHandlerVariable>";
_local2 = _local2 + (("<Name>" + _local4) + "</Name>");
_local2 = _local2 + (("<Data>" + variables[_local4]) + "</Data>");
_local2 = _local2 + "</EventHandlerVariable>";
}
_local2 = _local2 + "</EventHandlerVariables>";
}
send(_local5, _local2);
}
function connect() {
onConnect = connectionResponse;
onXML = XMLReceived;
super.connect(getIP(), getPort());
}
function getUser() {
return(myUser);
}
function applyAction(action, params) {
if (action == "ConnectionResponse") {
var _local39 = Number(params.Version.attributes.Major);
var _local38 = Number(params.Version.attributes.Minor);
var _local36 = Number(params.Version.attributes.Sub);
if ((params.Result.value == "Accepted") && (ValidateVersion(_local39, _local38, _local36))) {
connectionEstablished(true);
} else {
if ((params.Result.value == "Accepted") && (!ValidateVersion(_local39, _local38, _local36))) {
var _local57 = "ElectroServer 3 version is too old. Please install latest.";
} else {
var _local57 = params.Reason.value;
}
connectionEstablished(false, _local57);
}
} else if (action == "LoginResponse") {
if (params.Result.value.toLowerCase() == "accepted") {
var _local14 = params.Variables.Variables;
var _local27 = new Object();
if (params.Username.value != undefined) {
username = params.Username.value;
}
var _local6 = 0;
while (_local6 < _local14.length) {
var _local45 = _local14[_local6];
var _local17 = _local45.Name.value;
var _local46 = _local45.Data.value;
_local27[_local17] = _local46;
_local6++;
}
loggedIn(true, undefined, _local27);
} else {
var _local57 = params.Reason.value;
loggedIn(false, _local57);
}
} else if (action == "GetAllZones") {
var _local23 = params.Zones.Zones;
var _local28 = new Array();
var _local26 = 0;
while (_local26 < _local23.length) {
var _local45 = _local23[_local26];
_local28.push(_local45.value);
_local26++;
}
allZonesLoaded(_local28);
} else if (action == "GetUserLocation") {
var _local17 = params.User.value;
var _local44 = params.Zone.value;
var _local5 = params.Room.value;
if (params.Status.value == "Success") {
userLocationLoaded(_local17, _local44, _local5, true);
} else {
userLocationLoaded(_local17, _local44, _local5, false);
}
} else if (action == "GetUsersInRoom") {
var _local23 = params.Users.Users;
var _local29 = new Array();
var _local26 = 0;
while (_local26 < _local23.length) {
var _local45 = new Object();
_local45.username = _local23[_local26].value;
_local29.push(_local45);
_local26++;
}
usersInRoomLoaded(_local29, params.Room.value, params.Zone.value);
} else if (action == "FriendLoggedOut") {
var _local17 = params.FriendName.value;
var _local26 = 0;
while (_local26 < buddyList.length) {
var _local45 = buddyList[_local26];
if (_local45.username == _local17) {
_local45.online = false;
_local45.status = "offline";
_local45.label = (_local45.username + " ") + _local45.status;
break;
}
_local26++;
}
buddyLoggedOut(_local17);
} else if (action == "FriendLoggedIn") {
var _local17 = params.FriendName.value;
var _local26 = 0;
while (_local26 < buddyList.length) {
var _local45 = buddyList[_local26];
if (_local45.username == _local17) {
_local45.online = true;
_local45.status = "online";
_local45.label = (_local45.username + " ") + _local45.status;
break;
}
_local26++;
}
buddyLoggedIn(_local17);
} else if (action == "CreateRoom") {
if (params.Result.value == "Failure") {
var _local57 = params.Reason.value;
if ((_local57.indexOf("already exists") > -1) && auto_join) {
joinRoom(pendingRoom, "", pendingZone);
}
}
} else if (action == "LoadConfiguration") {
var _local51 = params.NumberOfPackets.value;
var _local48 = params.PacketNumber.value;
var _local43 = params.PacketData.value;
if (_local48 == "1") {
configXML = _local43;
} else {
configXML = configXML + _local43;
}
if (_local48 == _local51) {
parseConfig(configXML);
}
} else if (action == "UpdateUserVariable") {
var _local16 = zone.users;
var _local45 = params.UserVariable;
var _local35 = _local45.User.value;
var _local46 = _local45.Data.value;
var _local17 = _local45.Name.value;
var _local26 = 0;
while (_local26 < _local16.length) {
var _local20 = _local16[_local26].Name.value;
if (_local35 == _local20) {
var _local42 = _local16[_local26];
var _local22 = typeof(_local42.userVariables[_local17]);
if (_local22.toString() == "undefined") {
if (typeof(_local42.userVariables.toString()) == "undefined") {
_local42.userVariables = new Object();
}
_local42.userVariables[_local17] = _local46;
userVariableUpdated(_local42, "created", _local17);
} else if (_local46.toString() == "null") {
delete _local42.userVariables[_local17];
userVariableUpdated(_local42, "deleted", _local17);
} else {
_local42.userVariables[_local17] = _local46;
userVariableUpdated(_local42, "updated", _local17);
}
break;
}
_local26++;
}
} else if (action == "JoinRoom") {
if (params.Result.value == "Success") {
var _local32 = pendingRoom;
var _local25 = zone.rooms;
var _local30 = false;
var _local26 = 0;
while (_local26 < _local25.length) {
var _local18 = _local25[_local26];
if (_local18.Name.value == _local32) {
_local30 = true;
zone.myRoom = _local18;
var _local15 = params.RoomVariables.RoomVariables;
zone.myRoom.roomVariables = new Object();
var _local6 = 0;
while (_local6 < _local15.length) {
var _local17 = _local15[_local6].Name.value;
var _local46 = _local15[_local6].Data.value;
zone.myRoom.roomVariables[_local17] = _local46;
_local6++;
}
roomVariablesUpdated("all", zone.myRoom.roomVariables);
break;
}
_local26++;
}
if (!_local30) {
zone.myRoom = new Object();
zone.Name = new Object();
zone.Name.value = pendingZone;
zone.myRoom.Name = new Object();
zone.myRoom.Name.value = pendingRoom;
}
var _local15 = params.RoomVariables.RoomVariables;
zone.myRoom.roomVariables = new Object();
var _local6 = 0;
while (_local6 < _local15.length) {
var _local17 = _local15[_local6].Name.value;
var _local46 = _local15[_local6].Data.value;
zone.myRoom.roomVariables[_local17] = _local46;
_local6++;
}
roomVariablesUpdated("all", zone.myRoom.roomVariables);
roomJoined({success:true}, zone.myRoom);
delete pendingRoom;
joiningRoom = false;
zone.users = params.Users.Users;
_local26 = 0;
while (_local26 < zone.users.length) {
var _local42 = zone.users[_local26];
_local42.label = _local42.Name.value;
if (showModeratorLabel && _local42.attributes.Moderator) {
_local42.label = _local42.label + moderatorLabel;
}
_local42.data = _local42;
var _local24 = _local42.UserVariables.UserVariables;
_local42.userVariables = new Object();
var _local8 = 0;
while (_local8 < _local24.length) {
var _local9 = _local24[_local8];
var _local21 = _local9.Name.value;
var _local19 = _local9.Data.value;
_local42.userVariables[_local21] = _local19;
_local8++;
}
if (_local42.Name.value == username) {
myUser = _local42;
if (_local42.AssignedNumber.value == 0) {
_local42.isGameMaster = true;
}
}
_local26++;
}
userListUpdated(zone.users, "all");
} else {
var _local57 = params.Reason.value;
roomJoined({success:false, error:_local57});
}
} else if (action == "RenumberUsers") {
var _local16 = zone.users;
var _local26 = 0;
while (_local26 < params.Users.Users.length) {
var _local33 = params.Users.Users[_local26].Name.value;
var _local6 = 0;
while (_local6 < _local16.length) {
if (_local33 == _local16[_local6].Name.value) {
_local16[_local6].AssignedNumber.value = params.Users.Users[_local26].AssignedNumber.value;
_local16[_local6].isGameMaster = false;
}
_local6++;
}
if (getUser().AssignedNumber.value == 0) {
getUser().isGameMaster = true;
}
_local26++;
}
if (getUser().AssignedNumber.value == 0) {
isGameMaster = true;
} else {
isGameMaster = false;
}
usersRenumbered(_local16);
} else if (action == "SendPrivateMessage") {
var _local40 = params.Message.value;
var _local41 = params.User.value;
var _local14 = new Object();
var _local26 = 0;
while (_local26 < params.Variables.Variables.length) {
var _local17 = params.Variables.Variables[_local26].Name.value;
var _local46 = params.Variables.Variables[_local26].Data.value;
_local14[_local17] = _local46;
_local26++;
}
if (_local14.Action.toLowerCase() == "move") {
var _local52 = _local40;
var _local53 = new Wddx();
var _local45 = _local53.deserialize(_local52);
moveReceived("private", _local45, _local41);
} else {
messageReceived("private", _local40, _local41, _local14);
}
} else if (action == "SendPublicMessage") {
var _local40 = params.Message.value;
var _local41 = params.User.value;
var _local14 = new Object();
var _local26 = 0;
while (_local26 < params.Variables.Variables.length) {
var _local17 = params.Variables.Variables[_local26].Name.value;
var _local46 = params.Variables.Variables[_local26].Data.value;
_local14[_local17] = _local46;
_local26++;
}
if (_local14.Action.toLowerCase() == "move") {
var _local52 = _local40;
var _local53 = new Wddx();
var _local45 = _local53.deserialize(_local52);
moveReceived("public", _local45, _local41);
} else {
messageReceived("public", _local40, _local41, _local14);
}
} else if (action == "GetRoomsInZone") {
var _local4 = params.Zone.Rooms.Rooms;
var _local34 = true;
var _local55 = new Array();
var _local26 = 0;
while (_local26 < _local4.length) {
var _local11 = _local4[_local26].Name.value;
var _local7 = "";
if (_local34) {
_local7 = ((_local11 + " (") + _local4[_local26].attributes.Users) + ")";
} else {
_local7 = _local11;
}
_local4[_local26].label = _local7;
_local4[_local26].iconAlignment = "right";
var _local47 = _local4[_local26].Description.value;
if (_local47.length > 2) {
var _local53 = new Wddx();
var _local45 = _local53.deserialize(_local47);
} else {
var _local45 = new Object();
}
_local4[_local26].Description = _local45;
_local26++;
}
onRoomsInZoneLoaded(_local4, params.Zone.Name.value);
} else if (action == "RoomList") {
var _local13 = getRoom();
var _local31 = getUserList();
zone = new Object();
zone.numUsers = Number(params.Zone.attributes.Users);
zone.name = params.Zone.Name.value;
zone.rooms = params.Zone.Rooms.Rooms;
var _local26 = 0;
while (_local26 < zone.rooms.length) {
var _local47 = zone.rooms[_local26].Description.value;
if (_local47.length > 2) {
var _local53 = new Wddx();
var _local45 = _local53.deserialize(_local47);
} else {
var _local45 = new Object();
}
zone.rooms[_local26].Description = _local45;
var _local5 = zone.rooms[_local26];
_local5.label = _local5.Name.value;
_local5.data = _local5;
if (_local13.Name.value == _local5.Name.value) {
zone.rooms[_local26] = _local13;
zone.myRoom = _local13;
zone.users = _local31;
}
_local26++;
}
zoneChanged(zone.name);
roomListUpdated(zone.rooms, "all");
} else if (action == "UpdateUserList") {
var _local37 = params.MinorAction.value;
if (_local37 == "UserJoined") {
var _local16 = zone.users;
var _local42 = params.User;
var _local56 = _local42.Name.value;
var _local24 = _local42.UserVariables.UserVariables;
_local42.userVariables = new Object();
var _local8 = 0;
while (_local8 < _local24.length) {
var _local9 = _local24[_local8];
var _local21 = _local9.Name.value;
var _local19 = _local9.Data.value;
_local42.userVariables[_local21] = _local19;
_local8++;
}
_local42.label = _local42.Name.value;
if (showModeratorLabel && _local42.attributes.Moderator) {
_local42.label = _local42.label + moderatorLabel;
}
_local42.data = _local42;
_local16.push(_local42);
userListUpdated(zone.users, "userjoined", _local42.Name.value, _local42);
} else if (_local37 == "UserLeft") {
var _local16 = zone.users;
var _local42 = params.User;
var _local33 = _local42.Name.value;
var _local26 = 0;
while (_local26 < _local16.length) {
var _local17 = _local16[_local26].Name.value;
if (_local33 == _local17) {
_local16.splice(_local26, 1);
break;
}
_local26++;
}
userListUpdated(zone.users, "userleft", _local42.Name.value);
}
} else if (action == "SendPluginMessage") {
var _local49 = params.User.value;
var _local50 = params.Message.value;
var _local14 = params.Variables.Variables;
var _local45 = new Object();
var _local26 = 0;
while (_local26 < _local14.length) {
var _local17 = _local14[_local26].Name.value;
var _local46 = _local14[_local26].Value.value;
_local45[_local17] = _local46;
_local26++;
}
pluginMessageReceived(_local49, _local50, _local45);
} else if (action == "UpdateRoomVariable") {
var _local37 = params.MinorAction.value;
if (_local37 == "Create") {
var _local17 = params.RoomVariable.Name.value;
var _local46 = params.RoomVariable.Data.value;
zone.myRoom.roomVariables[_local17] = _local46;
roomVariablesUpdated("created", zone.myRoom.roomVariables, _local17);
} else if (_local37 == "Update") {
var _local17 = params.RoomVariable.Name.value;
var _local46 = params.RoomVariable.Data.value;
zone.myRoom.roomVariables[_local17] = _local46;
roomVariablesUpdated("updated", zone.myRoom.roomVariables, _local17);
} else if (_local37 == "Delete") {
var _local17 = params.RoomVariable.Name.value;
delete zone.myRoom.roomVariables[_local17];
roomVariablesUpdated("deleted", zone.myRoom.roomVariables, _local17);
}
} else if (action == "GetLoggedInUserCount") {
var _local48 = Number(params.LoggedInUsers.value);
loggedInUserCountUpdated(_local48);
} else if (action == "GetServerTime") {
var _local48 = Number(params.ServerTime.value);
onGetServerTime(_local48);
} else if (action == "UpdateRoomList") {
var _local37 = params.MinorAction.value;
zone.numUsers = Number(params.Zone.attributes.Users);
zoneUpdated(zone.numUsers);
var _local3 = params.Zone.Rooms.Rooms[0];
if (_local37 == "ChangeRoomDetails") {
var _local6 = 0;
while (_local6 < zone.rooms.length) {
var _local18 = zone.rooms[_local6];
if (_local18.Name.value == _local3.Name.value) {
_local18.label = _local18.Name.value;
_local18.data = _local18;
for (var _local26 in _local3) {
_local18[_local26] = _local3[_local26];
}
var _local47 = _local3.Description.value;
if (_local47.length > 2) {
var _local53 = new Wddx();
var _local45 = _local53.deserialize(_local47);
} else {
var _local45 = new Object();
}
_local18.Description = _local45;
break;
}
_local6++;
}
roomListUpdated(zone.rooms, "roomupdated", _local18);
} else if (_local37 == "CreateRoom") {
var _local18 = _local3;
_local18.label = _local18.Name.value;
_local18.data = _local18;
var _local47 = _local18.Description.value;
var _local53 = new Wddx();
var _local45 = _local53.deserialize(_local47);
_local18.Description = _local45;
zone.rooms.push(_local18);
roomListUpdated(zone.rooms, "roomcreated", _local18);
} else if (_local37 == "DeleteRoom") {
var _local6 = 0;
while (_local6 < zone.rooms.length) {
var _local18 = zone.rooms[_local6];
if (_local18.Name.value == _local3.Name.value) {
var _local10 = true;
var _local17 = _local3.Name.value;
if ((_local17 == getRoom().Name.value) && (!joiningRoom)) {
_local10 = false;
}
if (_local10) {
zone.rooms.splice(_local6, 1);
}
break;
}
_local6++;
}
roomListUpdated(zone.rooms, "RoomDeleted", _local17);
}
}
}
var MajorVersion = 3;
var MinorVersion = 2;
var SubVersion = 0;
var debug = false;
var showModeratorLabel = false;
var nodeNameList = {Users:true, Zones:true, UserVariables:true, RoomVariables:true, Rooms:true, Variables:true, BannedUsers:true, Plugins:true, Moderators:true, Words:true, RootWords:true, Templates:true};
var isConnected = false;
}
Symbol 1491 MovieClip [__Packages.Wddx] Frame 0
class Wddx
{
var tzOffset, timezoneString, wddxPacket, packet, useTimeZoneInfo;
function Wddx () {
var _local2 = 0;
while (_local2 < 256) {
if ((((_local2 < 32) && (_local2 != 9)) && (_local2 != 10)) && (_local2 != 13)) {
var _local3 = _local2.toString(16);
if (_local3.length == 1) {
_local3 = "0" + _local3;
}
et[_local2] = ("<char code='" + _local3) + "'/>";
at[_local2] = "";
} else if (_local2 < 128) {
et[_local2] = chr(_local2);
at[_local2] = chr(_local2);
} else {
et[_local2] = ("&#x" + _local2.toString(16)) + ";";
etRev[("&#x" + _local2.toString(16)) + ";"] = chr(_local2);
at[_local2] = ("&#x" + _local2.toString(16)) + ";";
atRev[("&#x" + _local2.toString(16)) + ";"] = chr(_local2);
}
_local2++;
}
et[60] = "<";
et[62] = ">";
et[38] = "&";
etRev["<"] = "<";
etRev[">"] = ">";
etRev["&"] = "&";
at[60] = "<";
at[62] = ">";
at[38] = "&";
at[39] = "'";
at[34] = """;
atRev["<"] = "<";
atRev[">"] = ">";
atRev["&"] = "&";
atRev["'"] = "'";
atRev["""] = "\"";
tzOffset = new Date().getTimezoneOffset();
if (tzOffset >= 0) {
timezoneString = "-";
} else {
timezoneString = "+";
}
timezoneString = timezoneString + ((Math.floor(Math.abs(tzOffset) / 60) + ":") + (Math.abs(tzOffset) % 60));
}
function serialize(rootObj) {
delete wddxPacket;
var _local2 = new XML();
packet = new XML();
packet.appendChild(_local2.createElement("wddxPacket"));
wddxPacket = packet.firstChild;
wddxPacket.attributes.version = "1.0";
wddxPacket.appendChild(_local2.createElement("header"));
wddxPacket.appendChild(_local2.createElement("data"));
if (serializeValue(rootObj, wddxPacket.childNodes[1])) {
return(packet);
}
return(null);
}
function serializeValue(obj, node) {
var _local4 = true;
var _local6 = obj.valueOf();
var _local9 = null;
var _local7 = new XML();
if (obj == null) {
node.appendChild(_local7.createElement("null"));
} else if (typeof(_local6) == "string") {
serializeString(_local6, node);
} else if (typeof(_local6) == "number") {
if (typeof(obj.getTimezoneOffset) == "function") {
if (useTimeZoneInfo) {
_local9 = timezoneString;
}
node.appendChild(_local7.createElement("dateTime"));
node.lastChild.appendChild(_local7.createTextNode(((((((((((obj.getFullYear() + "-") + (obj.getMonth() + 1)) + "-") + obj.getDate()) + "T") + obj.getHours()) + ":") + obj.getMinutes()) + ":") + obj.getSeconds()) + _local9));
} else {
node.appendChild(new XML().createElement("number"));
node.lastChild.appendChild(new XML().createTextNode(_local6));
}
} else if (typeof(_local6) == "boolean") {
node.appendChild(_local7.createElement("boolean"));
node.lastChild.attributes.value = _local6;
} else if (typeof(obj) == "object") {
if (typeof(obj.wddxSerialize) == "function") {
_local4 = obj.wddxSerialize(this, node);
} else if ((typeof(obj.join) == "function") && (typeof(obj.reverse) == "function")) {
node.appendChild(_local7.createElement("array"));
node.lastChild.attributes.length = obj.length;
var _local3 = 0;
while (_local4 && (_local3 < obj.length)) {
_local4 = serializeValue(obj[_local3], node.lastChild);
_local3++;
}
} else {
node.appendChild(_local7.createElement("struct"));
if (typeof(obj.wddxSerializationType) == "string") {
node.lastChild.attributes.type = obj.wddxSerializationType;
}
for (var _local8 in obj) {
if (_local8 != "wddxSerializationType") {
_local4 = serializeVariable(_local8, obj[_local8], node.lastChild);
if (!_local4) {
break;
}
}
}
}
} else {
_local4 = false;
}
return(_local4);
}
function serializeVariable(name, obj, node) {
var _local2 = true;
var _local3 = new XML();
if (typeof(obj) != "function") {
node.appendChild(_local3.createElement("var"));
node.lastChild.attributes.name = (preserveVarCase ? (serializeAttr(name)) : (serializeAttr(name.toLowerCase())));
_local2 = serializeValue(obj, node.lastChild);
}
return(_local2);
}
function serializeString(s, node) {
var _local5 = "";
var _local7 = new XML();
var _local6 = s.length;
node.appendChild(_local7.createElement("string"));
var _local2 = 0;
while (_local2 < _local6) {
var _local4 = substring(s, _local2 + 1, 1);
_local5 = _local5 + et[ord(substring(s, _local2 + 1, 1))];
_local2++;
}
node.lastChild.appendChild(_local7.createTextNode(_local5));
}
function serializeAttr(s) {
var _local3 = "";
var _local4 = s.length;
var _local2 = 0;
while (_local2 < _local4) {
_local3 = _local3 + at[ord(substring(s, _local2 + 1, 1))];
_local2++;
}
return(_local3);
}
function deserialize(wddxPacket) {
if (typeof(wddxPacket) != "object") {
wddxPacket = new XML(wddxPacket);
}
var _local5 = new XML();
var _local4 = new Array();
var _local2;
var _local6 = new Object();
while (wddxPacket.nodeName == null) {
wddxPacket = wddxPacket.firstChild;
}
_local5 = wddxPacket;
if (_local5.nodeName.toLowerCase() == "wddxpacket") {
_local4 = _local5.childNodes;
_local2 = 0;
while ((_local4[_local2].nodeName.toLowerCase() != "data") && (_local2 < _local4.length)) {
_local2++;
}
if (_local2 < _local4.length) {
_local6 = deserializeNode(_local4[_local2].firstChild);
return(_local6);
}
return(null);
}
return(null);
}
function deserializeNode(node) {
var _local9 = node.nodeName.toLowerCase();
if (_local9 == "number") {
var _local7 = node.firstChild.nodeValue;
return(Number(_local7));
}
if (_local9 == "boolean") {
var _local7 = String(node.attributes.value).toLowerCase() == "true";
return(_local7);
}
if (_local9 == "string") {
if (node.childNodes.length > 1) {
var _local7 = "";
var _local4 = 0;
_local4 = 0;
while (_local4 < node.childNodes.length) {
if (node.childNodes[_local4].nodeType == 3) {
_local7 = _local7 + deserializeString(node.childNodes[_local4].nodeValue);
} else if (node.childNodes[_local4].nodeName == "char") {
_local7 = _local7 + chr(parseInt(node.childNodes[_local4].attributes.code, 16));
}
_local4++;
}
} else {
var _local7 = deserializeString(node.firstChild.nodeValue);
}
return(_local7);
}
if (_local9 == "array") {
var _local7 = new Array();
var _local15 = 0;
var _local4 = 0;
while (_local4 < node.attributes.length) {
_local7[_local4] = deserializeNode(node.childNodes[_local4].cloneNode(true));
_local4++;
}
return(_local7);
}
if (_local9 == "datetime") {
var _local10 = node.firstChild.nodeValue;
var _local13 = _local10.indexOf("T");
var _local8 = _local10.indexOf("+");
var _local11 = new Array();
var _local12 = new Array();
var _local14 = new Array();
var _local7 = new Date();
if (_local8 == -1) {
_local8 = _local10.lastIndexOf("-");
if (_local8 < _local13) {
_local8 = -1;
}
}
_local11 = _local10.slice(0, _local13).split("-");
_local12 = _local10.slice(_local13 + 1, _local8).split(":");
_local14 = _local10.slice(_local8).split(":");
_local7.setFullYear(parseInt(_local11[0]), parseInt(_local11[1]) - 1, parseInt(_local11[2]));
_local7.setHours(parseInt(_local12[0]), parseInt(_local12[1]));
if (_local8 != -1) {
tzOffset = (parseInt(_local14[0]) * 60) + parseInt(_local14[1]);
_local7.setMinutes(_local7.getMinutes() - (_local7.getTimezoneOffset() + tzOffset));
}
return(_local7);
}
if (_local9 == "struct") {
var _local7 = new Object();
var _local4 = 0;
while (_local4 < node.childNodes.length) {
if (node.childNodes[_local4].nodeName.toLowerCase() == "var") {
_local7[deserializeAttr(node.childNodes[_local4].attributes.name)] = deserializeNode(node.childNodes[_local4].firstChild);
}
_local4++;
}
return(_local7);
}
if (_local9 == "recordset") {
var _local7 = new WddxRecordset(node.attributes.fieldNames.split(",").reverse(), parseInt(node.attributes.rowCount));
var _local4 = node.childNodes.length - 1;
while (_local4 >= 0) {
if (node.childNodes[_local4].nodeName.toLowerCase() == "field") {
var _local5 = deserializeAttr(node.childNodes[_local4].attributes.name);
_local7[_local5].wddxSerializationType = "field";
var _local3 = node.childNodes[_local4].childNodes.length - 1;
while (_local3 >= 0) {
_local7[_local5][_local3] = new Object();
var _local6 = deserializeNode(node.childNodes[_local4].childNodes[_local3]);
_local7.setField(_local3, _local5, _local6);
_local3--;
}
}
_local4--;
}
return(_local7);
}
}
function deserializeAttr(attr) {
var _local7 = attr.length;
var _local3 = 0;
var _local2;
var _local6 = "";
while (_local3 < _local7) {
_local2 = substring(attr, _local3 + 1, 1);
if (_local2 == "&") {
var _local4 = _local2;
do {
_local2 = substring(attr, _local3 + 1, 1);
_local4 = _local4 + _local2;
_local3++;
} while (_local2 != ";");
_local6 = _local6 + atRev[_local4];
} else {
_local6 = _local6 + _local2;
}
_local3++;
}
return(_local6);
}
function deserializeString(str) {
var _local7 = str.length;
var _local3 = 0;
var _local2;
var _local6 = "";
while (_local3 < _local7) {
_local2 = substring(str, _local3 + 1, 1);
if (_local2 == "&") {
var _local4 = _local2;
do {
_local3++;
_local2 = substring(str, _local3 + 1, 1);
_local4 = _local4 + _local2;
} while (_local2 != ";");
_local6 = _local6 + etRev[_local4];
} else {
_local6 = _local6 + _local2;
}
_local3++;
}
return(_local6);
}
var et = new Object();
var etRev = new Object();
var at = new Object();
var atRev = new Object();
var preserveVarCase = true;
var useTimezoneInfo = true;
}
Symbol 1492 MovieClip [__Packages.WddxRecordset] Frame 0
class WddxRecordset
{
function WddxRecordset (arguments) {
if (arguments.length > 0) {
var _local8;
_local8 = arguments[0].valueOf();
if (typeof(_local8) == "boolean") {
preserveFieldCase = arguments[0];
} else {
var _local7 = arguments[0];
var _local6 = 0;
if (arguments.length > 1) {
_local8 = arguments[1].valueOf();
if (typeof(_local8) == "boolean") {
preserveFieldCase = arguments[1];
} else {
_local6 = arguments[1];
if (arguments.length > 2) {
preserveFieldCase = arguments[2];
}
}
}
var _local4 = 0;
while (_local4 < _local7.length) {
var _local5 = new Array(_local6);
var _local3 = 0;
while (_local3 < _local6) {
_local5[_local3] = null;
_local3++;
}
this[(preserveFieldCase ? (_local7[_local4]) : (_local7[_local4].toLowerCase()))] = _local5;
_local4++;
}
}
}
}
function duplicate() {
var _local2 = new WddxRecordset();
for (var _local4 in this) {
if (_local4.toUpperCase() == "PRESERVEFIELDCASE") {
_local2[_local4] = this[_local4];
} else if (this[_local4].isColumn()) {
_local2.addColumn(_local4);
for (var _local3 in this[_local4]) {
_local2.setField(_local3, _local4, getField(_local3, _local4));
}
}
}
return(_local2);
}
function isColumn(name) {
return((typeof(this[name]) == "object") && (name.indexOf("_private_") == -1));
}
function getRowCount() {
var _local2 = 0;
for (var _local3 in this) {
if (isColumn(_local3)) {
_local2 = this[_local3].length;
break;
}
}
return(_local2);
}
function addColumn(name) {
var _local4 = getRowCount();
var _local3 = new Array(_local4);
var _local2 = 0;
while (_local2 < _local4) {
_local3[_local2] = null;
_local2++;
}
this[(preserveFieldCase ? (name) : (name.toLowerCase()))] = _local3;
}
function addRows(n) {
for (var _local5 in this) {
if (isColumn(_local5)) {
var _local3 = this[_local5].length;
var _local2 = _local3;
while (_local2 < (_local3 + n)) {
this[_local5][_local2] = "";
_local2++;
}
}
}
}
function getField(row, col) {
return(this[(preserveFieldCase ? (col) : (col.toLowerCase()))][row]);
}
function setField(row, col, value) {
this[(preserveFieldCase ? (col) : (col.toLowerCase()))][row] = value;
}
function wddxSerialize(serializer, node) {
var _local7 = "";
var _local8 = new Array();
var _local4 = 0;
for (var _local11 in this) {
if (isColumn(_local11)) {
_local8[_local4++] = _local11;
if (_local7.length > 0) {
_local7 = _local7 + ",";
}
_local7 = _local7 + _local11;
}
}
var _local9 = getRowCount();
node.appendChild(new XML().createElement("recordset"));
node.lastChild.attributes.rowCount = _local9;
node.lastChild.attributes.fieldNames = _local7;
var _local3 = true;
_local4 = 0;
while (_local3 && (_local4 < _local8.length)) {
var _local5 = _local8[_local4];
node.lastChild.appendChild(new XML().createElement("field"));
node.lastChild.lastChild.attributes.name = _local5;
var _local2 = 0;
while (_local3 && (_local2 < _local9)) {
_local3 = serializer.serializeValue(this[_local5][_local2], node.lastChild.lastChild);
_local2++;
}
_local4++;
}
return(_local3);
}
var preserveFieldCase = true;
}
Symbol 38 MovieClip Frame 89
i = 0;
while (i < 50) {
_root["unit" + i].removeMovieClip();
i++;
}
Symbol 38 MovieClip Frame 110
_root.gotoAndPlay("victory");
stop();
Symbol 39 MovieClip [stratofighter] Frame 1
#initclip 45
Object.registerClass("stratofighter", Unit);
#endinitclip
Symbol 39 MovieClip [stratofighter] Frame 4
stop();
Symbol 39 MovieClip [stratofighter] Frame 9
stop();
Symbol 39 MovieClip [stratofighter] Frame 14
stop();
Symbol 39 MovieClip [stratofighter] Frame 19
stop();
Symbol 55 MovieClip [red_transport] Frame 1
#initclip 13
Object.registerClass("red_transport", Unit);
#endinitclip
Symbol 55 MovieClip [red_transport] Frame 4
stop();
Symbol 55 MovieClip [red_transport] Frame 9
stop();
Symbol 55 MovieClip [red_transport] Frame 14
stop();
Symbol 55 MovieClip [red_transport] Frame 19
stop();
Symbol 62 MovieClip [red_tank] Frame 1
#initclip 14
Object.registerClass("red_tank", Unit);
#endinitclip
Symbol 62 MovieClip [red_tank] Frame 5
stop();
Symbol 62 MovieClip [red_tank] Frame 10
stop();
Symbol 62 MovieClip [red_tank] Frame 15
stop();
Symbol 62 MovieClip [red_tank] Frame 20
stop();
Symbol 69 MovieClip [red_scout] Frame 1
#initclip 15
Object.registerClass("red_scout", Unit);
#endinitclip
Symbol 69 MovieClip [red_scout] Frame 5
stop();
Symbol 69 MovieClip [red_scout] Frame 10
stop();
Symbol 69 MovieClip [red_scout] Frame 15
stop();
Symbol 69 MovieClip [red_scout] Frame 20
stop();
Symbol 83 MovieClip [red_rocketinf] Frame 1
#initclip 16
Object.registerClass("red_rocketinf", Unit);
#endinitclip
Symbol 83 MovieClip [red_rocketinf] Frame 4
stop();
Symbol 83 MovieClip [red_rocketinf] Frame 9
stop();
Symbol 83 MovieClip [red_rocketinf] Frame 14
stop();
Symbol 83 MovieClip [red_rocketinf] Frame 19
stop();
Symbol 90 MovieClip [red_rocket] Frame 1
#initclip 17
Object.registerClass("red_rocket", Unit);
#endinitclip
Symbol 90 MovieClip [red_rocket] Frame 4
stop();
Symbol 90 MovieClip [red_rocket] Frame 9
stop();
Symbol 90 MovieClip [red_rocket] Frame 14
stop();
Symbol 90 MovieClip [red_rocket] Frame 19
stop();
Symbol 97 MovieClip [red_lander] Frame 1
#initclip 18
Object.registerClass("red_lander", Unit);
#endinitclip
Symbol 97 MovieClip [red_lander] Frame 4
stop();
Symbol 97 MovieClip [red_lander] Frame 9
stop();
Symbol 97 MovieClip [red_lander] Frame 14
stop();
Symbol 97 MovieClip [red_lander] Frame 19
stop();
Symbol 103 MovieClip [red_infantry] Frame 1
#initclip 19
Object.registerClass("red_infantry", Unit);
#endinitclip
Symbol 103 MovieClip [red_infantry] Frame 4
stop();
Symbol 103 MovieClip [red_infantry] Frame 9
stop();
Symbol 103 MovieClip [red_infantry] Frame 14
stop();
Symbol 103 MovieClip [red_infantry] Frame 19
stop();
Symbol 110 MovieClip [red_helicopter] Frame 1
#initclip 20
Object.registerClass("red_helicopter", Unit);
#endinitclip
Symbol 110 MovieClip [red_helicopter] Frame 4
stop();
Symbol 110 MovieClip [red_helicopter] Frame 9
stop();
Symbol 110 MovieClip [red_helicopter] Frame 14
stop();
Symbol 110 MovieClip [red_helicopter] Frame 19
stop();
Symbol 124 MovieClip [red_fighter] Frame 1
#initclip 21
Object.registerClass("red_fighter", Unit);
#endinitclip
Symbol 124 MovieClip [red_fighter] Frame 4
stop();
Symbol 124 MovieClip [red_fighter] Frame 9
stop();
Symbol 124 MovieClip [red_fighter] Frame 14
stop();
Symbol 124 MovieClip [red_fighter] Frame 19
stop();
Symbol 131 MovieClip [red_destroyer] Frame 1
#initclip 22
Object.registerClass("red_destroyer", Unit);
#endinitclip
Symbol 131 MovieClip [red_destroyer] Frame 4
stop();
Symbol 131 MovieClip [red_destroyer] Frame 9
stop();
Symbol 131 MovieClip [red_destroyer] Frame 14
stop();
Symbol 131 MovieClip [red_destroyer] Frame 19
stop();
Symbol 138 MovieClip [red_carrier] Frame 1
#initclip 23
Object.registerClass("red_carrier", Unit);
#endinitclip
Symbol 138 MovieClip [red_carrier] Frame 4
stop();
Symbol 138 MovieClip [red_carrier] Frame 9
stop();
Symbol 138 MovieClip [red_carrier] Frame 14
stop();
Symbol 138 MovieClip [red_carrier] Frame 19
stop();
Symbol 145 MovieClip [red_bomber] Frame 1
#initclip 24
Object.registerClass("red_bomber", Unit);
#endinitclip
Symbol 145 MovieClip [red_bomber] Frame 4
stop();
Symbol 145 MovieClip [red_bomber] Frame 9
stop();
Symbol 145 MovieClip [red_bomber] Frame 14
stop();
Symbol 145 MovieClip [red_bomber] Frame 19
stop();
Symbol 152 MovieClip [red_art] Frame 1
#initclip 25
Object.registerClass("red_art", Unit);
#endinitclip
stop();
Symbol 152 MovieClip [red_art] Frame 9
stop();
Symbol 152 MovieClip [red_art] Frame 10
stop();
Symbol 152 MovieClip [red_art] Frame 19
stop();
Symbol 152 MovieClip [red_art] Frame 29
stop();
Symbol 152 MovieClip [red_art] Frame 39
stop();
Symbol 159 MovieClip [red_apc] Frame 1
#initclip 26
Object.registerClass("red_apc", Unit);
#endinitclip
Symbol 159 MovieClip [red_apc] Frame 4
stop();
Symbol 159 MovieClip [red_apc] Frame 9
stop();
Symbol 159 MovieClip [red_apc] Frame 14
stop();
Symbol 159 MovieClip [red_apc] Frame 19
stop();
Symbol 166 MovieClip [red_aa] Frame 1
#initclip 27
Object.registerClass("red_aa", Unit);
#endinitclip
Symbol 166 MovieClip [red_aa] Frame 4
stop();
Symbol 166 MovieClip [red_aa] Frame 9
stop();
Symbol 166 MovieClip [red_aa] Frame 14
stop();
Symbol 166 MovieClip [red_aa] Frame 19
stop();
Symbol 172 MovieClip Frame 5
stop();
Symbol 172 MovieClip Frame 10
stop();
Symbol 172 MovieClip Frame 15
stop();
Symbol 173 MovieClip Frame 1
if ((_parent.moves_left > 0) && (this.indicator._currentframe != 5)) {
this.indicator.gotoAndPlay("full");
} else if ((_parent.attacked == true) && (this.indicator._currentframe != 15)) {
this.indicator.gotoAndPlay("attacked");
} else if ((this.indicator._currentframe != 10) && (_parent.moves_left == 0)) {
this.indicator.gotoAndPlay("moved");
}
Symbol 178 MovieClip [blue_truck] Frame 1
#initclip 28
Object.registerClass("blue_truck", Unit);
#endinitclip
Symbol 178 MovieClip [blue_truck] Frame 4
stop();
Symbol 178 MovieClip [blue_truck] Frame 9
stop();
Symbol 178 MovieClip [blue_truck] Frame 14
stop();
Symbol 178 MovieClip [blue_truck] Frame 19
stop();
Symbol 191 MovieClip [blue_transport] Frame 1
#initclip 29
Object.registerClass("blue_transport", Unit);
#endinitclip
Symbol 191 MovieClip [blue_transport] Frame 4
stop();
Symbol 191 MovieClip [blue_transport] Frame 9
stop();
Symbol 191 MovieClip [blue_transport] Frame 14
stop();
Symbol 191 MovieClip [blue_transport] Frame 19
stop();
Symbol 200 MovieClip [blue_tank] Frame 1
#initclip 30
Object.registerClass("blue_tank", Unit);
#endinitclip
stop();
Symbol 200 MovieClip [blue_tank] Frame 9
stop();
Symbol 200 MovieClip [blue_tank] Frame 10
stop();
Symbol 200 MovieClip [blue_tank] Frame 19
stop();
Symbol 200 MovieClip [blue_tank] Frame 29
stop();
Symbol 200 MovieClip [blue_tank] Frame 39
stop();
Symbol 207 MovieClip [blue_scout] Frame 1
#initclip 31
Object.registerClass("blue_scout", Unit);
#endinitclip
Symbol 207 MovieClip [blue_scout] Frame 5
stop();
Symbol 207 MovieClip [blue_scout] Frame 10
stop();
Symbol 207 MovieClip [blue_scout] Frame 15
stop();
Symbol 207 MovieClip [blue_scout] Frame 20
stop();
Symbol 214 MovieClip [blue_rocketinf] Frame 1
#initclip 32
Object.registerClass("blue_rocketinf", Unit);
#endinitclip
Symbol 214 MovieClip [blue_rocketinf] Frame 4
stop();
Symbol 214 MovieClip [blue_rocketinf] Frame 9
stop();
Symbol 214 MovieClip [blue_rocketinf] Frame 14
stop();
Symbol 214 MovieClip [blue_rocketinf] Frame 19
stop();
Symbol 221 MovieClip [blue_rocket] Frame 1
#initclip 33
Object.registerClass("blue_rocket", Unit);
#endinitclip
Symbol 221 MovieClip [blue_rocket] Frame 4
stop();
Symbol 221 MovieClip [blue_rocket] Frame 9
stop();
Symbol 221 MovieClip [blue_rocket] Frame 14
stop();
Symbol 221 MovieClip [blue_rocket] Frame 19
stop();
Symbol 228 MovieClip [blue_lander] Frame 1
#initclip 34
Object.registerClass("blue_lander", Unit);
#endinitclip
Symbol 228 MovieClip [blue_lander] Frame 4
stop();
Symbol 228 MovieClip [blue_lander] Frame 9
stop();
Symbol 228 MovieClip [blue_lander] Frame 14
stop();
Symbol 228 MovieClip [blue_lander] Frame 19
stop();
Symbol 235 MovieClip [blue_infantry] Frame 1
#initclip 35
Object.registerClass("blue_infantry", Unit);
#endinitclip
Symbol 235 MovieClip [blue_infantry] Frame 4
stop();
Symbol 235 MovieClip [blue_infantry] Frame 9
stop();
Symbol 235 MovieClip [blue_infantry] Frame 14
stop();
Symbol 235 MovieClip [blue_infantry] Frame 19
stop();
Symbol 242 MovieClip [blue_helicopter] Frame 1
#initclip 36
Object.registerClass("blue_helicopter", Unit);
#endinitclip
Symbol 242 MovieClip [blue_helicopter] Frame 4
stop();
Symbol 242 MovieClip [blue_helicopter] Frame 9
stop();
Symbol 242 MovieClip [blue_helicopter] Frame 14
stop();
Symbol 242 MovieClip [blue_helicopter] Frame 19
stop();
Symbol 252 MovieClip [blue_fighter] Frame 1
#initclip 37
Object.registerClass("blue_fighter", Unit);
#endinitclip
Symbol 252 MovieClip [blue_fighter] Frame 4
stop();
Symbol 252 MovieClip [blue_fighter] Frame 9
stop();
Symbol 252 MovieClip [blue_fighter] Frame 14
stop();
Symbol 252 MovieClip [blue_fighter] Frame 19
stop();
Symbol 259 MovieClip [blue_destroyer] Frame 1
#initclip 38
Object.registerClass("blue_destroyer", Unit);
#endinitclip
Symbol 259 MovieClip [blue_destroyer] Frame 4
stop();
Symbol 259 MovieClip [blue_destroyer] Frame 9
stop();
Symbol 259 MovieClip [blue_destroyer] Frame 14
stop();
Symbol 259 MovieClip [blue_destroyer] Frame 19
stop();
Symbol 266 MovieClip [blue_carrier] Frame 1
#initclip 39
Object.registerClass("blue_carrier", Unit);
#endinitclip
Symbol 266 MovieClip [blue_carrier] Frame 4
stop();
Symbol 266 MovieClip [blue_carrier] Frame 9
stop();
Symbol 266 MovieClip [blue_carrier] Frame 14
stop();
Symbol 266 MovieClip [blue_carrier] Frame 19
stop();
Symbol 275 MovieClip [blue_bomber] Frame 1
#initclip 40
Object.registerClass("blue_bomber", Unit);
#endinitclip
Symbol 275 MovieClip [blue_bomber] Frame 4
stop();
Symbol 275 MovieClip [blue_bomber] Frame 9
stop();
Symbol 275 MovieClip [blue_bomber] Frame 14
stop();
Symbol 275 MovieClip [blue_bomber] Frame 19
stop();
Symbol 282 MovieClip [blue_art] Frame 1
#initclip 41
Object.registerClass("blue_art", Unit);
#endinitclip
stop();
Symbol 282 MovieClip [blue_art] Frame 9
stop();
Symbol 282 MovieClip [blue_art] Frame 10
stop();
Symbol 282 MovieClip [blue_art] Frame 19
stop();
Symbol 282 MovieClip [blue_art] Frame 29
stop();
Symbol 282 MovieClip [blue_art] Frame 39
stop();
Symbol 289 MovieClip [blue_apc] Frame 1
#initclip 42
Object.registerClass("blue_apc", Unit);
#endinitclip
Symbol 289 MovieClip [blue_apc] Frame 4
stop();
Symbol 289 MovieClip [blue_apc] Frame 9
stop();
Symbol 289 MovieClip [blue_apc] Frame 14
stop();
Symbol 289 MovieClip [blue_apc] Frame 19
stop();
Symbol 296 MovieClip [blue_aa] Frame 1
#initclip 43
Object.registerClass("blue_aa", Unit);
#endinitclip
Symbol 296 MovieClip [blue_aa] Frame 4
stop();
Symbol 296 MovieClip [blue_aa] Frame 9
stop();
Symbol 296 MovieClip [blue_aa] Frame 14
stop();
Symbol 296 MovieClip [blue_aa] Frame 19
stop();
Symbol 301 MovieClip [albatross] Frame 1
#initclip 44
Object.registerClass("albatross", Unit);
#endinitclip
Symbol 301 MovieClip [albatross] Frame 4
stop();
Symbol 301 MovieClip [albatross] Frame 9
stop();
Symbol 318 MovieClip Frame 1
stop();
Symbol 318 MovieClip Frame 2
play();
Symbol 318 MovieClip Frame 5
stop();
Symbol 324 MovieClip Frame 1
stop();
Symbol 324 MovieClip Frame 9
stop();
Symbol 324 MovieClip Frame 19
gotoAndStop (1);
Symbol 324 MovieClip Frame 29
stop();
Symbol 324 MovieClip Frame 40
stop();
Symbol 328 MovieClip Frame 1
stop();
Symbol 328 MovieClip Frame 2
play();
Symbol 328 MovieClip Frame 5
stop();
Symbol 333 MovieClip Frame 5
stop();
Symbol 337 MovieClip Frame 50
stop();
Symbol 345 MovieClip Frame 61
stop();
Symbol 351 MovieClip Frame 1
stop();
Symbol 351 MovieClip Frame 2
stop();
Symbol 351 MovieClip Frame 3
stop();
Symbol 351 MovieClip Frame 4
stop();
Symbol 351 MovieClip Frame 5
stop();
Symbol 372 MovieClip Frame 1
scoretxt.text = int(_root.score * 0.01);
Symbol 372 MovieClip Frame 6
scoretxt.text = int(_root.score * 0.02);
Symbol 372 MovieClip Frame 10
scoretxt.text = int(_root.score * 0.04);
Symbol 372 MovieClip Frame 13
scoretxt.text = int(_root.score * 0.08);
Symbol 372 MovieClip Frame 15
scoretxt.text = int(_root.score * 0.1);
Symbol 372 MovieClip Frame 17
scoretxt.text = int(_root.score * 0.11);
Symbol 372 MovieClip Frame 19
scoretxt.text = int(_root.score * 0.15);
Symbol 372 MovieClip Frame 21
scoretxt.text = int(_root.score * 0.21);
Symbol 372 MovieClip Frame 23
scoretxt.text = int(_root.score * 0.26);
Symbol 372 MovieClip Frame 25
scoretxt.text = int(_root.score * 0.31);
Symbol 372 MovieClip Frame 27
scoretxt.text = int(_root.score * 0.41);
Symbol 372 MovieClip Frame 29
scoretxt.text = int(_root.score * 0.48);
Symbol 372 MovieClip Frame 31
scoretxt.text = int(_root.score * 0.51);
Symbol 372 MovieClip Frame 33
scoretxt.text = int(_root.score * 0.58);
Symbol 372 MovieClip Frame 35
scoretxt.text = int(_root.score * 0.61);
Symbol 372 MovieClip Frame 37
scoretxt.text = int(_root.score * 0.65);
Symbol 372 MovieClip Frame 39
scoretxt.text = int(_root.score * 0.7);
Symbol 372 MovieClip Frame 40
scoretxt.text = int(_root.score * 0.8);
Symbol 372 MovieClip Frame 41
scoretxt.text = int(_root.score * 0.9);
Symbol 372 MovieClip Frame 42
scoretxt.text = int(_root.score * 0.95);
Symbol 372 MovieClip Frame 43
scoretxt.text = int(_root.score * 0.97);
Symbol 372 MovieClip Frame 44
scoretxt.text = _root.score;
stop();
Symbol 381 MovieClip [int_victory] Frame 1
stopAllSounds();
sound = new Sound(this);
sound.attachSound("won");
sound.setVolume(_root.music_vol);
sound.start(0, 999);
Symbol 381 MovieClip [int_victory] Frame 2
_root.attachMovie("advisor", "myAdvisor", 3600, {seq:"e"});
Symbol 381 MovieClip [int_victory] Frame 39
function Rank() {
if ((_root.myGameData.data.playerrank == undefined) && (_root.myGameData.data.playerscore > 600000)) {
_root.myGameData.data.playerrank = "1st Lieutenant";
this.int_promoted.gotoAndPlay("activated");
}
if ((_root.myGameData.data.playerrank == "2nd Lieutenant") && (_root.myGameData.data.playerscore > 600000)) {
_root.myGameData.data.playerrank = "1st Lieutenant";
this.int_promoted.gotoAndPlay("activated");
}
if ((_root.myGameData.data.playerrank == "1st Lieutenant") && (_root.myGameData.data.playerscore > 1300000)) {
_root.myGameData.data.playerrank = "Captain";
this.int_promoted.gotoAndPlay("activated");
}
if ((_root.myGameData.data.playerrank == "Captain") && (_root.myGameData.data.playerscore > 2000000)) {
_root.myGameData.data.playerrank = "Major";
this.int_promoted.gotoAndPlay("activated");
}
if ((_root.myGameData.data.playerrank == "Major") && (_root.myGameData.data.playerscore > 3000000)) {
_root.myGameData.data.playerrank = "Lieutenant Colonel";
this.int_promoted.gotoAndPlay("activated");
}
if ((_root.myGameData.data.playerrank == "Lieutenant Colonel") && (_root.myGameData.data.playerscore > 4500000)) {
_root.myGameData.data.playerrank = "Colonel";
this.int_promoted.gotoAndPlay("activated");
}
if ((_root.myGameData.data.playerrank == "Colonel") && (_root.myGameData.data.playerscore > 6000000)) {
_root.myGameData.data.playerrank = "Brigadier General";
this.int_promoted.gotoAndPlay("activated");
}
if ((_root.myGameData.data.playerrank == "Brigadier General") && (_root.myGameData.data.playerscore > 8000000)) {
_root.myGameData.data.playerrank = "Major General";
this.int_promoted.gotoAndPlay("activated");
}
}
function Score() {
var _local3 = 500000 /* 0x07A120 */;
var _local2 = 0;
var _local4 = _local3 - int(_root.tstat_player_time / 3);
_local2 = _local4 + int(_root.tstat_com_lost * 1000);
_local2 = _local4 - int(_root.tstat_player_lost * 6500);
_local2 = _local4 + int(_root.tstat_player_cash);
if (_local2 > _local3) {
_local2 = _local3;
}
if (_local2 < 0) {
_local2 = 0;
}
if (_local2 > 250000) {
grade.gotoAndPlay(2);
}
if (_local2 > 320000) {
grade.gotoAndPlay(3);
}
if (_local2 > 380000) {
grade.gotoAndPlay(4);
}
if (_local2 > 450000) {
grade.gotoAndPlay(5);
}
_root.score = _local2;
}
function GiveAwards() {
var _local3 = false;
if (_root.myGameData.data.award1 != true) {
if ((_root.stat_player_captured >= 200) && (_root.myGameData.data.award1 != true)) {
_root.myGameData.data.award1 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award2 != true) {
if ((_root.stat_player_captured >= 50) && (_root.myGameData.data.award2 != true)) {
_root.myGameData.data.award2 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award3 != true) {
if ((_root.stat_player_cash >= 25000) && (_root.myGameData.data.award3 != true)) {
_root.myGameData.data.award3 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award4 != true) {
if ((_root.mission == 0) && (_root.myGameData.data.award4 != true)) {
_root.myGameData.data.award4 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award5 != true) {
if ((_root.stat_player_built >= 20) && (_root.myGameData.data.award5 != true)) {
_root.myGameData.data.award5 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award6 != true) {
time = int(_root.stat_player_time / 1000);
hours = int(time / 3600);
if ((hours >= 2) && (_root.myGameData.data.award6 != true)) {
_root.myGameData.data.award6 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award7 != true) {
if ((_root.stat_player_built >= 100) && (_root.myGameData.data.award7 != true)) {
_root.myGameData.data.award7 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award8 != true) {
if ((_root.stat_player_built >= 200) && (_root.myGameData.data.award8 != true)) {
_root.myGameData.data.award8 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award9 != true) {
if ((_root.stat_player_cash >= 1000000) && (_root.myGameData.data.award9 != true)) {
_root.myGameData.data.award9 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award10 != true) {
time = int(_root.stat_player_time / 1000);
hours = int(time / 3600);
if (((_root.mission == 20) && (hours < 3)) && (_root.myGameData.data.award10 != true)) {
_root.myGameData.data.award10 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award11 != true) {
if ((_root.tstat_player_lost == 0) && (_root.myGameData.data.award11 != true)) {
_root.myGameData.data.award11 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award12 != true) {
if ((_root.tstat_player_lost < 5) && (_root.myGameData.data.award12 != true)) {
_root.myGameData.data.award12 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award13 != true) {
if ((_root.stat_player_captured == 100) && (_root.myGameData.data.award13 != true)) {
_root.myGameData.data.award13 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award14 != true) {
if ((_root.day <= 20) && (_root.myGameData.data.award14 != true)) {
_root.myGameData.data.award14 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award15 != true) {
if ((_root.mission >= 2) && (_root.myGameData.data.award15 != true)) {
_root.myGameData.data.award15 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award16 != true) {
if ((_root.tstat_com_lost >= 30) && (_root.myGameData.data.award16 != true)) {
_root.myGameData.data.award16 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award17 != true) {
if ((_root.mission == 18) && (_root.myGameData.data.award17 != true)) {
_root.myGameData.data.award17 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award18 != true) {
if ((_root.mission == 5) && (_root.myGameData.data.award18 != true)) {
_root.myGameData.data.award18 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award19 != true) {
if ((_root.stat_player_cash >= 2500000) && (_root.myGameData.data.award19 != true)) {
_root.myGameData.data.award19 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award20 != true) {
if (_root.myGameData.data.stat_win > 19) {
_root.myGameData.data.award20 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award21 != true) {
if ((_root.mission == 20) && (_root.myGameData.data.award21 != true)) {
_root.myGameData.data.award21 = true;
_local3 = true;
}
}
if (_root.myGameData.data.award22 != true) {
if ((_root.myGameData.data.stat_lose == 0) && (_root.mission == 18)) {
_root.myGameData.data.award20 = true;
_local3 = true;
}
}
if (_local3 == true) {
this.int_award.gotoAndPlay("activated");
}
}
var PlayTime;
var time;
var seconds;
var minutes;
var hours;
var tsec;
var tmin;
var thour;
var i = 0;
time = int(_root.tstat_player_time / 1000);
hours = int(time / 3600);
time = int(time) - int(hours * 3600);
minutes = int(time / 60);
time = int(time) - int(minutes * 60);
seconds = int(time);
if (seconds < 10) {
tsec = "0" + seconds.toString();
} else {
tsec = seconds.toString();
}
if (minutes < 10) {
tmin = "0" + minutes.toString();
} else {
tmin = minutes.toString();
}
if (hours < 10) {
thour = "0" + hours.toString();
} else {
thour = hours.toString();
}
PlayTime = (((thour + ":") + tmin) + ":") + tsec;
if (_root.setskirmish != true) {
_root.myGameData.data.mission = int(_root.mission + 1);
}
_root.myGameData.data.sfx_vol = _root.sfx_vol;
_root.myGameData.data.music_vol = _root.music_vol;
_root.myGameData.data.stat_player_lost = int(_root.stat_player_lost);
_root.myGameData.data.stat_player_built = int(_root.stat_player_built);
_root.myGameData.data.stat_player_captured = int(_root.stat_player_captured);
_root.myGameData.data.stat_player_cash = int(_root.stat_player_cash);
_root.myGameData.data.stat_player_time = int(_root.stat_player_time);
_root.myGameData.data.stat_win = int(_root.myGameData.data.stat_win) + 1;
var i;
i = 0;
while (i < 280) {
_root["t" + i].removeMovieClip();
i++;
}
GiveAwards();
_root.myGameData.data.flush();
Score();
_root.myGameData.data.playerscore = int(_root.myGameData.data.playerscore) + int(_root.score);
_root.myGameData.data.flush();
Rank();
_root.myGameData.data.flush();
stop();
Instance of Symbol 324 MovieClip "menu" in Symbol 381 MovieClip [int_victory] Frame 39
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
on (press) {
_root.selectedUnit.Deselect();
_root.clearMap();
_root.reset();
_root.gotoAndPlay("menu");
}
Instance of Symbol 324 MovieClip "proceed" in Symbol 381 MovieClip [int_victory] Frame 39
on (rollOver) {
gotoAndPlay ("over");
}
on (rollOut) {
gotoAndPlay ("out");
}
on (press) {
_root.mission = _root.mission + 1;
_root.advisor.removeMovieClip();
_root.gotoAndPlay("init");
}
Symbol 386 MovieClip [fx_ripple] Frame 60
this.removeMovieClip();
Symbol 390 MovieClip [fx_ripple_up] Frame 60
this.removeMovieClip();
Symbol 397 MovieClip [blue_sub] Frame 1
#initclip 76
Object.registerClass("blue_sub", Unit);
#endinitclip
Symbol 397 MovieClip [blue_sub] Frame 4
stop();
Symbol 397 MovieClip [blue_sub] Frame 9
stop();
Symbol 397 MovieClip [blue_sub] Frame 14
stop();
Symbol 397 MovieClip [blue_sub] Frame 19
stop();
Symbol 404 MovieClip [red_sub] Frame 1
#initclip 46
Object.registerClass("red_sub", Unit);
#endinitclip
Symbol 404 MovieClip [red_sub] Frame 4
stop();
Symbol 404 MovieClip [red_sub] Frame 9
stop();
Symbol 404 MovieClip [red_sub] Frame 14
stop();
Symbol 404 MovieClip [red_sub] Frame 19
stop();
Symbol 406 MovieClip [72] Frame 1
#initclip 47
Object.registerClass("72", Terrain);
#endinitclip
Symbol 408 MovieClip [11] Frame 1
#initclip 48
Object.registerClass("11", Terrain);
#endinitclip
Symbol 415 MovieClip [25] Frame 1
#initclip 49
Object.registerClass("25", Terrain);
#endinitclip
stop();
Symbol 415 MovieClip [25] Frame 2
stop();
Symbol 415 MovieClip [25] Frame 3
stop();
Symbol 419 MovieClip [17] Frame 1
#initclip 50
Object.registerClass("17", Terrain);
#endinitclip
stop();
Symbol 419 MovieClip [17] Frame 2
stop();
Symbol 419 MovieClip [17] Frame 3
stop();
Symbol 426 MovieClip [16] Frame 1
#initclip 51
Object.registerClass("16", Terrain);
#endinitclip
stop();
Symbol 426 MovieClip [16] Frame 2
stop();
Symbol 426 MovieClip [16] Frame 3
stop();
Symbol 437 MovieClip [18] Frame 1
#initclip 52
Object.registerClass("18", Terrain);
#endinitclip
stop();
Symbol 437 MovieClip [18] Frame 2
stop();
Symbol 437 MovieClip [18] Frame 3
stop();
Symbol 443 MovieClip [51] Frame 1
#initclip 53
Object.registerClass("51", Terrain);
#endinitclip
stop();
Symbol 443 MovieClip [51] Frame 2
stop();
Symbol 443 MovieClip [51] Frame 3
stop();
Symbol 448 MovieClip [50] Frame 1
#initclip 54
Object.registerClass("50", Terrain);
#endinitclip
stop();
Symbol 448 MovieClip [50] Frame 2
stop();
Symbol 448 MovieClip [50] Frame 3
stop();
Symbol 453 MovieClip [15] Frame 1
#initclip 55
Object.registerClass("15", Terrain);
#endinitclip
stop();
Symbol 453 MovieClip [15] Frame 2
stop();
Symbol 453 MovieClip [15] Frame 3
stop();
Symbol 458 MovieClip [30] Frame 1
#initclip 56
Object.registerClass("30", Terrain);
#endinitclip
Symbol 461 MovieClip [73] Frame 1
#initclip 57
Object.registerClass("73", Terrain);
#endinitclip
Symbol 463 MovieClip [10] Frame 1
#initclip 58
Object.registerClass("10", Terrain);
#endinitclip
Symbol 465 MovieClip [1] Frame 1
#initclip 59
Object.registerClass("1", Terrain);
#endinitclip
Symbol 469 MovieClip [20] Frame 1
#initclip 60
Object.registerClass("20", Terrain);
#endinitclip
Symbol 472 MovieClip [21] Frame 1
#initclip 61
Object.registerClass("21", Terrain);
#endinitclip
Symbol 474 MovieClip [23] Frame 1
#initclip 62
Object.registerClass("23", Terrain);
#endinitclip
Symbol 476 MovieClip [26] Frame 1
#initclip 63
Object.registerClass("26", Terrain);
#endinitclip
Symbol 478 MovieClip [22] Frame 1
#initclip 64
Object.registerClass("22", Terrain);
#endinitclip
Symbol 479 MovieClip [2] Frame 1
#initclip 65
Object.registerClass("2", Terrain);
#endinitclip
Symbol 481 MovieClip [5] Frame 1
#initclip 66
Object.registerClass("5", Terrain);
#endinitclip
Symbol 483 MovieClip [7] Frame 1
#initclip 67
Object.registerClass("7", Terrain);
#endinitclip
Symbol 485 MovieClip [8] Frame 1
#initclip 68
Object.registerClass("8", Terrain);
#endinitclip
Symbol 487 MovieClip [6] Frame 1
#initclip 69
Object.registerClass("6", Terrain);
#endinitclip
Symbol 489 MovieClip [9] Frame 1
#initclip 70
Object.registerClass("9", Terrain);
#endinitclip
Symbol 491 MovieClip [3] Frame 1
#initclip 71
Object.registerClass("3", Terrain);
#endinitclip
Symbol 493 MovieClip [4] Frame 1
#initclip 72
Object.registerClass("4", Terrain);
#endinitclip
Symbol 495 MovieClip [70] Frame 1
#initclip 73
Object.registerClass("70", Terrain);
#endinitclip
Symbol 497 MovieClip [71] Frame 1
#initclip 74
Object.registerClass("71", Terrain);
#endinitclip
Symbol 499 MovieClip [0] Frame 1
#initclip 75
Object.registerClass("0", Terrain);
#endinitclip
Instance of Symbol 501 MovieClip in Symbol 502 MovieClip [blocker] Frame 1
on (press) {
}
on (release) {
}
Symbol 512 MovieClip [tile_holder] Frame 1
#initclip 91
Object.registerClass("tile_holder", MapEdit);
#endinitclip
Symbol 538 MovieClip Frame 1
sound = new Sound(this);
sound.attachSound("gamewin");
sound.start(0, 1);
Symbol 538 MovieClip Frame 1206
_root.gotoAndPlay("menu");
Symbol 568 MovieClip [m] Frame 1
#initclip 77
Object.registerClass("m", Movement);
#endinitclip
Symbol 568 MovieClip [m] Frame 30
gotoAndPlay (1);
Symbol 568 MovieClip [m] Frame 31
stop();
Symbol 571 MovieClip [m2] Frame 1
#initclip 78
Object.registerClass("m2", Movement);
#endinitclip
Symbol 571 MovieClip [m2] Frame 30
gotoAndPlay (1);
Symbol 592 Button
on (press) {
_root.gotoAndPlay("mplay");
}
Symbol 618 MovieClip Frame 1
intro = new Sound();
intro.attachSound("victory");
intro.start(0, 1);
Symbol 618 MovieClip Frame 280
_root.gotoAndPlay("menu");
Symbol 622 MovieClip Frame 225
stop();
Symbol 633 MovieClip Frame 1
stop();
Symbol 633 MovieClip Frame 2
stop();
Symbol 633 MovieClip Frame 3
stop();
Symbol 633 MovieClip Frame 4
stop();
Symbol 633 MovieClip Frame 5
stop();
Symbol 660 MovieClip Frame 1
stop();
Symbol 685 MovieClip Frame 30
_root.updateIntel();
Symbol 687 MovieClip [interface_day] Frame 1
stop();
Instance of Symbol 685 MovieClip "int_inside" in Symbol 687 MovieClip [interface_day] Frame 1
on (press) {
gotoAndPlay (2);
}
on (release) {
gotoAndPlay (11);
}
Symbol 687 MovieClip [interface_day] Frame 19
stop();
Symbol 687 MovieClip [interface_day] Frame 29
gotoAndPlay (1);
Symbol 691 MovieClip [int_undig] Frame 1
#initclip 79
Object.registerClass("int_undig", Interface);
#endinitclip
Symbol 695 MovieClip [int_trench] Frame 1
#initclip 80
Object.registerClass("int_trench", Interface);
#endinitclip
Symbol 705 MovieClip Frame 1
stop();
Symbol 705 MovieClip Frame 2
stop();
Symbol 740 MovieClip [int_repair] Frame 9
var SFX = new Sound(this);
SFX.attachSound(repair);
SFX.setVolume = _root.sfx_vol;
SFX.start(0, 1);
Symbol 740 MovieClip [int_repair] Frame 30
this.removeMovieClip();
Symbol 743 MovieClip [int_reload] Frame 9
var SFX = new Sound(this);
SFX.attachSound(reload);
SFX.setVolume = _root.sfx_vol;
SFX.start(0, 1);
Symbol 743 MovieClip [int_reload] Frame 30
this.removeMovieClip();
Symbol 746 MovieClip [int_refuel] Frame 30
this.removeMovieClip();
Symbol 748 Button
on (press) {
_root._quality = "HIGH";
}
Symbol 749 Button
on (press) {
_root._quality = "MEDIUM";
}
Symbol 750 Button
on (press) {
_root._quality = "LOW";
}
Symbol 759 MovieClip Frame 1
_root.sfx_vol = int((volslider._x / 174) * 100);
Instance of Symbol 758 MovieClip "bar" in Symbol 759 MovieClip Frame 1
on (press) {
_parent.volslider._x = _xmouse;
if (_xmouse < 0) {
_parent.volslider._x = 0;
}
if (_xmouse > 174) {
_parent.volslider._x = 174;
}
}
Symbol 761 MovieClip Frame 1
_root.music_vol = int((volslider._x / 174) * 100);
_root.bgm.setVolume(_root.music_vol);
Instance of Symbol 756 MovieClip "volslider" in Symbol 761 MovieClip Frame 1
on (press) {
this._x = _xmouse;
if (_xmouse < 0) {
this._x = 0;
}
if (_xmouse > 174) {
this._x = 174;
}
}
Instance of Symbol 760 MovieClip in Symbol 761 MovieClip Frame 1
on (press) {
_parent.volslider._x = _xmouse;
if (_xmouse < 0) {
_parent.volslider._x = 0;
}
if (_xmouse > 174) {
_parent.volslider._x = 174;
}
}
Symbol 764 MovieClip Frame 1
stop();
Symbol 764 MovieClip Frame 2
stop();
Symbol 767 MovieClip Frame 1
stop();
Symbol 767 MovieClip Frame 2
stop();
Symbol 788 MovieClip [int_options] Frame 1
if (_root.fastmove == false) {
quickmove.gotoAndStop(1);
} else {
quickmove.gotoAndStop(2);
}
if (_root.opt_menuslide != true) {
menuslide.gotoAndStop(1);
} else {
menuslide.gotoAndStop(2);
}
musvol.volslider._x = (int(_root.music_vol) / 100) * 174;
sfxvol.volslider._x = (int(_root.sfx_vol) / 100) * 174;
Instance of Symbol 673 MovieClip in Symbol 788 MovieClip [int_options] Frame 1
on (press) {
_root.reset();
_root.ClearMap();
_root.gotoAndPlay("gameover");
}
Instance of Symbol 753 MovieClip in Symbol 788 MovieClip [int_options] Frame 1
on (press) {
_parent.removeMovieClip();
}
Instance of Symbol 673 MovieClip in Symbol 788 MovieClip [int_options] Frame 1
on (press) {
_parent.removeMovieClip();
}
Instance of Symbol 764 MovieClip "menuslide" in Symbol 788 MovieClip [int_options] Frame 1
on (press) {
_root.opt_menuslide = !_root.opt_menuslide;
if (_root.opt_menuslide == false) {
gotoAndStop (1);
} else {
gotoAndStop (2);
}
}
Instance of Symbol 767 MovieClip "quickmove" in Symbol 788 MovieClip [int_options] Frame 1
on (press) {
_root.fastmove = !_root.fastmove;
if (_root.fastmove == false) {
gotoAndStop (1);
} else {
gotoAndStop (2);
}
}
Symbol 790 MovieClip [int_nomoney] Frame 40
this.removeMovieClip();
Symbol 801 MovieClip [int_getOut] Frame 1
#initclip 81
Object.registerClass("int_getOut", Interface);
#endinitclip
Symbol 802 MovieClip [int_getIn] Frame 1
#initclip 82
Object.registerClass("int_getIn", Interface);
#endinitclip
Symbol 805 Button
on (press) {
this.removeMovieClip();
}
Symbol 811 Button
on (press) {
_root.buildUnit("blue_rocket", 0, "track", "rocket");
this.removeMovieClip();
}
Symbol 812 Button
on (press) {
_root.buildUnit("blue_art", 0, "track", "artillery");
this.removeMovieClip();
}
Symbol 813 Button
on (press) {
_root.buildUnit("blue_tank", 0, "track", "tank");
this.removeMovieClip();
}
Symbol 814 Button
on (press) {
_root.buildUnit("blue_aa", 0, "track", "aa");
this.removeMovieClip();
}
Symbol 815 Button
on (press) {
_root.buildUnit("blue_apc", 0, "track", "apc");
this.removeMovieClip();
}
Symbol 816 Button
on (press) {
_root.buildUnit("blue_scout", 0, "wheel", "scout");
this.removeMovieClip();
}
Symbol 817 Button
on (press) {
_root.buildUnit("blue_rocketinf", 0, "foot", "rocket infantry");
this.removeMovieClip();
}
Symbol 818 Button
on (press) {
_root.buildUnit("blue_infantry", 0, "foot", "infantry");
this.removeMovieClip();
}
Symbol 846 MovieClip [int_endday] Frame 5
var sound = new Sound(this);
sound.attachSound("chime");
sound.setVolume(_root.sfx_vol);
sound.start(0, 1);
Symbol 846 MovieClip [int_endday] Frame 42
this.removeMovieClip();
Symbol 851 Button
on (press) {
this.removeMovieClip();
}
Symbol 861 MovieClip [int_dig] Frame 1
#initclip 83
Object.registerClass("int_dig", Interface);
#endinitclip
Symbol 862 MovieClip [int_chat] Frame 140
this.removeMovieClip();
Symbol 872 MovieClip Frame 1
force.text = this._parent.unit_hp + "HP";
city.text = this._parent.old_hp + "HP";
Symbol 872 MovieClip Frame 20
city.text = random(200) + "HP";
Symbol 872 MovieClip Frame 21
city.text = random(200) + "HP";
Symbol 872 MovieClip Frame 22
city.text = random(200) + "HP";
Symbol 872 MovieClip Frame 23
city.text = random(200) + "HP";
Symbol 872 MovieClip Frame 24
city.text = random(200) + "HP";
Symbol 872 MovieClip Frame 25
city.text = random(200) + "HP";
Symbol 872 MovieClip Frame 26
city.text = random(200) + "HP";
Symbol 872 MovieClip Frame 27
city.text = random(200) + "HP";
Symbol 872 MovieClip Frame 28
city.text = random(200) + "HP";
Symbol 872 MovieClip Frame 29
city.text = random(200) + "HP";
Symbol 872 MovieClip Frame 30
city.text = random(200) + "HP";
Symbol 872 MovieClip Frame 31
city.text = _parent.new_hp + "HP";
Symbol 872 MovieClip Frame 50
_parent.gotoAndPlay(7);
stop();
Symbol 873 MovieClip [int_capturing_south] Frame 1
_root.int_capture.removeMovieClip();
_root.selectedUnit.moves_left = 0;
_root.selectedUnit.attacked = true;
Symbol 873 MovieClip [int_capturing_south] Frame 4
var old_hp;
var unit_hp;
var new_hp;
var percent;
var tracker;
old_hp = int(myOwner.city_hp);
unit_hp = int(_root.selectedUnit.hp);
new_hp = int(old_hp) - int(unit_hp);
percent = int(((200 - int(new_hp)) / 200) * 100);
myOwner.city_hp = new_hp;
if (new_hp <= 0) {
_root.tstat_player_captured = int(_root.tstat_player_captured) + 1;
myOwner.city_owner = 0;
myOwner.gotoAndStop(2);
myOwner.city_hp = 200;
}
_root.selectedUnit.Deselect();
Symbol 873 MovieClip [int_capturing_south] Frame 6
stop();
Symbol 873 MovieClip [int_capturing_south] Frame 10
if (new_hp > 0) {
this.removeMovieClip();
}
this.removeMovieClip();
Symbol 876 MovieClip [int_capture_china_south] Frame 1
#initclip 84
Object.registerClass("int_capture_china_south", Interface);
#endinitclip
_root.lock = true;
_root.int_capture.removeMovieClip();
_root.selectedUnit.moves_left = 0;
_root.selectedUnit.attacked = true;
Symbol 876 MovieClip [int_capture_china_south] Frame 4
var old_hp;
var unit_hp;
var new_hp;
var percent;
var tracker;
old_hp = int(myOwner.city_hp);
unit_hp = int(_root.selectedUnit.hp);
new_hp = int(old_hp) - int(unit_hp);
percent = int(((200 - int(new_hp)) / 200) * 100);
myOwner.city_hp = new_hp;
if (new_hp <= 0) {
_root.tstat_com_captured = int(_root.tstat_com_captured) + 1;
myOwner.city_owner = 1;
myOwner.gotoAndStop(3);
myOwner.city_hp = 200;
}
_root.selectedUnit.Deselect();
Symbol 876 MovieClip [int_capture_china_south] Frame 6
stop();
Symbol 876 MovieClip [int_capture_china_south] Frame 10
if (new_hp > 0) {
_root.lock = false;
this.removeMovieClip();
}
_root.lock = false;
this.removeMovieClip();
Symbol 878 MovieClip [int_capture_china] Frame 1
#initclip 85
Object.registerClass("int_capture_china", Interface);
#endinitclip
_root.lock = true;
_root.int_capture.removeMovieClip();
_root.selectedUnit.moves_left = 0;
_root.selectedUnit.attacked = true;
Symbol 878 MovieClip [int_capture_china] Frame 4
var old_hp;
var unit_hp;
var new_hp;
var percent;
var tracker;
old_hp = int(myOwner.city_hp);
unit_hp = int(_root.selectedUnit.hp);
new_hp = int(old_hp) - int(unit_hp);
percent = int(((200 - int(new_hp)) / 200) * 100);
myOwner.city_hp = new_hp;
if (new_hp <= 0) {
_root.tstat_com_captured = int(_root.tstat_com_captured) + 1;
myOwner.city_owner = 1;
myOwner.gotoAndStop(3);
myOwner.city_hp = 200;
}
_root.selectedUnit.Deselect();
Symbol 878 MovieClip [int_capture_china] Frame 6
stop();
Symbol 878 MovieClip [int_capture_china] Frame 10
if (new_hp > 0) {
_root.lock = false;
this.removeMovieClip();
}
_root.lock = false;
this.removeMovieClip();
Symbol 879 MovieClip [int_capturing] Frame 1
#initclip 86
Object.registerClass("int_capturing", Interface);
#endinitclip
_root.int_capture.removeMovieClip();
_root.selectedUnit.moves_left = 0;
_root.selectedUnit.attacked = true;
Symbol 879 MovieClip [int_capturing] Frame 4
var old_hp;
var unit_hp;
var new_hp;
var percent;
var tracker;
old_hp = int(myOwner.city_hp);
unit_hp = int(_root.selectedUnit.hp);
new_hp = int(old_hp) - int(unit_hp);
percent = int(((200 - int(new_hp)) / 200) * 100);
myOwner.city_hp = new_hp;
if (new_hp <= 0) {
_root.tstat_player_captured = int(_root.tstat_player_captured) + 1;
myOwner.city_owner = 0;
myOwner.gotoAndStop(2);
myOwner.city_hp = 200;
}
_root.selectedUnit.Deselect();
Symbol 879 MovieClip [int_capturing] Frame 6
stop();
Symbol 879 MovieClip [int_capturing] Frame 10
if (new_hp > 0) {
this.removeMovieClip();
}
this.removeMovieClip();
Symbol 888 MovieClip [int_capture] Frame 1
#initclip 87
Object.registerClass("int_capture", Interface);
#endinitclip
Symbol 888 MovieClip [int_capture] Frame 90
gotoAndPlay (70);
Symbol 898 MovieClip [int_bar] Frame 1
#initclip 88
Object.registerClass("int_bar", Interface);
#endinitclip
Symbol 901 MovieClip [int_attackinfo] Frame 10
stop();
Symbol 901 MovieClip [int_attackinfo] Frame 20
this.removeMovieClip();
Symbol 905 Button
on (press) {
_root.buildUnit("blue_bomber", 0, "air", "bomber");
this.removeMovieClip();
}
Symbol 906 Button
on (press) {
_root.buildUnit("blue_fighter", 0, "air", "fighter");
this.removeMovieClip();
}
Symbol 907 Button
on (press) {
_root.buildUnit("blue_helicopter", 0, "air", "helicopter");
this.removeMovieClip();
}
Symbol 908 Button
on (press) {
_root.buildUnit("blue_transport", 0, "air", "transport");
this.removeMovieClip();
}
Symbol 921 MovieClip [attack_safe] Frame 1
#initclip 89
Object.registerClass("attack_safe", Attack);
#endinitclip
Symbol 922 MovieClip [attack] Frame 1
#initclip 90
Object.registerClass("attack", Attack);
#endinitclip
Symbol 922 MovieClip [attack] Frame 20
if (by.team != 0) {
this.removeMovieClip();
}
Symbol 922 MovieClip [attack] Frame 40
if (by.team != 0) {
this.removeMovieClip();
}
Symbol 925 MovieClip [fx_tracks_up] Frame 90
this.removeMovieClip();
Symbol 926 MovieClip [fx_tracks] Frame 90
this.removeMovieClip();
Symbol 935 MovieClip [fx_shot_mgun] Frame 3
sound = new Sound(this);
sound.attachSound("Richet1");
sound.setVolume(_root.sfx_vol);
sound.start(0, 1);
Symbol 935 MovieClip [fx_shot_mgun] Frame 14
sound2 = new Sound(this);
sound2.attachSound("Richet2");
sound2.setVolume(_root.sfx_vol);
sound2.start(0, 1);
Symbol 935 MovieClip [fx_shot_mgun] Frame 25
sound3 = new Sound(this);
sound3.attachSound("Richet3");
sound3.setVolume(_root.sfx_vol);
sound3.start(0, 1);
Symbol 935 MovieClip [fx_shot_mgun] Frame 45
this.removeMovieClip();
Symbol 936 MovieClip Frame 45
this.removeMovieClip();
Symbol 940 MovieClip [fx_shot_cannon] Frame 30
this.removeMovieClip();
Symbol 942 MovieClip [fx_footprints_up] Frame 90
this.removeMovieClip();
Symbol 943 MovieClip [fx_footprints] Frame 90
this.removeMovieClip();
Symbol 944 MovieClip [fx_contrail] Frame 90
this.removeMovieClip();
Symbol 963 MovieClip Frame 1
sound = new Sound(this);
sound.attachSound("LrgExpl");
sound.setVolume(_root.sfx_volume);
sound.start(0, 1);
Symbol 963 MovieClip Frame 150
this._parent.removeMovieClip();
Symbol 986 MovieClip Frame 1
stop();
Symbol 986 MovieClip Frame 2
stop();
Symbol 986 MovieClip Frame 3
stop();
Symbol 986 MovieClip Frame 4
stop();
Symbol 986 MovieClip Frame 5
stop();
Symbol 986 MovieClip Frame 6
stop();
Symbol 986 MovieClip Frame 7
stop();
Symbol 986 MovieClip Frame 8
stop();
Symbol 986 MovieClip Frame 9
stop();
Symbol 986 MovieClip Frame 10
stop();
Symbol 986 MovieClip Frame 11
stop();
Symbol 986 MovieClip Frame 12
stop();
Symbol 986 MovieClip Frame 13
stop();
Symbol 986 MovieClip Frame 14
stop();
Symbol 986 MovieClip Frame 15
stop();
Symbol 986 MovieClip Frame 16
stop();
Symbol 986 MovieClip Frame 17
stop();
Symbol 999 MovieClip [briefing19] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1006 MovieClip [briefing18] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1011 MovieClip [briefing17] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1015 MovieClip [briefing16] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1020 MovieClip [briefing15] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1024 MovieClip [briefing14] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1028 MovieClip [briefing13] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1034 MovieClip [briefing12] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1040 MovieClip [briefing11] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1044 MovieClip [briefing10] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1051 MovieClip [briefing9] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1056 MovieClip [briefing8] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1061 MovieClip [briefing7] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1066 MovieClip [briefing6] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1071 MovieClip [briefing5] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1077 MovieClip [briefing4] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1084 MovieClip [briefing3] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1090 MovieClip [briefing2] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1101 MovieClip Frame 1
stop();
Symbol 1101 MovieClip Frame 2
stop();
Symbol 1101 MovieClip Frame 3
stop();
Symbol 1101 MovieClip Frame 4
stop();
Symbol 1103 MovieClip [advisor] Frame 1
#initclip 92
Object.registerClass("advisor", Advisor);
#endinitclip
Symbol 1109 MovieClip [briefing1] Frame 1
var briefing = new Sound(this);
briefing.attachSound("brief");
briefing.setVolume(_root.music_vol);
briefing.start(0, 10);
Symbol 1129 MovieClip Frame 15
stop();
Symbol 1130 MovieClip Frame 130
_root.gotoAndPlay("menu");
Symbol 1131 MovieClip Frame 1
stop();
Symbol 1131 MovieClip Frame 5
stop();
Symbol 1142 MovieClip Frame 10
stop();
Symbol 1153 MovieClip Frame 5
stop();
Symbol 1185 MovieClip Frame 1
stop();
Symbol 1185 MovieClip Frame 2
stop();
Symbol 1185 MovieClip Frame 3
stop();
Symbol 1185 MovieClip Frame 4
stop();
Symbol 1185 MovieClip Frame 5
stop();
Symbol 1185 MovieClip Frame 6
stop();
Symbol 1185 MovieClip Frame 7
stop();
Symbol 1185 MovieClip Frame 8
stop();
Symbol 1185 MovieClip Frame 9
stop();
Symbol 1185 MovieClip Frame 10
stop();
Symbol 1185 MovieClip Frame 11
stop();
Symbol 1185 MovieClip Frame 12
stop();
Symbol 1185 MovieClip Frame 13
stop();
Symbol 1193 MovieClip Frame 1
stop();
Symbol 1193 MovieClip Frame 10
stop();
Symbol 1193 MovieClip Frame 20
stop();
Symbol 1194 Button
on (press) {
_root.endmove();
}
Symbol 1198 Button
on (press) {
if (int_options == undefined) {
_root.attachMovie("int_options", "int_options", 2999);
} else {
int_options.removeMovieClip();
}
}
Symbol 1297 Button
on (press) {
i = 0;
while (i < 280) {
_root["t" + i].me = _root.selectedTerrain.slice(1);
_root["t" + i].attachMovie(_root.selectedTerrain.slice(1).toString(), "current", 2);
i++;
}
}
Symbol 1299 Button
on (press) {
dump();
}
Symbol 1301 MovieClip Frame 1
selectedID = _root.selectedTerrain.slice(1);
this.attachMovie(selectedID, "selected", 10);
Symbol 1318 Button
on (press) {
_root.gotoAndPlay("menu");
}
Symbol 1319 Button
on (press) {
gotoAndPlay (4);
}
Symbol 1320 Button
on (press) {
gotoAndPlay (2);
}
Symbol 1334 Button
on (press) {
_root.playerlane = 4;
gotoAndPlay (3);
}
Symbol 1335 Button
on (press) {
_root.playerlane = 3;
gotoAndPlay (3);
}
Symbol 1336 Button
on (press) {
_root.playerlane = 2;
gotoAndPlay (3);
}
Symbol 1337 Button
on (press) {
_root.playerlane = 1;
gotoAndPlay (3);
}
Symbol 1339 Button
on (press) {
gotoAndPlay (1);
}
Symbol 1347 Button
on (press) {
if (_root.bet <= _root.credits) {
_root.credits = _root.credits - _root.bet;
this._parent.gotoAndPlay(2);
}
}
Symbol 1351 Button
on (press) {
gotoAndStop (1);
}
Symbol 1352 MovieClip Frame 1
stop();
Symbol 1352 MovieClip Frame 2
stop();
Symbol 1352 MovieClip Frame 3
stop();
Symbol 1352 MovieClip Frame 4
stop();
Symbol 1383 Button
on (press) {
gotoAndStop (1);
}
Symbol 1392 MovieClip Frame 1
hills2.stop();
hills1.stop();
clouds.stop();
grass1.stop();
grass2.stop();
grass3.stop();
grass4.stop();
finish.stop();
lane1._x = 50;
lane2._x = 50;
lane3._x = 50;
lane4._x = 50;
stop();
Symbol 1392 MovieClip Frame 2
function UpdateRacers() {
var _local3;
var _local8;
var _local7;
var _local6;
var _local5;
var _local4;
_local3 = 0;
while (_local3 <= 4) {
_local4 = int(Math.random() * 3) - 1;
this["speed" + _local3] = this["speed" + _local3] + _local4;
if (this["speed" + _local3] <= 0) {
this["speed" + _local3] = 1;
}
if (this["speed" + _local3] > 5) {
this["speed" + _local3] = 5;
}
this["lane" + _local3]._x = this["lane" + _local3]._x + this["speed" + _local3];
if (this["lane" + _local3]._x > 510) {
_root.winninglane = _local3;
gotoAndPlay ("won");
}
_local3++;
}
}
hills2.play();
hills1.play();
clouds.play();
grass1.play();
grass2.play();
grass3.play();
grass4.play();
UpdateRacers();
Symbol 1392 MovieClip Frame 3
gotoAndPlay (2);
Symbol 1392 MovieClip Frame 4
hills2.stop();
hills1.stop();
clouds.stop();
grass1.stop();
grass2.stop();
grass3.stop();
grass4.stop();
finish.stop();
if (_root.playerlane == _root.winninglane) {
winnings = int(_root.bet * 2);
_root.credits = _root.credits + winnings;
outcome.text = ("Congratulations! You bet on the right lane and won " + winnings) + " credits!";
} else {
outcome.text = "Sorry, you didn't win this time, why don't you try again!";
}
stop();
Symbol 1432 MovieClip Frame 2
stop();
Symbol 1432 MovieClip Frame 24
gotoAndPlay ("normal");
Symbol 1432 MovieClip Frame 50
gotoAndPlay ("normal");
Symbol 1432 MovieClip Frame 74
gotoAndPlay ("normal");
Symbol 1432 MovieClip Frame 100
gotoAndPlay ("normal");
Symbol 1432 MovieClip Frame 126
gotoAndPlay ("normal");
Symbol 1432 MovieClip Frame 150
gotoAndPlay ("normal");
Symbol 1432 MovieClip Frame 175
gotoAndPlay ("normal");
Symbol 1432 MovieClip Frame 200
gotoAndPlay ("normal");
Symbol 1432 MovieClip Frame 225
gotoAndPlay ("normal");
Symbol 1432 MovieClip Frame 250
gotoAndPlay ("normal");
Symbol 1432 MovieClip Frame 274
gotoAndPlay ("normal");
Symbol 1432 MovieClip Frame 275
stop();
Symbol 1432 MovieClip Frame 300
gotoAndPlay ("normal");
Symbol 1443 Button
on (press) {
_root.gotoAndPlay("menu");
}
Symbol 1457 MovieClip Frame 1
function talk() {
}
function update(routine) {
happy._width = myHappy;
hunger._width = myHunger;
love._width = myLove;
study._width = myStudy;
health._width = myHealth;
bladder._width = myBladder;
speech._x = pet._x;
speech._y = pet._y;
if (myHunger <= 0) {
myHealth = myHealth - 10;
}
if (myHealth <= 0) {
pet.gotoAndStop("dead");
}
if (routine == true) {
age.text = int(age.text) + 1;
myHunger = myHunger - 1;
myBladder = myBladder - 1;
myHappy = myHappy - 1;
myLove = myLove - 1;
myStudy = myStudy - 1;
speech._alpha = 0;
var _local1 = int(random(20));
switch (_local1) {
case 0 :
speech.speech.text = "Lookin hot!";
speech._alpha = 100;
break;
case 1 :
pet.gotoAndPlay("blush");
speech.speech.text = "I wuv u";
speech._alpha = 100;
break;
case 2 :
pet.gotoAndPlay("anger");
speech.speech.text = "Feed me NOW!";
speech._alpha = 100;
break;
case 3 :
pet.gotoAndPlay("stress");
speech.speech.text = "I feel dumb";
speech._alpha = 100;
break;
case 4 :
pet.gotoAndPlay("shout");
speech.speech.text = "Your momma!";
speech._alpha = 100;
break;
case 5 :
pet.gotoAndPlay("anger");
speech.speech.text = "WTF?! STFU NOOB";
speech._alpha = 100;
break;
case 6 :
pet.gotoAndPlay("cry");
speech.speech.text = "So lonely...";
speech._alpha = 100;
break;
case 7 :
pet.gotoAndPlay("normal");
speech.speech.text = "La la la";
speech._alpha = 100;
break;
case 8 :
pet.gotoAndPlay("kiss");
speech.speech.text = "No Tongues!!";
speech._alpha = 100;
}
}
if (myPoo._alpha == 100) {
pet.gotoAndPlay("alert");
}
if ((myPoo._alpha == 100) && (pet.hitTest(myPoo))) {
pet.gotoAndPlay("sick");
myHealth = myHealth - 10;
}
if ((myBladder <= 2) && (myPoo._alpha == 0)) {
pet.gotoAndPlay("blush");
speech.speech.text = "Whoops!";
speech._alpha = 100;
myBladder = 100;
myPoo._x = pet._x;
myPoo._y = pet._y;
myPoo._alpha = 100;
}
}
function Give(variable, val) {
this[variable] = this[variable] + val;
if (this[variable] > 100) {
this[variable] = 100;
}
if (this[variable] < 0) {
this[variable] = 0;
}
update();
}
var myHunger = 50;
var myHappy = 50;
var myLove = 0;
var myStudy = 0;
var myHealth = 100;
var myBladder = 100;
feed.onPress = function () {
pet.gotoAndPlay("happy");
Give("myHunger", 10);
Give("myBladder", -10);
speech.speech.text = "Yum Delicious!";
speech._alpha = 100;
};
play.onPress = function () {
pet.gotoAndPlay("happy");
Give("myLove", 10);
Give("myHappy", 10);
speech.speech.text = "I Win!";
speech._alpha = 100;
};
kiss.onPress = function () {
pet.gotoAndPlay("kiss");
Give("myLove", 15);
Give("myHappy", 8);
speech.speech.text = "Mwah!!";
speech._alpha = 100;
};
studyk.onPress = function () {
pet.gotoAndPlay("study");
Give("myStudy", 10);
Give("myHappy", -15);
speech.speech.text = "Aww";
speech._alpha = 100;
};
talke.onPress = function () {
pet.gotoAndPlay("talk");
Give("myStudy", 3);
Give("myHappy", 3);
Give("myLove", 1);
speech.speech.text = "What? What's weather?";
speech._alpha = 100;
};
medicine.onPress = function () {
pet.gotoAndPlay("cry");
Give("myHealth", 25);
speech.speech.text = "Ow, I hate needles!";
speech._alpha = 100;
};
clean.onPress = function () {
pet.gotoAndPlay("blush");
Give("myHealth", 5);
myPoo._alpha = 0;
speech.speech.text = "Fresh as a daisy!";
speech._alpha = 100;
};
smack.onPress = function () {
pet.gotoAndPlay("cry");
Give("myHappy", -15);
Give("myLove", -5);
Give("myHealth", -10);
Give("myStudy", 5);
speech.speech.text = "I'm telling mom!";
speech._alpha = 100;
};
Symbol 1457 MovieClip Frame 2
pet._x = pet._x + int(random(20) - 10);
pet._y = pet._y + int(random(10) - 5);
if (pet._x > 500) {
pet._x = 500;
}
if (pet._x < 250) {
pet._x = 250;
}
if (pet._y > 190) {
pet._y = 190;
}
if (pet._y < 90) {
pet._y = 90;
}
speech._x = pet._x;
speech._y = pet._y;
Symbol 1457 MovieClip Frame 25
pet._x = pet._x + int(random(20) - 10);
pet._y = pet._y + int(random(10) - 5);
if (pet._x > 500) {
pet._x = 500;
}
if (pet._x < 250) {
pet._x = 250;
}
if (pet._y > 190) {
pet._y = 190;
}
if (pet._y < 90) {
pet._y = 90;
}
speech._x = pet._x;
speech._y = pet._y;
Symbol 1457 MovieClip Frame 50
pet._x = pet._x + int(random(20) - 10);
pet._y = pet._y + int(random(10) - 5);
if (pet._x > 500) {
pet._x = 500;
}
if (pet._x < 250) {
pet._x = 250;
}
if (pet._y > 190) {
pet._y = 190;
}
if (pet._y < 90) {
pet._y = 90;
}
speech._x = pet._x;
speech._y = pet._y;
Symbol 1457 MovieClip Frame 60
update(true);
gotoAndPlay (2);
Symbol 1462 MovieClip Frame 1
stop();
Symbol 1462 MovieClip Frame 5
sound = new Sound(this);
sound.attachSound("hammerwhack");
sound.setVolume(_root.sfx_vol);
sound.start(0, 1);
Symbol 1466 Button
on (press) {
if (_currentframe <= 2) {
gotoAndPlay ("player");
} else {
gotoAndPlay (1);
}
}
Symbol 1467 Button
on (press) {
_root.gotoAndPlay("menu");
}
Symbol 1473 MovieClip Frame 4
stop();
Symbol 1473 MovieClip Frame 35
gotoAndPlay (1);
Symbol 1473 MovieClip Frame 65
gotoAndPlay (1);
Symbol 1473 MovieClip Frame 85
gotoAndPlay (1);
Symbol 1481 MovieClip Frame 1
var mouseListener = new Object();
mouseListener.onMouseDown = function () {
var _local3;
var _local4;
var _local2;
hammer.gotoAndPlay("whack");
_local2 = 1;
while (_local2 <= 9) {
if (this.hammer.collision.hitTest(this["pad" + _local2])) {
_local3 = this["pad" + _local2]._currentframe;
if ((_local3 >= 5) && (_local3 < 35)) {
this["pad" + _local2].gotoAndPlay("whack");
_local4 = 50;
}
if ((_local3 >= 36) && (_local3 < 65)) {
this["pad" + _local2].gotoAndPlay("whack");
_local4 = 250;
}
if ((_local3 >= 66) && (_local3 < 85)) {
this["pad" + _local2].gotoAndPlay("whack");
_local4 = 1000;
}
score.text = int(score.text) + _local4;
}
_local2++;
}
};
score.text = 0;
timeleft.text = 500;
Mouse.addListener(mouseListener);
Mouse.hide();
startDrag (hammer, true);
Instance of Symbol 1473 MovieClip "pad9" in Symbol 1481 MovieClip Frame 1
on (press) {
var frame = 0;
var points = 0;
frame = this._currentframe;
if ((frame >= 5) && (frame < 35)) {
gotoAndPlay ("whack");
points = 50;
}
if ((frame >= 36) && (frame < 65)) {
gotoAndPlay ("whack");
points = 250;
}
if ((frame >= 66) && (frame < 85)) {
gotoAndPlay ("whack");
points = 1000;
}
this._parent.score.text = int(this._parent.score.text) + points;
}
Instance of Symbol 1473 MovieClip "pad6" in Symbol 1481 MovieClip Frame 1
on (press) {
var frame = 0;
var points = 0;
frame = this._currentframe;
if ((frame >= 5) && (frame < 35)) {
gotoAndPlay ("whack");
points = 50;
}
if ((frame >= 36) && (frame < 65)) {
gotoAndPlay ("whack");
points = 250;
}
if ((frame >= 66) && (frame < 85)) {
gotoAndPlay ("whack");
points = 1000;
}
this._parent.score.text = int(this._parent.score.text) + points;
}
Instance of Symbol 1473 MovieClip "pad3" in Symbol 1481 MovieClip Frame 1
on (press) {
var frame = 0;
var points = 0;
frame = this._currentframe;
if ((frame >= 5) && (frame < 35)) {
gotoAndPlay ("whack");
points = 50;
}
if ((frame >= 36) && (frame < 65)) {
gotoAndPlay ("whack");
points = 250;
}
if ((frame >= 66) && (frame < 85)) {
gotoAndPlay ("whack");
points = 1000;
}
this._parent.score.text = int(this._parent.score.text) + points;
}
Instance of Symbol 1473 MovieClip "pad8" in Symbol 1481 MovieClip Frame 1
on (press) {
var frame = 0;
var points = 0;
frame = this._currentframe;
if ((frame >= 5) && (frame < 35)) {
gotoAndPlay ("whack");
points = 50;
}
if ((frame >= 36) && (frame < 65)) {
gotoAndPlay ("whack");
points = 250;
}
if ((frame >= 66) && (frame < 85)) {
gotoAndPlay ("whack");
points = 1000;
}
this._parent.score.text = int(this._parent.score.text) + points;
}
Instance of Symbol 1473 MovieClip "pad5" in Symbol 1481 MovieClip Frame 1
on (press) {
var frame = 0;
var points = 0;
frame = this._currentframe;
if ((frame >= 5) && (frame < 35)) {
gotoAndPlay ("whack");
points = 50;
}
if ((frame >= 36) && (frame < 65)) {
gotoAndPlay ("whack");
points = 250;
}
if ((frame >= 66) && (frame < 85)) {
gotoAndPlay ("whack");
points = 1000;
}
this._parent.score.text = int(this._parent.score.text) + points;
}
Instance of Symbol 1473 MovieClip "pad2" in Symbol 1481 MovieClip Frame 1
on (press) {
var frame = 0;
var points = 0;
frame = this._currentframe;
if ((frame >= 5) && (frame < 35)) {
gotoAndPlay ("whack");
points = 50;
}
if ((frame >= 36) && (frame < 65)) {
gotoAndPlay ("whack");
points = 250;
}
if ((frame >= 66) && (frame < 85)) {
gotoAndPlay ("whack");
points = 1000;
}
this._parent.score.text = int(this._parent.score.text) + points;
}
Instance of Symbol 1473 MovieClip "pad7" in Symbol 1481 MovieClip Frame 1
on (press) {
var frame = 0;
var points = 0;
frame = this._currentframe;
if ((frame >= 5) && (frame < 35)) {
gotoAndPlay ("whack");
points = 50;
}
if ((frame >= 36) && (frame < 65)) {
gotoAndPlay ("whack");
points = 250;
}
if ((frame >= 66) && (frame < 85)) {
gotoAndPlay ("whack");
points = 1000;
}
this._parent.score.text = int(this._parent.score.text) + points;
}
Instance of Symbol 1473 MovieClip "pad4" in Symbol 1481 MovieClip Frame 1
on (press) {
var frame = 0;
var points = 0;
frame = this._currentframe;
if ((frame >= 5) && (frame < 35)) {
gotoAndPlay ("whack");
points = 50;
}
if ((frame >= 36) && (frame < 65)) {
gotoAndPlay ("whack");
points = 250;
}
if ((frame >= 66) && (frame < 85)) {
gotoAndPlay ("whack");
points = 1000;
}
this._parent.score.text = int(this._parent.score.text) + points;
}
Instance of Symbol 1473 MovieClip "pad1" in Symbol 1481 MovieClip Frame 1
on (press) {
var frame = 0;
var points = 0;
frame = this._currentframe;
if ((frame >= 5) && (frame < 35)) {
gotoAndPlay ("whack");
points = 50;
}
if ((frame >= 36) && (frame < 65)) {
gotoAndPlay ("whack");
points = 250;
}
if ((frame >= 66) && (frame < 85)) {
gotoAndPlay ("whack");
points = 1000;
}
this._parent.score.text = int(this._parent.score.text) + points;
}
Symbol 1481 MovieClip Frame 2
stop();
Symbol 1481 MovieClip Frame 3
i = 1;
while (i <= 9) {
var rand = (Math.random() * 300);
if (this["pad" + i]._currentframe == 4) {
if (rand <= 10) {
this["pad" + i].gotoAndPlay("pink");
}
if ((rand <= 40) && (rand > 10)) {
this["pad" + i].gotoAndPlay("red");
}
if ((rand <= 70) && (rand > 40)) {
this["pad" + i].gotoAndPlay("blue");
}
}
i++;
}
timeleft.text = int(timeleft.text) - 1;
if (int(timeleft.text) == 0) {
gotoAndPlay ("done");
}
Symbol 1481 MovieClip Frame 15
gotoAndPlay ("player");
Symbol 1481 MovieClip Frame 16
stop();