Frame 1
Audio.stop();
stageWidth = 640;
stageHeight = 448;
Stage.showMenu = false;
Frame 2
function PassCode() {
if (((((EncryptionB % 307) != 0) || ((EncryptionA % 7) != 0)) || (EncryptionB == 0)) || (EncryptionA == 0)) {
gotoAndPlay (1);
}
EncryptionA = Math.floor(EncryptionA / 7);
EncryptionB = Math.floor(EncryptionB / 307);
Gold = EncryptionA % 100000;
EncryptionA = Math.floor(EncryptionA / 100000);
MaxWeap = EncryptionA;
Weapon = MaxWeap;
EncryptionA = Math.floor(EncryptionA / 10);
PotionL = EncryptionA % 10;
EncryptionA = Math.floor(EncryptionA / 10);
PotionM = EncryptionA % 10;
EncryptionA = Math.floor(EncryptionA / 10);
PotionS = EncryptionA % 10;
SA = EncryptionB % 100;
Skill1Active = SA % 2;
SA = Math.floor(SA / 2);
Skill2Active = SA % 2;
SA = Math.floor(SA / 2);
Skill3Active = SA % 2;
SA = Math.floor(SA / 2);
Skill4Active = SA % 2;
SA = Math.floor(SA / 2);
Skill5Active = SA % 2;
SA = Math.floor(SA / 2);
Skill6Active = SA % 2;
EncryptionB = Math.floor(EncryptionB / 100);
Location = EncryptionB % 100;
EncryptionB = Math.floor(EncryptionB / 100);
Health = EncryptionB;
if ((5 < Location) || (Skill1Active == 1)) {
BossesBeaten[0] = 1;
}
if ((10 < Location) || (1 < MaxWeap)) {
BossesBeaten[1] = 1;
}
if ((17 < Location) || (Skill2Active == 1)) {
BossesBeaten[2] = 1;
}
if (Skill4Active == 1) {
BossesBeaten[3] = 1;
}
if (3 < MaxWeap) {
BossesBeaten[4] = 1;
}
if (Skill6Active == 1) {
BossesBeaten[5] = 2;
}
if (MaxWeap == 5) {
BossesBeaten[6] = 1;
}
if (((50 < Health) || (50 < Magic)) || (5 < MaxWeap)) {
gotoAndPlay (1);
}
gotoAndPlay(Location);
}
_xscale = 99.8;
_yscale = 99.8;
_quality = "MEDIUM";
Audio = new Sound(this);
Audio.attachSound("Music_Title");
Audio.start(0, 99);
SEffect = new Sound(this);
WeaponType = 1;
MaxWeap = 1;
Health = 50;
Magic = 50;
Gold = 0;
Attacking = false;
Lit = false;
GuidedStrike = getTimer() - 10;
PotionS = 0;
PotionM = 0;
PotionL = 0;
CurrentSkill = 0;
Skill1Active = 0;
Skill2Active = 0;
Skill3Active = 0;
Skill4Active = 0;
Skill5Active = 0;
Skill6Active = 0;
Fireball = 1;
EncryptionA = 0;
EncryptionB = 0;
EventEnded = getTimer() - 1000;
BossesBeaten = [0, 0, 0, 0, 0, 0, 0];
CutscenesWatched = [0, 0, 0, 0, 0, 0, 0, 0, 0];
travelling = "forward";
tileW = 32;
tileH = 32;
startX = 90;
startY = 0;
visAreaX = 17;
visAreaY = 14;
map_forest_1 = [[10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 12, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [10, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 52, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [10, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 13, 13, 13, 13, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [10, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 0, 0, 0, 0, 12, 12, 13, 0, 0, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [10, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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[10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 12, 0, 0, 0, 53, 0, 0, 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 3, 13, 13, 13, 0, 6, 56, 0, 0, 0, 0, 0, 0, 0, 0, 101], [10, 0, 0, 0, 0, 0, 500, 0, 0, 0, 0, 0, 0, 6, 0, 13, 13, 12, 12, 13, 13, 0, 0, 0, 0, 0, 0, 0, 54, 3, 3, 0, 0, 6, 13, 13, 12, 12, 12, 13, 13, 13, 0, 0, 6, 0, 6, 0, 59, 13, 13], [10, 17, 17, 17, 17, 17, 13, 13, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 12, 12]];
map_forest_2 = [[12, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 0, 12, 12, 0, 0, 0, 12, 12], [12, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 0, 3, 3, 0, 0, 0, 12, 12], [12, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 0, 3, 3, 0, 0, 0, 12, 12], [12, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 0, 13, 13, 0, 0, 0, 12, 12], [100, 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 3, 3, 0, 0, 13, 0, 0, 12, 12, 0, 0, 0, 12, 12], [100, 0, 0, 0, 0, 3, 3, 0, 0, 0, 54, 13, 13, 0, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 102], [13, 0, 0, 0, 13, 13, 13, 0, 0, 0, 13, 12, 12, 0, 0, 0, 0, 0, 12, 12, 0, 0, 0, 6, 102], [12, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 0, 12, 12, 0, 0, 0, 13, 13], [12, 13, 0, 0, 0, 12, 12, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 0, 12, 12, 0, 0, 0, 12, 12], [12, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, 0, 12, 12, 0, 0, 0, 12, 12], [12, 0, 0, 0, 13, 12, 12, 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 0, 12, 12, 0, 0, 0, 12, 12], [12, 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 0, 3, 3, 0, 0, 0, 12, 12], [12, 13, 0, 6, 0, 3, 3, 0, 50, 6, 0, 13, 13, 0, 0, 51, 6, 0, 3, 3, 52, 6, 0, 12, 12], [12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 12, 12]];
map_forest_3 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 50, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 0, 0, 0, 0, 12], [12, 13, 13, 13, 13, 13, 13, 13, 12, 13, 13, 13, 13, 13, 13, 13, 12]];
map_forest_4 = [[12, 12, 12, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [12, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [12, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 132, 0, 0, 0, 0, 0, 0, 0, 0, 12], [101, 0, 0, 0, 0, 0, 13, 13, 13, 0, 0, 0, 0, 0, 0, 0, 12], [101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [13, 0, 0, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 104], [12, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 104], [12, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13], [12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 12]];
map_Kinver = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 106], [15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 106], [14, 14, 15, 15, 15, 15, 200, 200, 200, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 51, 0, 0, 0, 0, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 106], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 14, 14, 14, 14, 15, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 0, 0, 15, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 53, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14], [14, 14, 14, 0, 0, 4, 14, 14, 4, 4, 4, 14, 14, 0, 0, 0, 0, 0, 0, 0, 15, 15, 14, 14, 14, 15, 15, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 14], [14, 14, 0, 0, 0, 4, 4, 4, 4, 4, 4, 14, 14, 15, 0, 0, 0, 0, 15, 15, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 15, 15, 15, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 15, 14, 14], [14, 0, 0, 0, 0, 4, 4, 4, 4, 4, 4, 4, 4, 4, 0, 0, 0, 15, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 15, 15, 14, 14, 14, 15, 15, 0, 7, 0, 0, 0, 0, 0, 15, 15, 15, 14, 14, 14], [14, 0, 0, 0, 0, 15, 15, 15, 4, 4, 4, 4, 4, 4, 0, 0, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 15, 14, 14, 4, 4, 4, 4, 14, 15, 15, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14], [14, 15, 0, 0, 0, 4, 4, 14, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 0, 0, 0, 14, 14, 0, 0, 0, 0, 4, 4, 4, 4, 4, 4, 4, 4, 14, 0, 0, 0, 0, 0, 0, 7, 0, 14, 14, 14], [14, 14, 15, 15, 0, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 14, 15, 0, 0, 0, 4, 4, 4, 4, 4, 4, 4, 4, 14, 15, 0, 0, 0, 0, 0, 54, 0, 0, 0, 14], [14, 14, 14, 14, 15, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 0, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 4, 4, 4, 4, 4, 4, 4, 14, 14, 0, 0, 0, 0, 0, 7, 0, 0, 0, 106], [14, 14, 14, 14, 14, 200, 200, 15, 15, 200, 200, 15, 15, 4, 4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 14, 4, 4, 4, 4, 4, 4, 4, 14, 14, 15, 0, 0, 0, 0, 7, 0, 0, 0, 106], [14, 14, 14, 14, 14, 202, 202, 14, 14, 14, 14, 14, 14, 15, 4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 14, 14, 15, 200, 200, 200, 15, 4, 4, 4, 4, 0, 0, 0, 0, 0, 7, 0, 0, 0, 106], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 0, 0, 0, 0, 15, 15, 15, 15, 0, 0, 0, 15, 14, 14, 14, 14, 202, 202, 202, 14, 4, 4, 4, 4, 0, 0, 0, 15, 15, 15, 15, 0, 0, 106], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 14, 14, 14, 14, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 15, 15, 15]];
map_swamp_2 = [[14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 107], [14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 54, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 0, 0, 0, 0, 0, 107], [105, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 50, 0, 0, 0, 0, 0, 0, 0, 0, 51, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 0, 0, 107], [105, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 14, 15, 4, 4, 0, 0, 107], [105, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 0, 0, 15, 15, 0, 0, 15, 15, 14, 14, 15, 4, 4, 0, 107], [15, 15, 15, 15, 15, 15, 200, 200, 200, 15, 14, 14, 14, 15, 15, 0, 0, 0, 0, 0, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 15, 14, 14, 14, 15, 15, 14, 14, 15, 15, 14, 14, 14, 4, 4, 4, 4, 4, 15], [14, 14, 14, 14, 14, 14, 202, 202, 202, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 15, 14, 14, 14, 15, 0, 0, 0, 0, 0, 0, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 4, 4, 4, 4, 4, 15, 14], [14, 14, 14, 14, 14, 14, 202, 202, 202, 14, 14, 14, 14, 14, 14, 15, 0, 0, 0, 14, 14, 14, 14, 14, 15, 15, 15, 0, 0, 15, 14, 14, 14, 14, 14, 0, 0, 14, 14, 14, 0, 0, 4, 4, 4, 4, 4, 4, 14, 14], [14, 14, 4, 0, 0, 14, 14, 202, 202, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 14, 14, 0, 0, 0, 7, 0, 0, 0, 0, 57, 0, 0, 4, 4, 4, 4, 4, 15, 14, 14], [14, 14, 4, 0, 0, 0, 14, 202, 202, 202, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 7, 0, 0, 0, 7, 0, 0, 0, 0, 7, 0, 4, 4, 4, 4, 4, 4, 14, 14, 14], [14, 4, 4, 4, 0, 0, 14, 202, 202, 202, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 55, 0, 0, 0, 56, 0, 0, 0, 15, 15, 4, 4, 4, 4, 4, 15, 15, 14, 14, 14], [14, 4, 4, 4, 0, 0, 14, 14, 202, 202, 14, 14, 14, 14, 0, 0, 0, 0, 7, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 7, 0, 0, 0, 7, 0, 0, 4, 4, 4, 4, 4, 4, 4, 15, 14, 14, 14, 14, 14], [14, 4, 4, 15, 200, 200, 200, 14, 202, 202, 14, 14, 7, 0, 0, 0, 0, 0, 7, 0, 14, 14, 14, 14, 14, 14, 4, 4, 15, 15, 15, 0, 0, 0, 7, 0, 4, 4, 4, 4, 4, 4, 15, 15, 14, 14, 14, 14, 14, 14], [14, 4, 4, 14, 202, 202, 202, 202, 202, 202, 14, 0, 7, 0, 0, 0, 15, 0, 53, 0, 0, 14, 14, 14, 14, 14, 4, 4, 4, 4, 4, 4, 4, 15, 15, 15, 4, 4, 4, 4, 4, 4, 14, 14, 14, 14, 14, 14, 14, 14], [14, 4, 4, 14, 14, 202, 202, 202, 202, 202, 14, 0, 52, 0, 0, 0, 0, 0, 7, 0, 0, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14], [14, 4, 4, 4, 14, 14, 14, 14, 14, 14, 14, 0, 7, 0, 15, 0, 0, 0, 15, 0, 0, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [14, 4, 4, 4, 4, 4, 4, 4, 4, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 15, 4, 4, 15, 15, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [14, 4, 4, 4, 4, 4, 4, 4, 4, 4, 0, 0, 15, 200, 200, 200, 200, 200, 200, 200, 200, 14, 15, 15, 14, 14, 15, 15, 15, 200, 200, 15, 15, 200, 200, 200, 200, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [14, 15, 15, 200, 200, 200, 200, 15, 15, 15, 15, 15, 14, 14, 202, 202, 202, 202, 202, 202, 202, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14]];
map_swamp_3 = [[14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [14, 14, 14, 0, 7, 0, 0, 14, 14, 14, 0, 0, 7, 0, 14, 14, 14], [14, 14, 4, 0, 7, 0, 0, 0, 7, 0, 0, 0, 7, 0, 4, 14, 14], [14, 4, 4, 0, 7, 0, 0, 0, 7, 0, 0, 0, 7, 0, 4, 4, 14], [14, 4, 4, 0, 7, 0, 0, 0, 0, 0, 0, 0, 7, 0, 4, 4, 14], [14, 4, 4, 0, 7, 0, 0, 0, 52, 0, 0, 0, 7, 0, 4, 4, 14], [14, 4, 4, 0, 50, 0, 0, 0, 0, 0, 0, 0, 51, 0, 4, 4, 14], [14, 4, 0, 0, 7, 0, 0, 0, 7, 0, 0, 0, 7, 0, 0, 4, 14], [14, 15, 0, 0, 7, 0, 0, 0, 7, 0, 0, 0, 7, 0, 0, 15, 14], [14, 14, 0, 0, 7, 0, 0, 0, 7, 0, 0, 0, 7, 0, 0, 14, 14], [14, 14, 15, 15, 15, 200, 200, 200, 15, 200, 200, 200, 15, 15, 15, 14, 14], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14]];
map_Rynn = [[0, 0, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,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0, 5, 5, 5, 5, 0, 0, 0, 11, 11, 11, 0, 0, 0, 0, 0, 0, 0, 5, 5, 5, 5, 5, 0, 0, 0, 0, 0, 0, 5, 5, 5, 0, 0, 0, 0, 11, 0, 0, 0, 0], [0, 0, 0, 0, 11, 0, 0, 0, 0, 0, 5, 5, 5, 5, 0, 0, 11, 5, 5, 5, 0, 0, 0, 0, 0, 0, 11, 11, 5, 5, 5, 5, 0, 0, 132, 0, 0, 0, 5, 5, 5, 0, 0, 0, 0, 11, 0, 0, 0, 0], [0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 5, 5, 5, 5, 0, 11, 5, 5, 5, 5, 0, 0, 0, 0, 0, 0, 5, 5, 5, 5, 5, 5, 0, 11, 11, 11, 0, 0, 5, 5, 5, 0, 0, 0, 0, 5, 0, 0, 0, 109], [106, 0, 0, 0, 5, 0, 0, 0, 0, 0, 5, 5, 11, 11, 11, 5, 5, 5, 5, 5, 0, 0, 0, 0, 0, 0, 5, 5, 5, 5, 11, 11, 11, 5, 5, 5, 0, 0, 5, 5, 5, 0, 0, 0, 0, 5, 0, 0, 0, 109], [106, 0, 0, 0, 5, 0, 0, 0, 0, 0, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 0, 0, 0, 0, 0, 0, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 0, 0, 5, 5, 5, 0, 0, 0, 0, 5, 0, 0, 0, 109], [106, 0, 0, 0, 5, 0, 0, 0, 0, 11, 11, 5, 5, 5, 5, 5, 5, 5, 5, 5, 0, 0, 0, 139, 0, 11, 11, 11, 5, 5, 5, 5, 5, 5, 5, 5, 0, 0, 5, 5, 5, 0, 0, 138, 0, 5, 0, 0, 0, 109], [17, 17, 17, 17, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 17, 17, 17, 17], [0, 0, 0, 0, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 0, 0, 0, 0], [200, 200, 200, 200, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 200, 200, 200, 200]];
map_Crossroads = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 113, 113, 113, 113, 113, 113], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 113], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 113], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 13, 0, 0, 0, 0, 0, 0, 6, 0, 13], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 12, 0, 0, 0, 0, 13, 13, 13, 13, 12], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 12, 3, 0, 0, 0, 3, 12, 12, 12, 12], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 12, 13, 13, 0, 0, 0, 12, 12, 12, 12], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 0, 0, 12, 12, 12, 12], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 3, 13, 12, 12, 12, 12], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 13, 12, 12, 12, 12, 12], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 13, 12, 12, 12, 12, 12, 12], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 13, 13, 12, 12, 12, 12, 12, 12, 12], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 12], [108, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 12, 12, 12, 12, 12, 12], [108, 0, 0, 0, 0, 0, 0, 0, 0, 13, 13, 13, 0, 6, 3, 3, 3, 3, 3, 3, 3, 0, 12, 12, 12], [108, 0, 0, 0, 0, 0, 6, 0, 13, 12, 12, 12, 13, 13, 13, 3, 3, 3, 3, 0, 0, 0, 0, 0, 110], [108, 0, 0, 0, 0, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 13, 3, 3, 0, 0, 0, 0, 0, 0, 110], [108, 0, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 3, 0, 0, 0, 0, 0, 0, 110], [13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 0, 6, 0, 0, 13, 13, 13], [12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 12, 12, 12]];
map_plains_1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0,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, 3, 3, 3, 3, 0, 0, 6, 0, 13, 12, 12], [109, 0, 0, 0, 0, 3, 3, 3, 3, 3, 3, 0, 0, 13, 13, 13, 13, 13, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 13, 13, 12, 12, 13, 0, 6, 0, 0, 0, 0, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 202, 202, 202, 202, 12, 12, 12, 13, 3, 3, 3, 3, 3, 3, 3, 13, 13, 12, 12, 12], [109, 0, 6, 0, 0, 13, 13, 13, 13, 3, 3, 0, 13, 12, 12, 12, 12, 12, 13, 13, 3, 3, 3, 3, 3, 13, 13, 13, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 3, 3, 3, 3, 13, 12, 12, 12, 12, 12], [13, 13, 13, 13, 13, 12, 12, 12, 12, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12]];
map_plains_2 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 112], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 0, 0, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 202, 202, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 3, 3, 3, 3, 0, 0, 112], [110, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 51, 0, 0, 3, 3, 3, 0, 0, 0, 0, 0, 6, 0, 13, 13, 13, 13, 13, 13, 13, 200, 200, 200, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 202, 202, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13], [110, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 6, 0, 13, 13, 13, 200, 200, 200, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [110, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 3, 3, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 202, 202, 202, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [110, 0, 0, 6, 0, 0, 0, 0, 13, 13, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 202, 202, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [13, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12]];
map_Pecal_1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 118], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 118], [111, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 5, 0, 0, 5, 5, 5, 5, 0, 0, 5, 5, 5, 0, 0, 118], [13, 13, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 17, 17, 17, 17, 17, 17, 17, 17, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 17, 17, 17, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13], [12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 200, 200, 200, 200, 200, 200, 200, 200, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 200, 200, 200, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12]];
map_Pecal_1D = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [111, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [111, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 0, 0], [111, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 0, 0], [111, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 11, 11, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0], [111, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 11, 11, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 0, 0], [111, 0, 0, 0, 0, 0, 0, 5, 5, 0, 0, 11, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0], [111, 0, 0, 0, 0, 0, 0, 5, 5, 0, 0, 11, 11, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0], [111, 0, 0, 0, 0, 0, 142, 5, 5, 0, 0, 5, 5, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0], [111, 0, 0, 0, 0, 11, 11, 11, 11, 0, 0, 5, 5, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 0, 0], [111, 0, 0, 0, 0, 5, 5, 5, 5, 0, 0, 5, 5, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 0, 0], [111, 0, 13, 13, 0, 5, 5, 5, 5, 0, 0, 5, 5, 0, 0, 132, 0, 0, 0, 0, 0, 11, 11, 0, 0], [13, 13, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 17, 17, 17, 17, 17, 17, 17, 17, 13, 13, 0, 0], [12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 200, 200, 200, 200, 200, 200, 200, 200, 12, 12, 200, 200]];
map_Pecal_2 = [[112, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 119], [112, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 119], [112, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,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 0, 0, 0, 0, 54, 5, 5, 5, 5, 5, 0, 0, 5, 0, 5, 5, 0, 0, 0, 0, 5, 5, 0, 0, 0, 5, 5, 5, 0, 0, 0, 0, 5, 0, 0, 5, 0, 0, 0, 0, 0, 5, 0, 5, 11, 0, 0, 59, 0, 0, 5, 5, 5, 0, 0, 0, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 0, 5, 5, 0, 0, 0, 0, 0, 0, 62, 5, 5, 5, 0, 0, 0, 0, 0, 5, 5, 5, 0, 0, 0, 0, 120], [118, 0, 5, 5, 5, 0, 0, 0, 0, 5, 5, 5, 11, 11, 11, 11, 11, 11, 11, 5, 5, 0, 0, 0, 52, 0, 0, 5, 5, 5, 5, 0, 0, 0, 0, 11, 11, 11, 11, 5, 5, 0, 0, 0, 0, 5, 5, 5, 0, 0, 0, 0, 5, 5, 0, 0, 0, 5, 56, 5, 5, 5, 0, 0, 0, 0, 5, 5, 5, 0, 58, 0, 0, 0, 5, 0, 0, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 0, 0, 0, 5, 5, 0, 0, 0, 11, 11, 11], [13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 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, 5, 5, 5, 0, 0, 0, 0, 66, 0, 0, 0, 5, 5, 5, 0, 0, 5, 5, 5, 5, 5, 0, 0, 11, 0, 0, 11, 0, 0, 11, 5, 5, 5, 11, 0, 0, 68, 0, 0, 0, 0, 0, 0, 0, 0, 0, 145, 0, 0, 11, 11], [0, 0, 0, 0, 0, 132, 0, 5, 5, 0, 0, 0, 50, 11, 11, 11, 0, 0, 51, 0, 5, 0, 5, 0, 0, 0, 0, 11, 11, 5, 0, 0, 5, 5, 5, 0, 0, 11, 0, 5, 5, 11, 11, 11, 11, 0, 54, 0, 0, 5, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 11, 11, 11, 11, 0, 0, 0, 0, 0, 0, 59, 0, 0, 11, 11, 0, 5, 0, 5, 0, 0, 0, 61, 0, 0, 0, 0, 5, 5, 5, 0, 0, 0, 0, 5, 11, 0, 0, 5, 11, 5, 0, 0, 0, 11, 0, 0, 65, 0, 0, 5, 5, 5, 11, 11, 11, 11, 11, 11, 0, 0, 5, 5, 5, 0, 0, 11, 11, 11, 5, 5, 67, 0, 11, 0, 0, 11, 0, 0, 11, 5, 5, 5, 11, 0, 0, 11, 11, 11, 0, 0, 0, 0, 0, 0, 0, 145, 0, 0, 11, 11], [11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,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, 12, 12, 12, 12, 0, 0, 3, 3, 13, 3, 3, 3, 3, 0, 0, 0, 3, 3, 3, 13, 3, 3, 3, 3, 0, 0, 0, 0, 0, 3, 3, 13, 13, 13, 13, 0, 0, 0, 3, 3, 0, 0, 3, 3, 3, 3, 3, 3, 3, 0, 64, 0, 3, 3, 3, 0, 0, 0, 12, 12, 12], [109, 0, 0, 0, 0, 3, 3, 3, 13, 12, 12, 12, 12, 0, 0, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 3, 3, 3, 12, 3, 3, 3, 3, 0, 0, 0, 0, 0, 3, 3, 12, 12, 12, 12, 0, 0, 0, 3, 3, 0, 3, 3, 3, 3, 3, 3, 3, 3, 13, 0, 0, 3, 3, 3, 0, 0, 0, 12, 12, 12], [109, 0, 0, 0, 0, 3, 3, 3, 12, 12, 12, 12, 12, 0, 0, 3, 3, 3, 3, 3, 13, 13, 0, 52, 3, 3, 3, 13, 12, 13, 3, 3, 3, 0, 0, 0, 0, 0, 3, 3, 12, 12, 12, 12, 13, 0, 3, 3, 3, 3, 3, 3, 13, 13, 3, 3, 13, 13, 12, 13, 0, 3, 3, 3, 0, 0, 0, 12, 12, 12], [109, 0, 0, 0, 0, 3, 3, 13, 12, 12, 12, 12, 12, 0, 60, 3, 3, 3, 3, 3, 12, 12, 13, 0, 3, 3, 3, 12, 12, 12, 3, 3, 3, 0, 62, 0, 0, 54, 3, 13, 12, 12, 12, 12, 12, 0, 3, 3, 3, 3, 3, 3, 12, 12, 13, 13, 12, 12, 12, 12, 13, 13, 3, 3, 3, 0, 13, 12, 12, 12], [13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 13, 13, 13, 13, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 12, 12, 12, 12]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 3, 3, 3, 0, 13, 0, 0, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 3, 13, 13, 0, 0, 0, 13, 12, 12], [12, 12, 12, 12, 13, 0, 3, 3, 3, 3, 0, 0, 13, 13, 0, 0, 3, 3, 3, 12, 12, 3, 3, 0, 13, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 13, 12, 0, 0, 0, 13, 13, 13, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 12, 3, 3, 3, 12, 12, 12], [12, 12, 12, 12, 12, 13, 3, 3, 3, 3, 0, 3, 3, 3, 0, 0, 3, 3, 3, 12, 12, 3, 3, 0, 12, 12, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 12, 12, 0, 0, 0, 0, 12, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 12, 12, 12], [12, 12, 12, 12, 12, 12, 13, 3, 3, 3, 0, 3, 3, 3, 3, 51, 3, 13, 13, 12, 12, 13, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 12, 12, 13, 0, 0, 0, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 12, 12, 12], [12, 12, 12, 12, 12, 12, 12, 3, 3, 3, 3, 3, 3, 3, 3, 0, 13, 12, 12, 12, 12, 12, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 13, 12, 12, 12, 0, 0, 3, 3, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 13, 12, 12, 12], [12, 12, 12, 12, 12, 12, 12, 13, 13, 3, 3, 3, 3, 3, 3, 3, 12, 12, 12, 12, 12, 12, 13, 3, 3, 3, 3, 3, 0, 62, 0, 0, 0, 0, 0, 53, 0, 0, 0, 63, 0, 3, 12, 12, 12, 12, 13, 3, 3, 3, 3, 3, 3, 0, 65, 0, 0, 0, 0, 0, 0, 0, 55, 0, 0, 3, 12, 12, 12, 12], [12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 12]];
map_highlands_3 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 60, 0, 0, 0, 0, 0, 0, 12], [12, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 0, 0, 13, 0, 0, 0, 0, 0, 0, 12], [12, 13, 13, 13, 13, 13, 13, 12, 13, 13, 13, 13, 13, 12, 13, 13, 13, 13, 13, 13, 12]];
map_BMK_1 = [[10, 10, 10, 10, 10, 10, 10, 10, 125, 125, 125, 125, 125, 125, 125, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 13, 13], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 12], [10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 12], [10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 12], [117, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 12], [117, 1, 1, 1, 1, 1, 1, 1, 16, 16, 16, 1, 1, 1, 1, 1, 1, 1, 1, 1, 16, 16, 16, 1, 1, 1, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 12], [117, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 132, 0, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114], [10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13], [10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 16, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 16, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12], [10, 10, 10, 10, 10, 10, 10, 10, 122, 122, 122, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12]];
map_BMK_2 = [[10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 10, 10, 10, 10, 0, 0, 0, 1, 0, 0, 0, 1, 0, 116], [10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 0, 10, 10, 0, 10, 10, 0, 1, 0, 0, 0, 1, 0, 0, 0, 10, 10, 10], [10, 10, 10, 10, 10, 10, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 10, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 10, 10, 10], [10, 10, 10, 10, 10, 10, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 10, 10, 10, 10, 0, 0, 1, 0, 0, 0, 1, 0, 0, 10, 10, 10, 10], [10, 10, 10, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 81, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 10, 10, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 10, 10, 10, 10], [10, 10, 10, 0, 10, 10, 0, 10, 10, 10, 10, 10, 10, 0, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 10, 10, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 10, 10, 10, 10, 10], [10, 10, 10, 0, 10, 10, 0, 10, 10, 10, 10, 10, 10, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 10, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 10, 10, 10, 10, 10], [10, 0, 0, 0, 10, 10, 0, 0, 0, 10, 10, 10, 10, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 0, 10, 10, 10, 10, 0, 1, 0, 0, 0, 10, 0, 0, 0, 1, 10, 10, 10, 10, 10, 10], [10, 0, 10, 10, 10, 10, 10, 10, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 10, 10, 10, 10, 10, 10, 0, 10, 10, 10, 0, 10, 10, 10, 10, 10, 10, 10, 0, 10, 10, 10, 10, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 10, 10, 10, 10, 10, 10], [10, 0, 10, 10, 10, 10, 10, 10, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 10, 10, 10, 10, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 10, 10, 10, 0, 10, 10, 0, 0, 0, 1, 0, 10, 0, 1, 0, 0, 0, 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, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10], [10, 0, 1, 0, 0, 0, 1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 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 10, 1, 1, 1, 1, 1, 1, 10, 10, 10], [10, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 10, 10, 10, 0, 1, 0, 0, 0, 1, 0, 10, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 10, 10, 1, 1, 1, 1, 1, 1, 10, 10, 10], [10, 0, 1, 0, 131, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 10, 10, 0, 0, 0, 1, 0, 0, 0, 1, 0, 10, 10, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 10, 10, 0, 1, 0, 10, 0, 1, 0, 0, 0, 10, 10, 1, 1, 1, 1, 1, 1, 10, 10, 10], [10, 0, 1, 10, 10, 10, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 10, 10, 10, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 10, 10, 10, 0, 1, 0, 10, 0, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10], [10, 0, 10, 10, 10, 10, 10, 0, 50, 0, 1, 0, 0, 10, 10, 0, 51, 0, 1, 0, 0, 0, 1, 0, 0, 52, 1, 0, 10, 10, 10, 10, 10, 0, 1, 0, 0, 0, 1, 53, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 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]];
map_BMK_1B = [[10, 116, 116, 116, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 1, 1, 16, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 1, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 16, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 1, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 1, 1, 16, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 1, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 16, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 1, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 146, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 1, 1, 16, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 16, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 1, 1, 1, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 16, 1, 1, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 1, 1, 1, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 1, 1, 16, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 16, 1, 1, 1, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 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, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 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, 1, 1, 16, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 10, 10, 10, 10, 10, 10, 201, 201, 201, 201, 201, 201, 201, 201, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 10, 10, 10, 10, 10, 10, 10, 203, 203, 203, 203, 203, 203, 203, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 16, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 203, 203, 203, 203, 203, 203, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 1, 1, 16, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 16, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 1, 1, 16, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 16, 1, 1, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 16, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 1, 1, 1, 1, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 16, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 16, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 16, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 16, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 1, 1, 1, 1, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 16, 16, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 1, 1, 1, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 1, 1, 16, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 16, 16, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 1, 1, 1, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 16, 1, 1, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 16, 16, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 1, 1, 1, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 1, 1, 16, 10], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 1, 1, 1, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, 10, 10, 10, 10, 10, 16, 1, 1, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 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, 1, 1, 1, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 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, 1, 1, 16, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 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, 1, 1, 1, 10], [10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 16, 1, 1, 10], [10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10], [10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 16, 10], [10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10], [10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 16, 1, 1, 10], [10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 10, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 201, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 10, 10, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 10, 10, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 10, 10, 10, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, 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, 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]];
map_BMK_2B = [[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,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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, 131, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 16, 16, 16, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 16, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10]];
map_BMK_3B = [[10, 116, 116, 116, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [10, 16, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [10, 1, 1, 1, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [10, 1, 1, 16, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 16, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 1, 1, 16, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0], [10, 16, 1, 1, 1, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0], [10, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0], [10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 16, 1, 1, 1, 10, 10, 10], [10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 16, 1, 1, 1, 10, 10, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 16, 1, 1, 1, 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, 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]];
map_BMK_3 = [[10, 10, 10, 10, 127, 127, 127, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [10, 0, 0, 10, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 52, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 58, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 56, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 206, 206, 206, 206, 206, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 1, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 1, 1, 1, 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, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 10, 10, 10, 10, 10, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 10, 10, 10, 10, 10, 10, 10, 116, 116, 116, 116, 116, 10]];
map_BMK_4 = [[0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10], [0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10], [0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10], [16, 16, 0, 0, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10], [0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10], [0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10], [0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10], [0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10], [0, 0, 0, 0, 10, 10, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10], [0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10], [0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 1, 10, 10, 10], [0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 1, 1, 1, 10, 10], [0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 116, 116, 116, 116, 116, 10]];
map_BMK_5 = [[0, 0, 0, 0, 0, 10, 128, 128, 128, 128, 128, 10, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 10, 1, 1, 1, 1, 1, 10, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 10, 10, 1, 1, 1, 10, 10, 0, 0, 0, 0, 0], [0, 0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1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 1, 10], [10, 1, 1, 1, 1, 1, 0, 1, 50, 1, 0, 1, 1, 1, 1, 1, 10], [10, 1, 1, 1, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 1, 1, 10], [10, 16, 16, 1, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 16, 16, 10], [10, 1, 0, 1, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 10], [10, 1, 1, 1, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 1, 1, 10], [10, 1, 1, 1, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 1, 1, 10], [10, 0, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 1, 0, 10], [10, 206, 206, 206, 206, 1, 0, 1, 1, 1, 0, 1, 206, 206, 206, 206, 10], [10, 10, 10, 10, 10, 1, 1, 16, 16, 16, 1, 1, 10, 10, 10, 10, 10], [10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10], [10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10], [10, 10, 10, 10, 10, 10, 10, 125, 125, 125, 10, 10, 10, 10, 10, 10, 10]];
map_BMK_6 = [[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, 0, 1, 0, 1, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 10], [10, 0, 1, 0, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 0, 1, 0, 10], [10, 0, 1, 0, 1, 1, 1, 0, 0, 1, 1, 0, 50, 0, 1, 1, 0, 0, 1, 1, 1, 0, 1, 0, 10], [10, 0, 1, 0, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1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0, 0, 0, 0, 0, 0, 0, 11, 11, 0, 0, 0, 0, 0, 223], [12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 0, 0, 0, 0, 0, 223], [12, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 5, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 5, 0, 0, 0, 0, 0, 223], [12, 12, 13, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 11, 11, 0, 0, 0, 5, 5, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 5, 0, 0, 0, 0, 0, 223], [12, 12, 12, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 5, 5, 0, 0, 0, 5, 5, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 5, 0, 0, 0, 0, 0, 223], [12, 12, 12, 12, 13, 13, 0, 0, 0, 132, 0, 0, 0, 5, 5, 0, 0, 0, 0, 13, 13, 13, 0, 0, 0, 5, 5, 5, 0, 0, 0, 5, 5, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 148, 0, 0, 0, 5, 5, 0, 0, 0, 0, 0, 223], [12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13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 4, 0, 0, 0, 0, 0, 0, 4, 4, 4, 14, 14, 14, 14, 15, 15, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 0, 0, 0, 0, 0, 0, 0, 14, 14, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 0, 0, 0, 0, 0, 224], [222, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 50, 0, 4, 4, 4, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 4, 4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 0, 4, 4, 4, 0, 0, 0, 0, 0, 4, 4, 4, 4, 4, 4, 14, 14, 14, 15, 0, 0, 0, 0, 0, 4, 4, 0, 0, 0, 0, 0, 63, 0, 0, 4, 4, 4, 0, 0, 0, 0, 0, 57, 0, 14, 14, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 0, 0, 0, 0, 0, 224], [222, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 4, 0, 0, 0, 0, 52, 0, 0, 0, 0, 4, 4, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 4, 4, 4, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 4, 4, 4, 14, 14, 15, 0, 0, 0, 0, 4, 4, 4, 0, 0, 15, 15, 15, 15, 4, 4, 4, 4, 4, 0, 0, 0, 0, 15, 15, 14, 14, 14, 14, 15, 15, 0, 0, 0, 0, 0, 0, 4, 4, 4, 0, 0, 0, 0, 224], [222, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 0, 4, 4, 4, 0, 0, 0, 0, 53, 0, 0, 4, 4, 4, 4, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 4, 4, 0, 0, 0, 55, 0, 0, 4, 4, 4, 4, 4, 4, 4, 14, 14, 14, 0, 56, 0, 0, 4, 4, 15, 15, 15, 14, 14, 14, 14, 15, 15, 15, 4, 4, 0, 0, 0, 15, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 0, 0, 0, 0, 4, 4, 4, 0, 0, 0, 0, 224], [15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15]];
map_Mists_2 = [[223, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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 0, 0, 0, 0, 0, 225], [223, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 0, 0, 60, 14, 14, 14, 14, 0, 0, 0, 0, 4, 4, 0, 0, 14, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 0, 4, 4, 4, 0, 0, 0, 0, 14, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 62, 0, 0, 0, 0, 4, 4, 0, 0, 14, 14, 14, 15, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 14, 14, 14, 0, 0, 0, 4, 4, 4, 4, 0, 15, 14, 14, 14, 14, 14, 15, 15, 15, 0, 0, 0, 0, 225], [223, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 0, 15, 15, 14, 14, 14, 14, 15, 0, 52, 4, 4, 4, 0, 0, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 14, 15, 0, 0, 0, 4, 4, 4, 4, 0, 0, 15, 14, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 0, 0, 15, 14, 14, 14, 14, 14, 15, 0, 0, 0, 4, 4, 4, 4, 0, 14, 14, 14, 14, 15, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 14, 14, 14, 15, 63, 0, 4, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 225], [223, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 0, 0, 0, 0, 0, 50, 14, 14, 14, 15, 0, 0, 0, 51, 0, 0, 4, 4, 4, 4, 15, 15, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 15, 15, 0, 53, 0, 0, 15, 15, 14, 14, 0, 61, 4, 4, 4, 4, 4, 0, 15, 14, 14, 15, 15, 0, 0, 0, 54, 0, 4, 4, 4, 4, 15, 15, 14, 14, 14, 14, 14, 14, 14, 0, 4, 4, 4, 4, 4, 15, 15, 14, 14, 14, 14, 14, 15, 0, 55, 0, 0, 4, 4, 4, 4, 15, 15, 14, 14, 14, 14, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15], [15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14]];
map_Mists_3 = [[14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0], [14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 226], [14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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 0, 0, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15], [14, 14, 15, 15, 0, 151, 50, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14], [14, 14, 14, 14, 15, 15, 15, 0, 0, 0, 0, 0, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0], [14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 14, 0, 0, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 15, 15, 14, 14, 14, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 14, 14, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 206, 206, 206, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 14, 14, 14, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 14, 14, 14, 14, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 15, 15, 15, 15, 0, 0, 0, 0, 15, 15, 15, 15, 0, 0, 0, 0, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 0, 0, 0, 0, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 206, 206, 206, 206, 206, 206, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 206, 206, 206, 206, 14, 14, 14, 14, 206, 206, 206, 206, 14, 14, 14, 14, 206, 206, 206, 206, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 81, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10], [224, 0, 0, 0, 0, 0, 152, 0, 0, 0, 132, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10], [224, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 80, 0, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 0, 0, 0, 0, 0, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 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, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10], [15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 14, 14, 14, 14, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 10, 10, 10, 10, 10, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 10, 10, 10, 10, 10, 10, 10], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 10, 10], [14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 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, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 52, 0, 0, 0, 51, 0, 0, 0, 50, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 8, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 0, 0, 70, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 69, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 55, 0, 0, 0, 0, 0, 0, 54, 0, 0, 0, 0, 0, 53, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 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, 10, 10, 10, 10, 10, 1, 1, 10, 10, 206, 206, 206, 206, 206, 206, 206, 10, 10, 1, 1, 1, 1, 1, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 0, 0, 0, 10, 0, 0, 0, 8, 0, 0, 0, 8, 0, 0, 0, 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, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 1, 1, 1, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 8, 0, 10, 0, 8, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 0, 0, 0, 10, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 56, 0, 0, 0, 57, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 10, 10, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 206, 206, 206, 206, 206, 206, 206, 10, 10, 10, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 0, 0, 0, 10, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 10, 10, 10, 10, 0, 0, 10, 10, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 8, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 1, 1, 1, 1, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 71, 0, 0, 0, 0, 0, 68, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 1, 1, 1, 1, 0, 0, 58, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 67, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 0, 0, 65, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 10, 10, 0, 0, 8, 0, 0, 0, 10, 10, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 0, 0, 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, 0, 0, 10, 0, 0, 10, 10, 0, 62, 0, 0, 61, 0, 10, 10, 0, 0, 0, 0, 0, 0, 10, 10, 1, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 0, 0, 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, 0, 0, 10, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 60, 0, 0, 59, 0, 10, 10, 1, 1, 10, 10, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 10, 10, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 0, 0, 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, 0, 0, 10, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 10, 10], [10, 10, 10, 10, 10, 10, 10, 0, 0, 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, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 10, 10], [227, 0, 0, 0, 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, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 201, 201, 201, 201, 10, 10, 201, 201, 201, 201, 10, 10, 201, 201, 201, 201, 10, 10, 10, 10, 10, 10], [227, 0, 0, 0, 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, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 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, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [227, 0, 0, 0, 0, 0, 8, 0, 0, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 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, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10], [227, 0, 0, 0, 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, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 63, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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, 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, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]];
map_MistKeep_2 = [[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, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 226], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 226], [10, 0, 0, 0, 57, 0, 0, 0, 0, 0, 0, 56, 0, 55, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 226], [10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 226], [10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10], [10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 50, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10], [10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 10, 10, 10, 10], [10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 0, 54, 0, 0, 0, 0, 0, 0, 0, 0, 51, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 8, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 10, 0, 0, 8, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 0, 0, 0], [10, 10, 10, 0, 0, 0, 10, 0, 0, 0, 0, 0, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 10, 10, 0, 0, 0, 10, 10, 0, 0, 0, 10, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 0, 8, 0, 10, 0, 0, 0, 0, 0, 0, 52, 0, 0, 0, 0, 0, 0, 0, 0, 0, 53, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 8, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 10, 10, 0, 0, 58, 0, 0, 59, 0, 0, 10, 10, 10, 0, 0, 0, 10, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 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, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 63, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 65, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 0, 0, 60, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 228, 0, 0, 0, 0, 0, 0, 0, 10, 0, 8, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 228, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 228, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 10, 10, 0, 0, 0, 228, 0, 0, 0, 0, 0, 0, 0, 10,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0, 0, 0], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 149, 0, 0, 0, 0, 0, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 16, 16, 16, 0, 0, 0, 0, 10, 0, 0, 10, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 62, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 0, 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, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 10, 10, 10, 0, 0, 0], [10, 0, 0, 0, 0, 61, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 0, 0, 0], [10, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, 10, 0, 0, 0, 0, 69, 0, 0, 0, 0, 0, 0, 70, 0, 0, 0, 0, 0, 71, 0, 0, 0, 0, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 0, 0, 0, 73, 0, 0, 0, 0, 10, 10, 10, 0, 0, 0], [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, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0]];
map_MistKeep_3 = [[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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 0, 0, 0, 0, 0, 0, 0, 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, 10, 10], [10, 10, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 10, 10, 0, 0, 0, 0, 10, 10, 0, 0, 0, 10, 0, 0, 0, 0, 10, 10], [10, 10, 0, 0, 0, 10, 10, 0, 0, 0, 10, 0, 0, 0, 10, 10, 10, 0, 0, 0, 10, 10, 0, 0, 10, 10, 0, 0, 0, 10, 10, 10], [10, 10, 10, 0, 0, 10, 10, 10, 0, 0, 10, 10, 10, 10, 10, 10, 10, 0, 0, 10, 10, 10, 0, 0, 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]];
map_MistKeep_4 = [[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, 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, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 10], [10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 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, 0, 0, 0, 0, 0, 0, 0, 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 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], [10, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 50, 0, 0, 0, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10, 10, 0, 0, 0, 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, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10]];
this.attachMovie("Magic_Regen", "Magic_Regen", 20001);
stop();
Frame 3
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * j) + i));
this.clip["Goblin_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Plains");
Audio.start(0, 99);
BG = 2;
if (travelling == "forward") {
startPos = [2, 12];
}
if (travelling == "back") {
startPos = [45, 12];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_forest_1);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Instance of Symbol 848 MovieClip "BG" in Frame 3
onClipEvent (enterFrame) {
if ((_root._currentframe == 36) && (525 < _root.clip.char.ypos)) {
gotoAndStop (6);
} else {
gotoAndStop(_root.BG);
}
}
Frame 4
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * j) + i));
this.clip["Goblin_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
BG = 2;
Audio.stop();
Audio.attachSound("Music_Plains");
Audio.start(0, 99);
if (travelling == "forward") {
startPos = [2, 12];
}
if (travelling == "back") {
startPos = [23, 6];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_forest_2);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 5
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 5) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Ninja", "Ninja_" + a, 88888 + ((30 * j) + i));
this.clip["Ninja_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Ninja_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Ninja_" + a].placer = a;
}
a++;
}
if ((i == startPos[1]) && (j == startPos[0])) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
}
j++;
}
i++;
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 5) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Ninja", "Ninja_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Ninja_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Ninja_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Ninja_" + a].placer = a;
}
a++;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 5) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Ninja", "Ninja_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Ninja_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Ninja_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Ninja_" + a].placer = a;
}
a++;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 5) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Ninja", "Ninja_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Ninja_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Ninja_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Ninja_" + a].placer = a;
}
a++;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 5) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Ninja", "Ninja_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Ninja_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Ninja_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Ninja_" + a].placer = a;
}
a++;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
BG = 2;
Audio.stop();
Audio.attachSound("Music_Boss");
Audio.start(0, 99);
startPos = [1, 12];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
if (BossesBeaten[0] == 1) {
gotoAndPlay (6);
} else if (CutscenesWatched[1] == 0) {
gotoAndPlay (61);
} else {
buildMap(map_forest_3);
attachMovie("RdyGo", "RdyGo", 21002);
}
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 6
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 5) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * j) + i));
this.clip["Plant_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
a = 5;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * j) + i));
this.clip["Goblin_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if ((i == startPos[1]) && (j == startPos[0])) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
}
j++;
}
i++;
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 5) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Plant_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
a = 5;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 5) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Plant_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
a = 5;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 5) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Plant_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
a = 5;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 5) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Plant_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
a = 5;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
BG = 2;
Audio.stop();
Audio.attachSound("Music_Plains");
Audio.start(0, 99);
startPos = [5, 12];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_forest_4);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 7
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * j) + i));
this.clip["Goblin_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Town");
Audio.start(0, 99);
BG = 2;
if (travelling == "forward") {
startPos = [3, 12];
}
if (travelling == "back") {
startPos = [31, 12];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_Kinver);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 8
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * j) + i));
this.clip["Plant_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Plant_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Plant_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Plant_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Plant_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Swamp");
Audio.start(0, 99);
BG = 3;
if (travelling == "forward") {
startPos = [3, 5];
}
if (travelling == "back") {
startPos = [45, 10];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_swamp_1);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 9
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * j) + i));
this.clip["Plant_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Plant_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Plant_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Plant_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Plant", "Plant_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Plant_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Plant_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Plant_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Swamp");
Audio.start(0, 99);
BG = 3;
if (travelling == "forward") {
startPos = [2, 4];
}
if (travelling == "back") {
startPos = [47, 3];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_swamp_2);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 10
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 2) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SuperPlant_SideKick", "SuperPlant_SideKick_" + a, 88888 + ((30 * j) + i));
this.clip["SuperPlant_SideKick_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SuperPlant_SideKick_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SuperPlant_SideKick_" + a].placer = a;
}
a++;
}
if ((cMap[i][j] == 52) && (_root.active[2] == 0)) {
_root.active[2] = 1;
this.clip.attachMovie("SuperPlant", "SuperPlant_2", 88888 + ((30 * j) + i));
this.clip.SuperPlant_2.xpos = (j * tileW) + (tileW / 2);
this.clip.SuperPlant_2.ypos = (i * tileH) + (tileH / 2);
this.clip.SuperPlant_2.placer = 2;
}
if ((i == startPos[1]) && (j == startPos[0])) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
}
j++;
}
i++;
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SuperPlant_SideKick", "SuperPlant_SideKick_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SuperPlant_SideKick_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SuperPlant_SideKick_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SuperPlant_SideKick_" + a].placer = a;
}
a++;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SuperPlant_SideKick", "SuperPlant_SideKick_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SuperPlant_SideKick_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SuperPlant_SideKick_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SuperPlant_SideKick_" + a].placer = a;
}
a++;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SuperPlant_SideKick", "SuperPlant_SideKick_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SuperPlant_SideKick_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SuperPlant_SideKick_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SuperPlant_SideKick_" + a].placer = a;
}
a++;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SuperPlant_SideKick", "SuperPlant_SideKick_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SuperPlant_SideKick_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SuperPlant_SideKick_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SuperPlant_SideKick_" + a].placer = a;
}
a++;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
Audio.stop();
Audio.attachSound("Music_Boss");
Audio.start(0, 99);
BG = 3;
startPos = [3, 12];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
if (BossesBeaten[1] == 1) {
gotoAndPlay (11);
}
buildMap(map_swamp_3);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 11
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * j) + i));
this.clip["Goblin_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Town");
Audio.start(0, 99);
BG = 2;
if (travelling == "forward") {
startPos = [2, 12];
}
if (travelling == "back") {
startPos = [47, 12];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_Rynn);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 12
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * j) + i));
this.clip["Goblin_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Goblin", "Goblin_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Goblin_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Goblin_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Goblin_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Plains");
Audio.start(0, 99);
BG = 2;
startPos = [10, 13];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_Crossroads);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 13
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * j) + i));
this.clip["Springy_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Plains");
Audio.start(0, 99);
BG = 2;
if (travelling == "forward") {
startPos = [3, 12];
}
if (travelling == "back") {
startPos = [68, 6];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_plains_1);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 14
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * j) + i));
this.clip["Springy_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Plains");
Audio.start(0, 99);
BG = 2;
if (travelling == "forward") {
startPos = [2, 12];
}
if (travelling == "back") {
startPos = [92, 8];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_plains_2);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 15
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * j) + i));
this.clip["Springy_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Pecal");
Audio.start(0, 99);
BG = 4;
if (travelling == "forward") {
startPos = [2, 11];
}
if (travelling == "back") {
startPos = [62, 12];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
if (BossesBeaten[3] == 1) {
gotoAndPlay (24);
}
buildMap(map_Pecal_1);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 16
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * j) + i));
this.clip["Wolf_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * j) + i));
this.clip["WolfWere_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WolfWere_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WolfWere_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WolfWere_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WolfWere_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Plains");
Audio.start(0, 99);
BG = 2;
if (travelling == "forward") {
startPos = [2, 12];
}
if (travelling == "back") {
startPos = [67, 5];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_highlands_1);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 17
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * j) + i));
this.clip["Wolf_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * j) + i));
this.clip["WolfWere_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WolfWere_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WolfWere_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WolfWere_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WolfWere_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Plains");
Audio.start(0, 99);
BG = 5;
if (travelling == "forward") {
startPos = [3, 12];
}
if (travelling == "back") {
startPos = [67, 13];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_highlands_2);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 18
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * j) + i));
this.clip["Wolf_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WereWolf", "WereWolf_" + a, 88888 + ((30 * j) + i));
this.clip["WereWolf_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["WereWolf_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["WereWolf_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WereWolf", "WereWolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WereWolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WereWolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WereWolf_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WereWolf", "WereWolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WereWolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WereWolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WereWolf_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WereWolf", "WereWolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WereWolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WereWolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WereWolf_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WereWolf", "WereWolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WereWolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WereWolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WereWolf_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Boss");
Audio.start(0, 99);
BG = 5;
if (travelling == "forward") {
startPos = [3, 12];
}
if (travelling == "back") {
startPos = [67, 13];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
if (BossesBeaten[2] == 1) {
gotoAndPlay (19);
}
buildMap(map_highlands_3);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 19
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * j) + i));
this.clip["Wolf_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * j) + i));
this.clip["WolfWere_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WolfWere_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WolfWere_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WolfWere_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Wolf", "Wolf_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Wolf_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Wolf_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Wolf_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("WolfWere", "WolfWere_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["WolfWere_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["WolfWere_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["WolfWere_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Keep");
Audio.start(0, 99);
BG = 5;
if (travelling == "forward") {
startPos = [48, 12];
}
if (travelling == "back") {
startPos = [21, 12];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_BMK_1);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 20
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * j) + i));
this.clip["Golem_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * j) + i));
this.clip["SB1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Golem_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Golem_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Golem_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Golem_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Keep");
Audio.start(0, 99);
BG = 6;
if (travelling == "forward") {
startPos = [62, 6];
}
if (travelling == "back") {
startPos = [24, 3];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_BMK_2);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 21
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * j) + i));
this.clip["Skeleton_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Pecal");
Audio.start(0, 99);
BG = 4;
if (travelling == "forward") {
startPos = [2, 11];
}
if (travelling == "back") {
startPos = [67, 12];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_Pecal_2);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 22
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 20) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * j) + i));
this.clip["Skeleton_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Pecal");
Audio.start(0, 99);
BG = 4;
startPos = [2, 13];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_Pecal_3);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 23
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 20) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * j) + i));
this.clip["Skeleton_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
a = 40;
while (a < 45) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("GreenLight", "GreenLight_" + a, 98888 + ((30 * j) + i));
this.clip["GreenLight_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["GreenLight_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["GreenLight_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
a = 40;
while (a < 45) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("GreenLight", "GreenLight_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["GreenLight_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["GreenLight_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["GreenLight_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
a = 40;
while (a < 45) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("GreenLight", "GreenLight_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["GreenLight_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["GreenLight_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["GreenLight_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
a = 40;
while (a < 45) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("GreenLight", "GreenLight_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["GreenLight_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["GreenLight_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["GreenLight_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton", "Skeleton_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton_" + a].placer = a;
}
a++;
}
a = 40;
while (a < 45) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("GreenLight", "GreenLight_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["GreenLight_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["GreenLight_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["GreenLight_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Boss");
Audio.start(0, 99);
BG = 4;
startPos = [6, 13];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
if (CutscenesWatched[3] == 0) {
gotoAndPlay (63);
} else {
buildMap(map_Pecal_4);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
}
stop();
Frame 24
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * j) + i));
this.clip["Springy_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy", "Springy_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Pecal");
Audio.start(0, 99);
BG = 4;
startPos = [2, 11];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_Pecal_1D);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 25
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * j) + i));
this.clip["Golem_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * j) + i));
this.clip["SB1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Golem_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Golem_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Golem_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Golem_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Keep");
Audio.start(0, 99);
BG = 6;
startPos = [2, 2];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
if (Skill6Active == 1) {
gotoAndPlay (27);
}
buildMap(map_BMK_1B);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 26
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Red_Ninja", "Red_Ninja_" + a, 88888 + ((30 * j) + i));
this.clip["Red_Ninja_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Red_Ninja_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Red_Ninja_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * j) + i));
this.clip["SB1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Red_Ninja", "Red_Ninja_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Red_Ninja_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Red_Ninja_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Red_Ninja_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Red_Ninja", "Red_Ninja_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Red_Ninja_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Red_Ninja_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Red_Ninja_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Red_Ninja", "Red_Ninja_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Red_Ninja_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Red_Ninja_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Red_Ninja_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Red_Ninja", "Red_Ninja_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Red_Ninja_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Red_Ninja_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Red_Ninja_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Boss");
Audio.start(0, 99);
BG = 6;
startPos = [13, 14];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_BMK_2B);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 27
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * j) + i));
this.clip["Golem_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * j) + i));
this.clip["SB1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Golem_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Golem_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Golem_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Golem", "Golem_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Golem_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Golem_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Golem_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Keep");
Audio.start(0, 99);
BG = 6;
startPos = [3, 10];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_BMK_3B);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 28
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * j) + i));
this.clip["SB1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * j) + i));
this.clip["SB1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Keep");
Audio.start(0, 99);
BG = 6;
if (travelling == "forward") {
startPos = [111, 11];
}
if (travelling == "back") {
startPos = [5, 5];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
if ((Skill6Active == 0) || (_root.BossesBeaten[4] == 1)) {
gotoAndPlay (29);
}
buildMap(map_BMK_3);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 29
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * j) + i));
this.clip["SB1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * j) + i));
this.clip["SB1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Keep");
Audio.start(0, 99);
BG = 6;
startPos = [10, 12];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_BMK_4);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 30
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * j) + i));
this.clip["SB1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * j) + i));
this.clip["SB1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("down");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SB1", "SB1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SB1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SB1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SB1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Keep");
Audio.start(0, 99);
BG = 5;
startPos = [8, 50];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_BMK_5);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 31
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * j) + i));
this.clip["SEARISSHADE_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * j) + i));
this.clip["SEARISSHADE_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("down");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Boss");
Audio.start(0, 99);
BG = 5;
startPos = [12, 12];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
MaxWeap = 4;
WeaponType = 4;
if (CutscenesWatched[5] == 0) {
gotoAndPlay (65);
} else {
buildMap(map_BMK_6);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
}
stop();
Frame 32
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * j) + i));
this.clip["SEARISSHADE_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * j) + i));
this.clip["SEARISSHADE_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("SEARISSHADE", "SEARISSHADE_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["SEARISSHADE_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["SEARISSHADE_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["SEARISSHADE_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Town");
Audio.start(0, 99);
BG = 5;
if (travelling == "forward") {
startPos = [5, 11];
}
if (travelling == "back") {
startPos = [52, 12];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_Tain);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 33
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy2", "Springy2_" + a, 88888 + ((30 * j) + i));
this.clip["Springy2_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Springy2_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Springy2_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * j) + i));
this.clip["MBEAST1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy2", "Springy2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy2_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy2", "Springy2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy2_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy2", "Springy2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy2_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy2", "Springy2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy2_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Mists");
Audio.start(0, 99);
BG = 7;
if (travelling == "forward") {
startPos = [2, 12];
}
if (travelling == "back") {
startPos = [139, 12];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_Mists_1);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 34
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy2", "Springy2_" + a, 88888 + ((30 * j) + i));
this.clip["Springy2_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Springy2_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Springy2_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * j) + i));
this.clip["MBEAST1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy2", "Springy2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy2_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy2", "Springy2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy2_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy2", "Springy2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy2_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Springy2", "Springy2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Springy2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Springy2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Springy2_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Mists");
Audio.start(0, 99);
BG = 7;
if (travelling == "forward") {
startPos = [2, 12];
}
if (travelling == "back") {
startPos = [139, 10];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_Mists_2);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 35
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 10) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Josh_Ghost", "Josh_Ghost_" + a, 88888 + ((30 * j) + i));
this.clip["Josh_Ghost_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Josh_Ghost_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Josh_Ghost_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * j) + i));
this.clip["MBEAST1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Josh_Ghost", "Josh_Ghost_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Josh_Ghost_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Josh_Ghost_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Josh_Ghost_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Josh_Ghost", "Josh_Ghost_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Josh_Ghost_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Josh_Ghost_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Josh_Ghost_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Josh_Ghost", "Josh_Ghost_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Josh_Ghost_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Josh_Ghost_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Josh_Ghost_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 10) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Josh_Ghost", "Josh_Ghost_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Josh_Ghost_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Josh_Ghost_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Josh_Ghost_" + a].placer = a;
}
a++;
}
a = 10;
while (a < 20) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Mists");
Audio.start(0, 99);
BG = 7;
startPos = [5, 10];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
if (BossesBeaten[6] == 1) {
gotoAndPlay (36);
}
buildMap(map_Mists_3);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 36
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 30) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton2", "Skeleton2_" + a, 88888 + ((30 * j) + i));
this.clip["Skeleton2_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Skeleton2_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Skeleton2_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * j) + i));
this.clip["MBEAST1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("down");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton2", "Skeleton2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton2_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton2", "Skeleton2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton2_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton2", "Skeleton2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton2_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton2", "Skeleton2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton2_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Mists");
Audio.start(0, 99);
BG = 7;
if (travelling == "forward") {
startPos = [6, 11];
}
if (travelling == "back") {
startPos = [5, 38];
}
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_MistKeep_1);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 37
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 30) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton2", "Skeleton2_" + a, 88888 + ((30 * j) + i));
this.clip["Skeleton2_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Skeleton2_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Skeleton2_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * j) + i));
this.clip["MBEAST1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton2", "Skeleton2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton2_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton2", "Skeleton2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton2_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton2", "Skeleton2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton2_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Skeleton2", "Skeleton2_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Skeleton2_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Skeleton2_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Skeleton2_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_Mists");
Audio.start(0, 99);
if (MaxWeap < 5) {
BossesBeaten[6] = 1;
MaxWeap = 5;
WeaponType = 5;
}
BG = 6;
startPos = [63, 4];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
buildMap(map_MistKeep_2);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
stop();
Frame 38
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 30) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Searis", "Searis_" + a, 88888 + ((30 * j) + i));
this.clip["Searis_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["Searis_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["Searis_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * j) + i));
this.clip["MBEAST1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("right");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Searis", "Searis_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Searis_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Searis_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Searis_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Searis", "Searis_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Searis_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Searis_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Searis_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Searis", "Searis_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Searis_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Searis_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Searis_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("Searis", "Searis_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["Searis_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["Searis_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["Searis_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_MistKeep");
Audio.start(0, 99);
if (MaxWeap < 5) {
BossesBeaten[6] = 1;
MaxWeap = 5;
WeaponType = 5;
}
BG = 6;
startPos = [6, 11];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
if (CutscenesWatched[6] == 0) {
gotoAndPlay (66);
} else {
buildMap(map_MistKeep_3);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
}
stop();
Frame 39
function buildMap(map) {
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("Cover", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
mapW = map[0].length;
mapH = map.length;
cMap = map;
i = 0;
while (i < (visAreaY + 1)) {
j = 0;
while (j < (visAreaX + 1)) {
if (cMap[i][j] >= 0) {
if ((cMap[i][j] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, ((30 * j) + i) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + i) + "_") + j, (30 * j) + i);
}
this.clip[(("t_" + i) + "_") + j]._x = j * tileW;
this.clip[(("t_" + i) + "_") + j]._y = i * tileH;
this.clip[(("t_" + i) + "_") + j].gotoAndStop(cMap[i][j] + 1);
}
a = 0;
while (a < 30) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MistDemon", "MistDemon_" + a, 88888 + ((30 * j) + i));
this.clip["MistDemon_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["MistDemon_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["MistDemon_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[i][j] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * j) + i));
this.clip["MBEAST1_" + a].xpos = (j * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (i * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((i == startPos[1]) && (j == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (j * tileW) + (tileW / 2);
this.clip.char.ypos = (i * tileH) + (tileH / 2);
CharAppeared = 1;
}
j++;
}
i++;
}
while (CharAppeared == 0) {
doScroll("down");
}
}
function doScroll(dir) {
if ((dir == "right") && (mapW >= j)) {
this.clip._x = this.clip._x - scrSpeed;
_root.CenterMark._x = _root.CenterMark._x + scrSpeed;
majorX = majorX + scrSpeed;
if (majorX >= tileW) {
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = j;
while (lastj < (j + 1)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj - visAreaX) - 1)]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MistDemon", "MistDemon_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MistDemon_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MistDemon_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MistDemon_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
j++;
majorX = majorX - tileW;
}
}
if ((dir == "left") && (0 < (j - visAreaX))) {
this.clip._x = this.clip._x + scrSpeed;
_root.CenterMark._x = _root.CenterMark._x - scrSpeed;
majorX = majorX - scrSpeed;
if (0 >= majorX) {
j--;
var lasti = ((i - visAreaY) - 1);
while (lasti < i) {
var lastj = ((j - visAreaX) - 1);
while (lastj < (j - visAreaX)) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + lasti) + "_") + ((lastj + visAreaX) + 1)]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MistDemon", "MistDemon_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MistDemon_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MistDemon_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MistDemon_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorX = majorX + tileW;
}
}
if ((dir == "up") && (0 < (i - visAreaY))) {
this.clip._y = this.clip._y + scrSpeed;
_root.CenterMark._y = _root.CenterMark._y - scrSpeed;
majorY = majorY - scrSpeed;
if (0 >= majorY) {
i--;
var lasti = ((i - visAreaY) - 1);
while (lasti < (i - visAreaY)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti + visAreaY) + 1)) + "_") + lastj]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MistDemon", "MistDemon_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MistDemon_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MistDemon_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MistDemon_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
majorY = majorY + tileH;
}
}
if ((dir == "down") && (mapH >= i)) {
this.clip._y = this.clip._y - scrSpeed;
_root.CenterMark._y = _root.CenterMark._y + scrSpeed;
majorY = majorY + scrSpeed;
if (majorY >= tileH) {
var lasti = i;
while (lasti < (i + 1)) {
var lastj = ((j - visAreaX) - 1);
while (lastj < j) {
if ((cMap[lasti][lastj] + 1) >= 200) {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, ((30 * lastj) + lasti) + 12000);
} else {
this.clip.attachMovie("tile", (("t_" + lasti) + "_") + lastj, (30 * lastj) + lasti);
}
this.clip[(("t_" + lasti) + "_") + lastj]._x = lastj * tileW;
this.clip[(("t_" + lasti) + "_") + lastj]._y = lasti * tileH;
this.clip[(("t_" + lasti) + "_") + lastj].gotoAndStop(cMap[lasti][lastj] + 1);
removeMovieClip(this.clip[(("t_" + ((lasti - visAreaY) - 1)) + "_") + lastj]);
a = 0;
while (a < 30) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MistDemon", "MistDemon_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MistDemon_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MistDemon_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MistDemon_" + a].placer = a;
}
a++;
}
a = 30;
while (a < 40) {
if ((cMap[lasti][lastj] == (50 + a)) && (_root.active[a] == 0)) {
_root.active[a] = 1;
this.clip.attachMovie("MBEAST1", "MBEAST1_" + a, 88888 + ((30 * lastj) + lasti));
this.clip["MBEAST1_" + a].xpos = (lastj * tileW) + (tileW / 2);
this.clip["MBEAST1_" + a].ypos = (lasti * tileH) + (tileH / 2);
this.clip["MBEAST1_" + a].placer = a;
}
a++;
}
if (((lasti == startPos[1]) && (lastj == startPos[0])) && (CharAppeared == 0)) {
this.clip.attachMovie("char", "char", 11000);
this.clip.char.xpos = (lastj * tileW) + (tileW / 2);
this.clip.char.ypos = (lasti * tileH) + (tileH / 2);
CharAppeared = 1;
}
lastj++;
}
lasti++;
}
i++;
majorY = majorY - tileH;
}
}
}
majorX = 0;
majorY = 0;
scrSpeed = 4;
CharAppeared = 0;
Audio.stop();
Audio.attachSound("Music_FinalBoss");
Audio.start(0, 99);
if (MaxWeap < 5) {
BossesBeaten[6] = 1;
MaxWeap = 5;
WeaponType = 5;
}
BG = 6;
startPos = [10, 16];
_root.active = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
_root.CenterMark._x = 252;
_root.CenterMark._y = 224;
if (CutscenesWatched[7] == 0) {
gotoAndPlay (67);
} else {
buildMap(map_MistKeep_4);
attachMovie("RdyGo", "RdyGo", 21002);
RdyGo._x = 365;
RdyGo._y = 224;
}
stop();
Frame 50
Audio.stop();
Audio.attachSound("Music_Credits");
Audio.start(0, 99);
stop();
Frame 60
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("empty", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
Audio.stop();
CutscenesWatched[0] = 1;
stop();
Instance of Symbol 897 MovieClip in Frame 60
onClipEvent (unload) {
Voices.stop();
}
Frame 61
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("empty", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
Audio.stop();
CutscenesWatched[1] = 1;
stop();
Instance of Symbol 902 MovieClip in Frame 61
onClipEvent (unload) {
Voices.stop();
}
Frame 62
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("empty", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
Audio.stop();
CutscenesWatched[2] = 1;
stop();
Instance of Symbol 905 MovieClip in Frame 62
onClipEvent (unload) {
Voices.stop();
}
Frame 63
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("empty", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
Audio.stop();
CutscenesWatched[3] = 1;
stop();
Instance of Symbol 909 MovieClip in Frame 63
onClipEvent (unload) {
Voices.stop();
}
Frame 64
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("empty", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
Audio.stop();
CutscenesWatched[4] = 1;
stop();
Instance of Symbol 916 MovieClip in Frame 64
onClipEvent (unload) {
Voices.stop();
}
Frame 65
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("empty", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
Audio.stop();
CutscenesWatched[5] = 1;
stop();
Instance of Symbol 920 MovieClip in Frame 65
onClipEvent (unload) {
Voices.stop();
}
Frame 66
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("empty", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
Audio.stop();
CutscenesWatched[6] = 1;
stop();
Instance of Symbol 932 MovieClip in Frame 66
onClipEvent (unload) {
Voices.stop();
}
Frame 67
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("empty", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
Audio.stop();
CutscenesWatched[7] = 1;
stop();
Instance of Symbol 937 MovieClip in Frame 67
onClipEvent (unload) {
Voices.stop();
}
Frame 68
this.attachMovie("empty", "clip", 0);
this.clip._x = startX;
this.clip._y = startY;
this.attachMovie("empty", "Cover", 20000);
this.Cover._x = 320;
this.Cover._y = 224;
Audio.stop();
CutscenesWatched[8] = 1;
stop();
Instance of Symbol 949 MovieClip in Frame 68
onClipEvent (unload) {
Voices.stop();
}
Symbol 53 MovieClip Frame 1
scale = Number(random(50)) + 30;
setProperty(_target, _x , (Number(../:x) + Number(random(12))) - 6);
setProperty(_target, _yscale , scale);
Symbol 54 MovieClip Frame 1
i = 1;
max = 60;
x = getProperty("fire", _x);
Symbol 54 MovieClip Frame 2
if (Number(max) >= Number(i)) {
duplicateMovieClip ("fire", "fire" add i, i);
i = Number(i) + 1;
}
Symbol 54 MovieClip Frame 3
if (Number(max) >= Number(i)) {
duplicateMovieClip ("fire", "fire" add i, i);
i = Number(i) + 1;
}
gotoAndPlay (2);
Symbol 86 MovieClip Frame 2
if (_parent.EHealth < 1) {
gotoAndPlay (11);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 86 MovieClip Frame 4
if (_parent.EHealth < 1) {
gotoAndPlay (11);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 86 MovieClip Frame 34
_root.Gold = _root.Gold + 300;
_parent.removeMovieClip();
_root.BossesBeaten[4] = 1;
_root.gotoAndPlay(19);
Symbol 92 MovieClip [Plantshot] Frame 1
this._y = _root.clip["Plant_" + placer]._y;
this._x = _root.clip["Plant_" + placer]._x;
Symbol 92 MovieClip [Plantshot] Frame 2
if (_root.Paused < getTimer()) {
speed = 6;
xinc = Math.floor(speed * Math.sin(((rot - 90) / 180) * Math.PI));
yinc = -1 * Math.floor(speed * Math.cos(((rot - 90) / 180) * Math.PI));
this._x = this._x + xinc;
this._y = this._y + yinc;
if ((500 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y))) {
gotoAndPlay (4);
}
if (((((_root.clip.char._x - 20) < this._x) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 1);
} else {
_root.clip.char.PlayerHit("right", 1);
}
gotoAndPlay (4);
}
}
Symbol 92 MovieClip [Plantshot] Frame 3
gotoAndPlay (2);
Symbol 92 MovieClip [Plantshot] Frame 8
this.removeMovieClip();
Instance of Symbol 86 MovieClip in Symbol 93 MovieClip Frame 1
onClipEvent (load) {
gotoAndStop (3);
}
Instance of Symbol 92 MovieClip [Plantshot] in Symbol 93 MovieClip Frame 1
onClipEvent (load) {
stop();
}
Symbol 93 MovieClip Frame 17
gotoAndPlay (1);
Symbol 108 MovieClip Frame 121
_parent.removeMovieClip();
Symbol 110 MovieClip [ACC] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
if (_root.Paused < getTimer()) {
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (((((_root.clip.char._x - 20) < this._x) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
_root.Gold = _root.Gold + 20;
this.removeMovieClip();
}
this.render();
}
}
speed = 4;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
JustHit = getTimer() + 10;
Instance of Symbol 109 MovieClip [empty] in Symbol 110 MovieClip [ACC] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 115 MovieClip Frame 121
_parent.removeMovieClip();
Symbol 116 MovieClip [SCC] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
if (_root.Paused < getTimer()) {
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (((((_root.clip.char._x - 20) < this._x) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
_root.Gold = _root.Gold + 1;
this.removeMovieClip();
}
this.render();
}
}
speed = 4;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
JustHit = getTimer() + 10;
Instance of Symbol 109 MovieClip [empty] in Symbol 116 MovieClip [SCC] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 179 MovieClip Frame 121
_parent.removeMovieClip();
Symbol 180 MovieClip [GCC] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
if (_root.Paused < getTimer()) {
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (((((_root.clip.char._x - 20) < this._x) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
_root.Gold = _root.Gold + 5;
this.removeMovieClip();
}
this.render();
}
}
speed = 4;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
JustHit = getTimer() + 10;
Instance of Symbol 109 MovieClip [empty] in Symbol 180 MovieClip [GCC] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 187 MovieClip Frame 2
if (_parent.onGround) {
gotoAndPlay (1);
}
Symbol 187 MovieClip Frame 15
if (_parent.EHealth < 1) {
} else if ((_parent._x < _root.clip.char._x) && (_parent.onGround)) {
gotoAndPlay (2);
} else if ((_parent._x >= _root.clip.char._x) && (_parent.onGround)) {
gotoAndPlay (17);
} else {
gotoAndPlay (14);
}
Symbol 187 MovieClip Frame 17
if (_parent.onGround) {
gotoAndPlay (16);
}
Symbol 187 MovieClip Frame 30
if (_parent.EHealth < 1) {
} else if ((_parent._x < _root.clip.char._x) && (_parent.onGround)) {
gotoAndPlay (2);
} else if ((_parent._x >= _root.clip.char._x) && (_parent.onGround)) {
gotoAndPlay (17);
} else {
gotoAndPlay (29);
}
Symbol 188 MovieClip [Red_Ninja] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 23) / tileH);
upY = Math.floor((ypos - 23) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 22) / tileH);
upY2 = Math.floor((ypos - 22) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if (onGround) {
if (this._x < _root.clip.char._x) {
direct = 1;
} else {
direct = 2;
}
if (random(2) == 0) {
yspeed = -2 * jumpspeed;
} else if (direct == 1) {
yspeed = -jumpspeed;
xspeed = (2 + random(2)) * speed;
} else {
yspeed = -jumpspeed;
xspeed = (-(2 + random(2))) * speed;
}
}
if ((this._y < 150) && ((JustThrew + 500) < getTimer())) {
JustThrew = getTimer();
_parent.attachMovie("Red_Shuriken", "Red_Shuriken_" + ((10 * placer) + 1), 14000 + ((10 * placer) + 1));
_parent["Red_Shuriken_" + ((10 * placer) + 1)].placer = placer;
_parent["Red_Shuriken_" + ((10 * placer) + 1)].xspeed = 0;
_parent["Red_Shuriken_" + ((10 * placer) + 1)].yspeed = 10;
if (direct == 1) {
a = 1;
} else {
a = -1;
}
_parent.attachMovie("Red_Shuriken", "Red_Shuriken_" + ((10 * placer) + 2), 14000 + ((10 * placer) + 2));
_parent["Red_Shuriken_" + ((10 * placer) + 2)].placer = placer;
_parent["Red_Shuriken_" + ((10 * placer) + 2)].xspeed = a * 5;
_parent["Red_Shuriken_" + ((10 * placer) + 2)].yspeed = 9;
_parent.attachMovie("Red_Shuriken", "Red_Shuriken_" + ((10 * placer) + 3), 14000 + ((10 * placer) + 3));
_parent["Red_Shuriken_" + ((10 * placer) + 3)].placer = placer;
_parent["Red_Shuriken_" + ((10 * placer) + 3)].xspeed = a * 10;
_parent["Red_Shuriken_" + ((10 * placer) + 3)].yspeed = 7;
_parent.attachMovie("Red_Shuriken", "Red_Shuriken_" + ((10 * placer) + 4), 14000 + ((10 * placer) + 4));
_parent["Red_Shuriken_" + ((10 * placer) + 4)].placer = placer;
_parent["Red_Shuriken_" + ((10 * placer) + 4)].xspeed = a * 11;
_parent["Red_Shuriken_" + ((10 * placer) + 4)].yspeed = 4;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.Gold = _root.Gold + 250;
_root.active[placer] = 0;
_root.BossesBeaten[5] = _root.BossesBeaten[5] + 1;
if (_root.BossesBeaten[5] == 2) {
_root.travelling = "back";
_root.gotoAndPlay(19);
}
this.removeMovieClip();
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 25) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 25))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 40) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 40))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if (((((_root.clip.char._x - 30) < this._x) && (this._x < (_root.clip.char._x + 30))) && ((_root.clip.char._y - 40) < this._y)) && (this._y < (_root.clip.char._y + 40))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", -5);
} else {
_root.clip.char.PlayerHit("right", -5);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
this.attachMovie("Hit", "Hit", 1);
if (WT == 6) {
EHealth = EHealth - 2;
} else if (WT == 7) {
EHealth = EHealth - 3;
} else {
EHealth = EHealth - WT;
}
}
}
speed = 10;
jumpspeed = 14;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 2;
EHealth = 27;
JustHit = getTimer() + 10;
JustThrew = getTimer() + 10;
Instance of Symbol 109 MovieClip [empty] in Symbol 188 MovieClip [Red_Ninja] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 189 MovieClip [Ninja] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 23) / tileH);
upY = Math.floor((ypos - 23) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 22) / tileH);
upY2 = Math.floor((ypos - 22) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if (onGround) {
if (this._x < _root.clip.char._x) {
direct = 1;
} else {
direct = 2;
}
if (random(2) == 0) {
yspeed = -2 * jumpspeed;
} else if (direct == 1) {
yspeed = -jumpspeed;
xspeed = 2.5 * speed;
} else {
yspeed = -jumpspeed;
xspeed = -2.5 * speed;
}
}
if ((this._y < 150) && ((JustThrew + 500) < getTimer())) {
JustThrew = getTimer();
_parent.attachMovie("Shuriken", "Shuriken_" + ((10 * placer) + 1), 14000 + ((10 * placer) + 1));
_parent["Shuriken_" + ((10 * placer) + 1)].placer = placer;
_parent["Shuriken_" + ((10 * placer) + 1)].xspeed = 0;
_parent["Shuriken_" + ((10 * placer) + 1)].yspeed = 10;
if (direct == 1) {
a = 1;
} else {
a = -1;
}
_parent.attachMovie("Shuriken", "Shuriken_" + ((10 * placer) + 2), 14000 + ((10 * placer) + 2));
_parent["Shuriken_" + ((10 * placer) + 2)].placer = placer;
_parent["Shuriken_" + ((10 * placer) + 2)].xspeed = a * 5;
_parent["Shuriken_" + ((10 * placer) + 2)].yspeed = 9;
_parent.attachMovie("Shuriken", "Shuriken_" + ((10 * placer) + 3), 14000 + ((10 * placer) + 3));
_parent["Shuriken_" + ((10 * placer) + 3)].placer = placer;
_parent["Shuriken_" + ((10 * placer) + 3)].xspeed = a * 10;
_parent["Shuriken_" + ((10 * placer) + 3)].yspeed = 7;
_parent.attachMovie("Shuriken", "Shuriken_" + ((10 * placer) + 4), 14000 + ((10 * placer) + 4));
_parent["Shuriken_" + ((10 * placer) + 4)].placer = placer;
_parent["Shuriken_" + ((10 * placer) + 4)].xspeed = a * 11;
_parent["Shuriken_" + ((10 * placer) + 4)].yspeed = 4;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.Gold = _root.Gold + 50;
_root.BossesBeaten[0] = 1;
_root.active[placer] = 0;
_root.gotoAndPlay(62);
this.removeMovieClip();
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 25) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 25))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 40) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 40))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if (((((_root.clip.char._x - 30) < this._x) && (this._x < (_root.clip.char._x + 30))) && ((_root.clip.char._y - 40) < this._y)) && (this._y < (_root.clip.char._y + 40))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 2);
} else {
_root.clip.char.PlayerHit("right", 2);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
this.attachMovie("Hit", "Hit", 1);
if (WT == 6) {
EHealth = EHealth - 2;
} else if (WT == 7) {
EHealth = EHealth - 3;
} else {
EHealth = EHealth - WT;
}
}
}
speed = 10;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 2;
EHealth = 15;
JustHit = getTimer() + 10;
JustThrew = getTimer() + 10;
Instance of Symbol 109 MovieClip [empty] in Symbol 189 MovieClip [Ninja] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 221 MovieClip Frame 2
if ((!_parent.onGround) && (_parent.direct == 1)) {
gotoAndPlay (7);
} else if ((!_parent.onGround) && (_parent.direct == 2)) {
gotoAndPlay (15);
} else if (_parent.direct == 1) {
gotoAndPlay (1);
} else if (_parent.direct == 2) {
gotoAndPlay (3);
}
Symbol 221 MovieClip Frame 4
if ((!_parent.onGround) && (_parent.direct == 1)) {
gotoAndPlay (7);
} else if ((!_parent.onGround) && (_parent.direct == 2)) {
gotoAndPlay (15);
} else if (_parent.direct == 1) {
gotoAndPlay (1);
} else if (_parent.direct == 2) {
gotoAndPlay (3);
}
Symbol 221 MovieClip Frame 14
if ((!_parent.onGround) && (_parent.direct == 1)) {
gotoAndPlay (13);
} else if ((!_parent.onGround) && (_parent.direct == 2)) {
gotoAndPlay (22);
} else if (_parent.direct == 1) {
gotoAndPlay (1);
} else if (_parent.direct == 2) {
gotoAndPlay (3);
}
Symbol 221 MovieClip Frame 23
if ((!_parent.onGround) && (_parent.direct == 1)) {
gotoAndPlay (13);
} else if ((!_parent.onGround) && (_parent.direct == 2)) {
gotoAndPlay (22);
} else if (_parent.direct == 1) {
gotoAndPlay (1);
} else if (_parent.direct == 2) {
gotoAndPlay (3);
}
Symbol 222 MovieClip [Josh_Ghost] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
if (4600 < xpos) {
_parent.attachMovie("Ghost_Kill", "Ghost_Kill", 10);
this.removeMovieClip();
}
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 16) / tileW);
rightX = Math.floor((xpos + 16) / tileW);
midY = Math.floor(ypos / tileH);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if ((jump == 1) && (onGround)) {
yspeed = -jumpspeed;
jump = 0;
} else if (jump == 1) {
jump = 0;
}
direct = 1;
xspeed = speed;
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if ((((direct == 1) && (8 < cMap[midY][rightX])) && (cMap[midY][rightX] < 50)) || (((direct == 2) && (9 < cMap[midY][leftX])) && (cMap[midY][leftX] < 50))) {
jump = 1;
}
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
this.render();
}
}
speed = 7;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 10;
JustHit = getTimer() + 10;
jump = 0;
Instance of Symbol 109 MovieClip [empty] in Symbol 222 MovieClip [Josh_Ghost] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 228 MovieClip Frame 4
if (_parent._parent.onGround) {
play();
} else {
gotoAndPlay (3);
}
Symbol 233 MovieClip Frame 2
if (_parent.EHealth < 1) {
gotoAndPlay (11);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 233 MovieClip Frame 4
if (_parent.EHealth < 1) {
gotoAndPlay (11);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 233 MovieClip Frame 19
if (random(9) == 0) {
_root.clip.attachMovie("ACC", "ACC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["ACC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["ACC_" + _parent.placer].ypos = _parent.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("GCC", "GCC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["GCC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["GCC_" + _parent.placer].ypos = _parent.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("SCC", "SCC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["SCC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["SCC_" + _parent.placer].ypos = _parent.ypos - 10;
}
_parent.removeMovieClip();
Symbol 234 MovieClip [WolfWere] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 16) / tileW);
rightX = Math.floor((xpos + 16) / tileW);
midY = Math.floor(ypos / tileH);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if ((jump == 1) && (onGround)) {
yspeed = -jumpspeed;
jump = 0;
}
if ((onGround && (xspeed == 0)) && (this._x < _root.clip.char._x)) {
if (direct != 1) {
yspeed = 0;
}
direct = 1;
} else if ((onGround && (xspeed == 0)) && (_root.clip.char._x < this._x)) {
if (direct != 2) {
yspeed = 0;
}
direct = 2;
}
if (onGround && (this._x < (_root.clip.char._x - 40))) {
if (direct != 1) {
yspeed = 0;
}
direct = 1;
}
if (onGround && ((_root.clip.char._x + 40) < this._x)) {
if (direct != 2) {
yspeed = 0;
}
direct = 2;
}
if (direct == 1) {
xspeed = speed;
} else if (direct == 2) {
xspeed = -speed;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if ((((direct == 1) && (9 < cMap[midY][rightX])) && (cMap[midY][rightX] < 50)) || (((direct == 2) && (9 < cMap[midY][leftX])) && (cMap[midY][leftX] < 50))) {
jump = 1;
}
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 20) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 20))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 20) < this._x)) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 3);
} else {
_root.clip.char.PlayerHit("right", 3);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if (((WT != 6) && (2 < WT)) && ((JustHit + 150) < getTimer())) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
if (dir == "right") {
xspeed = -2 * speed;
} else {
xspeed = 2 * speed;
}
this.attachMovie("Hit", "Hit", 1);
if (WT == 7) {
EHealth = EHealth - 3;
} else {
EHealth = EHealth - WT;
}
}
}
speed = 6;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 10;
JustHit = getTimer() + 10;
jump = 0;
Instance of Symbol 109 MovieClip [empty] in Symbol 234 MovieClip [WolfWere] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 240 MovieClip Frame 4
if (_parent._parent.onGround) {
play();
} else {
gotoAndPlay (3);
}
Symbol 245 MovieClip Frame 2
if (_parent.EHealth < 1) {
gotoAndPlay (11);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 245 MovieClip Frame 4
if (_parent.EHealth < 1) {
gotoAndPlay (11);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 245 MovieClip Frame 19
if (random(3) == 0) {
_root.clip.attachMovie("ACC", "ACC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["ACC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["ACC_" + _parent.placer].ypos = _parent.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("GCC", "GCC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["GCC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["GCC_" + _parent.placer].ypos = _parent.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("SCC", "SCC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["SCC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["SCC_" + _parent.placer].ypos = _parent.ypos - 10;
}
_parent.removeMovieClip();
Symbol 246 MovieClip [MBEAST1] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 16) / tileW);
rightX = Math.floor((xpos + 16) / tileW);
midY = Math.floor(ypos / tileH);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if ((jump == 1) && (onGround)) {
yspeed = -jumpspeed;
jump = 0;
}
if ((onGround && (xspeed == 0)) && (this._x < _root.clip.char._x)) {
if (direct != 1) {
yspeed = 0;
}
direct = 1;
} else if ((onGround && (xspeed == 0)) && (_root.clip.char._x < this._x)) {
if (direct != 2) {
yspeed = 0;
}
direct = 2;
}
if (onGround && (this._x < (_root.clip.char._x - 40))) {
if (direct != 1) {
yspeed = 0;
}
direct = 1;
}
if (onGround && ((_root.clip.char._x + 40) < this._x)) {
if (direct != 2) {
yspeed = 0;
}
direct = 2;
}
if (direct == 1) {
xspeed = speed;
} else if (direct == 2) {
xspeed = -speed;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if ((((direct == 1) && (9 < cMap[midY][rightX])) && (cMap[midY][rightX] < 50)) || (((direct == 2) && (9 < cMap[midY][leftX])) && (cMap[midY][leftX] < 50))) {
jump = 1;
}
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 20) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 20))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 20) < this._x)) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 8);
} else {
_root.clip.char.PlayerHit("right", 8);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if (((JustHit + 150) < getTimer()) && (WT == 5)) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
if (dir == "right") {
xspeed = -2 * speed;
} else {
xspeed = 2 * speed;
}
this.attachMovie("Hit", "Hit", 1);
EHealth = EHealth - WT;
}
}
speed = 6;
jumpspeed = 9;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 25;
JustHit = getTimer() + 10;
jump = 0;
Instance of Symbol 109 MovieClip [empty] in Symbol 246 MovieClip [MBEAST1] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 264 MovieClip Frame 2
if (_parent.onGround && (_parent.direct == 1)) {
gotoAndPlay (3);
} else if (_parent.onGround && (_parent.direct == 2)) {
gotoAndPlay (1);
} else if (_parent.direct == 1) {
gotoAndPlay (8);
} else if (_parent.direct == 2) {
gotoAndPlay (6);
}
Symbol 264 MovieClip Frame 4
if (_parent.onGround && (_parent.direct == 1)) {
gotoAndPlay (3);
} else if (_parent.onGround && (_parent.direct == 2)) {
gotoAndPlay (1);
} else if (_parent.direct == 1) {
gotoAndPlay (8);
} else if (_parent.direct == 2) {
gotoAndPlay (6);
}
Symbol 264 MovieClip Frame 7
if (_parent.onGround && (_parent.direct == 1)) {
gotoAndPlay (3);
} else if (_parent.onGround && (_parent.direct == 2)) {
gotoAndPlay (1);
} else if (_parent.direct == 1) {
gotoAndPlay (8);
} else if (_parent.direct == 2) {
gotoAndPlay (6);
}
Symbol 264 MovieClip Frame 9
if (_parent.onGround && (_parent.direct == 1)) {
gotoAndPlay (3);
} else if (_parent.onGround && (_parent.direct == 2)) {
gotoAndPlay (1);
} else if (_parent.direct == 1) {
gotoAndPlay (8);
} else if (_parent.direct == 2) {
gotoAndPlay (6);
}
Symbol 265 MovieClip [MistDemon] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 16) / tileW);
rightX = Math.floor((xpos + 16) / tileW);
midY = Math.floor(ypos / tileH);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if ((jump == 1) && (onGround)) {
yspeed = -jumpspeed;
jump = 0;
if (random(3) == 0) {
drain = 3;
} else if (random(5) == 0) {
lev = 1;
}
}
if (((0 < EHealth) && (Math.abs(yspeed) < 1.5)) && (drain != 0)) {
drain--;
_parent.attachMovie("DemonDrain", "SearisEnergy_" + ((10 * placer) + ShotNum), 13000 + ((10 * placer) + ShotNum));
_parent["SearisEnergy_" + ((10 * placer) + ShotNum)].placer = placer;
rot = Math.atan((this._y - _root.clip.char._y) / (this._x - _root.clip.char._x)) * 57.2957795130823;
if ((this._x - _root.clip.char._x) < 0) {
rot = rot + 180;
}
if (((this._x - _root.clip.char._x) >= 0) && ((this._y - _root.clip.char._y) < 0)) {
rot = rot + 360;
}
_parent["SearisEnergy_" + ((10 * placer) + ShotNum)].rot = rot;
ShotNum = ShotNum + 1;
if (ShotNum >= 10) {
ShotNum = 0;
}
_root.SEffect.attachSound("SE_Drain");
_root.SEffect.start(0, 1);
}
if (((0 < EHealth) && (Math.abs(yspeed) < 1.5)) && (lev != 0)) {
lev--;
}
if ((onGround && (xspeed == 0)) && (this._x < _root.clip.char._x)) {
if (direct != 1) {
yspeed = 0;
}
direct = 1;
} else if ((onGround && (xspeed == 0)) && (_root.clip.char._x < this._x)) {
if (direct != 2) {
yspeed = 0;
}
direct = 2;
}
if (onGround && (this._x < (_root.clip.char._x - 40))) {
if (direct != 1) {
yspeed = 0;
}
direct = 1;
}
if (onGround && ((_root.clip.char._x + 40) < this._x)) {
if (direct != 2) {
yspeed = 0;
}
direct = 2;
}
if (direct == 1) {
xspeed = speed;
} else if (direct == 2) {
xspeed = -speed;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if ((((direct == 1) && (9 < cMap[midY][rightX])) && (cMap[midY][rightX] < 50)) || (((direct == 2) && (9 < cMap[midY][leftX])) && (cMap[midY][leftX] < 50))) {
jump = 1;
}
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
_root.gotoAndPlay(68);
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 20) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 20))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 20) < this._x)) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 4);
} else {
_root.clip.char.PlayerHit("right", 4);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 200;
if (dir == "right") {
xspeed = -speed;
} else {
xspeed = speed;
}
this.attachMovie("Hit", "Hit", 1);
if (WT == 6) {
EHealth = EHealth - 1;
} else if (WT == 7) {
EHealth = EHealth - 2;
} else if (WT == 5) {
EHealth = EHealth - 3;
}
}
}
speed = 8;
jumpspeed = 14;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 50;
JustHit = getTimer() + 10;
jump = 0;
drain = 0;
lev = 0;
ShotNum = 0;
Instance of Symbol 109 MovieClip [empty] in Symbol 265 MovieClip [MistDemon] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 266 MovieClip [Searis] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 16) / tileW);
rightX = Math.floor((xpos + 16) / tileW);
midY = Math.floor(ypos / tileH);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if ((jump == 1) && (onGround)) {
yspeed = -jumpspeed;
jump = 0;
if (random(4) == 0) {
ball = 3;
} else if (random(3) == 0) {
drain = 1;
}
}
if (((0 < EHealth) && (Math.abs(yspeed) < 1.5)) && (drain != 0)) {
drain--;
_parent.attachMovie("SearisDrain", "SearisEnergy_" + ((10 * placer) + ShotNum), 13000 + ((10 * placer) + ShotNum));
_parent["SearisEnergy_" + ((10 * placer) + ShotNum)].placer = placer;
rot = Math.atan((this._y - _root.clip.char._y) / (this._x - _root.clip.char._x)) * 57.2957795130823;
if ((this._x - _root.clip.char._x) < 0) {
rot = rot + 180;
}
if (((this._x - _root.clip.char._x) >= 0) && ((this._y - _root.clip.char._y) < 0)) {
rot = rot + 360;
}
_parent["SearisEnergy_" + ((10 * placer) + ShotNum)].rot = rot;
ShotNum = ShotNum + 1;
if (ShotNum >= 10) {
ShotNum = 0;
}
_root.SEffect.attachSound("SE_Drain");
_root.SEffect.start(0, 1);
}
if (((0 < EHealth) && (Math.abs(yspeed) < 1.5)) && (ball != 0)) {
ball--;
_parent.attachMovie("SearisEnergy2", "SearisEnergy_" + ((10 * placer) + ShotNum), 13000 + ((10 * placer) + ShotNum));
_parent["SearisEnergy_" + ((10 * placer) + ShotNum)].placer = placer;
rot = Math.atan((this._y - _root.clip.char._y) / (this._x - _root.clip.char._x)) * 57.2957795130823;
if ((this._x - _root.clip.char._x) < 0) {
rot = rot + 180;
}
if (((this._x - _root.clip.char._x) >= 0) && ((this._y - _root.clip.char._y) < 0)) {
rot = rot + 360;
}
_parent["SearisEnergy_" + ((10 * placer) + ShotNum)].rot = rot;
ShotNum = ShotNum + 1;
if (ShotNum >= 10) {
ShotNum = 0;
}
}
if ((onGround && (xspeed == 0)) && (this._x < _root.clip.char._x)) {
if (direct != 1) {
yspeed = 0;
}
direct = 1;
} else if ((onGround && (xspeed == 0)) && (_root.clip.char._x < this._x)) {
if (direct != 2) {
yspeed = 0;
}
direct = 2;
}
if (onGround && (this._x < (_root.clip.char._x - 40))) {
if (direct != 1) {
yspeed = 0;
}
direct = 1;
}
if (onGround && ((_root.clip.char._x + 40) < this._x)) {
if (direct != 2) {
yspeed = 0;
}
direct = 2;
}
if (direct == 1) {
xspeed = speed;
} else if (direct == 2) {
xspeed = -speed;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if ((((direct == 1) && (9 < cMap[midY][rightX])) && (cMap[midY][rightX] < 50)) || (((direct == 2) && (9 < cMap[midY][leftX])) && (cMap[midY][leftX] < 50))) {
jump = 1;
}
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
_root.gotoAndPlay(67);
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 20) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 20))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 20) < this._x)) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 4);
} else {
_root.clip.char.PlayerHit("right", 4);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 200;
if (dir == "right") {
xspeed = -speed;
} else {
xspeed = speed;
}
this.attachMovie("Hit", "Hit", 1);
if (WT == 6) {
EHealth = EHealth - 1;
} else if (WT == 7) {
EHealth = EHealth - 3;
} else if (WT == 5) {
EHealth = EHealth - 2;
}
}
}
speed = 6;
jumpspeed = 20;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 50;
JustHit = getTimer() + 10;
jump = 0;
drain = 0;
ball = 0;
ShotNum = 0;
Instance of Symbol 109 MovieClip [empty] in Symbol 266 MovieClip [Searis] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 270 MovieClip Frame 2
if (_parent.EHealth < 1) {
gotoAndPlay (11);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 270 MovieClip Frame 4
if (_parent.EHealth < 1) {
gotoAndPlay (11);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 270 MovieClip Frame 19
if (random(9) == 0) {
_root.clip.attachMovie("ACC", "ACC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["ACC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["ACC_" + _parent.placer].ypos = _parent.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("GCC", "GCC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["GCC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["GCC_" + _parent.placer].ypos = _parent.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("SCC", "SCC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["SCC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["SCC_" + _parent.placer].ypos = _parent.ypos - 10;
}
_parent.removeMovieClip();
Symbol 271 MovieClip [Wolf] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 16) / tileW);
rightX = Math.floor((xpos + 16) / tileW);
midY = Math.floor(ypos / tileH);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if ((jump == 1) && (onGround)) {
yspeed = -jumpspeed;
jump = 0;
}
if ((onGround && (xspeed == 0)) && (this._x < _root.clip.char._x)) {
if (direct != 1) {
yspeed = 0;
}
direct = 1;
} else if ((onGround && (xspeed == 0)) && (_root.clip.char._x < this._x)) {
if (direct != 2) {
yspeed = 0;
}
direct = 2;
}
if (onGround && (this._x < (_root.clip.char._x - 40))) {
if (direct != 1) {
yspeed = 0;
}
direct = 1;
}
if (onGround && ((_root.clip.char._x + 40) < this._x)) {
if (direct != 2) {
yspeed = 0;
}
direct = 2;
}
if (direct == 1) {
xspeed = speed;
} else if (direct == 2) {
xspeed = -speed;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if ((((direct == 1) && (9 < cMap[midY][rightX])) && (cMap[midY][rightX] < 50)) || (((direct == 2) && (9 < cMap[midY][leftX])) && (cMap[midY][leftX] < 50))) {
jump = 1;
}
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 20) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 20))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 20) < this._x)) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 2);
} else {
_root.clip.char.PlayerHit("right", 2);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
if (dir == "right") {
xspeed = -2 * speed;
} else {
xspeed = 2 * speed;
}
this.attachMovie("Hit", "Hit", 1);
if (WT == 6) {
EHealth = EHealth - 2;
} else if (WT == 7) {
EHealth = EHealth - 4;
} else {
EHealth = EHealth - WT;
}
}
}
speed = 6;
jumpspeed = 9;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 10;
JustHit = getTimer() + 10;
jump = 0;
Instance of Symbol 109 MovieClip [empty] in Symbol 271 MovieClip [Wolf] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 273 MovieClip [SB1] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if (Startup == 0) {
_parent.attachMovie("SB1A", ("SB1A_" + (10 * placer)) + 9, (99000 + (10 * placer)) + 9);
_parent[("SB1A_" + (10 * placer)) + 9].placer = placer;
_parent.attachMovie("SpikedBall_Chain_anim", ("SpikedBall_Chain_anim_" + (10 * placer)) + 5, (99000 + (10 * placer)) + 5);
_parent[("SpikedBall_Chain_anim_" + (10 * placer)) + 5].percentage = 0.2;
_parent[("SpikedBall_Chain_anim_" + (10 * placer)) + 5].placer = placer;
_parent.attachMovie("SpikedBall_Chain_anim", ("SpikedBall_Chain_anim_" + (10 * placer)) + 6, (99000 + (10 * placer)) + 6);
_parent[("SpikedBall_Chain_anim_" + (10 * placer)) + 6].percentage = 0.4;
_parent[("SpikedBall_Chain_anim_" + (10 * placer)) + 6].placer = placer;
_parent.attachMovie("SpikedBall_Chain_anim", ("SpikedBall_Chain_anim_" + (10 * placer)) + 7, (99000 + (10 * placer)) + 7);
_parent[("SpikedBall_Chain_anim_" + (10 * placer)) + 7].percentage = 0.6;
_parent[("SpikedBall_Chain_anim_" + (10 * placer)) + 7].placer = placer;
_parent.attachMovie("SpikedBall_Chain_anim", ("SpikedBall_Chain_anim_" + (10 * placer)) + 8, (99000 + (10 * placer)) + 8);
_parent[("SpikedBall_Chain_anim_" + (10 * placer)) + 8].percentage = 0.8;
_parent[("SpikedBall_Chain_anim_" + (10 * placer)) + 8].placer = placer;
_parent.attachMovie("SpikedBall_ChainBorder_anim", ("SpikedBall_ChainBorder_anim_" + (10 * placer)) + 1, (99000 + (10 * placer)) + 1);
_parent[("SpikedBall_ChainBorder_anim_" + (10 * placer)) + 1].percentage = 0.2;
_parent[("SpikedBall_ChainBorder_anim_" + (10 * placer)) + 1].placer = placer;
_parent.attachMovie("SpikedBall_ChainBorder_anim", ("SpikedBall_ChainBorder_anim_" + (10 * placer)) + 2, (99000 + (10 * placer)) + 2);
_parent[("SpikedBall_ChainBorder_anim_" + (10 * placer)) + 2].percentage = 0.4;
_parent[("SpikedBall_ChainBorder_anim_" + (10 * placer)) + 2].placer = placer;
_parent.attachMovie("SpikedBall_ChainBorder_anim", ("SpikedBall_ChainBorder_anim_" + (10 * placer)) + 3, (99000 + (10 * placer)) + 3);
_parent[("SpikedBall_ChainBorder_anim_" + (10 * placer)) + 3].percentage = 0.6;
_parent[("SpikedBall_ChainBorder_anim_" + (10 * placer)) + 3].placer = placer;
_parent.attachMovie("SpikedBall_ChainBorder_anim", ("SpikedBall_ChainBorder_anim_" + (10 * placer)) + 4, (99000 + (10 * placer)) + 4);
_parent[("SpikedBall_ChainBorder_anim_" + (10 * placer)) + 4].percentage = 0.8;
_parent[("SpikedBall_ChainBorder_anim_" + (10 * placer)) + 4].placer = placer;
Startup = 1;
}
}
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
this.removeMovieClip();
}
this.render();
}
}
speed = 4;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 2;
JustHit = getTimer() + 10;
Startup = 0;
Instance of Symbol 109 MovieClip [empty] in Symbol 273 MovieClip [SB1] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 287 MovieClip Frame 2
if ((_parent.latch == 1) && (_parent.direct == 1)) {
gotoAndPlay (13);
} else if ((_parent.latch == 1) && (_parent.direct == 2)) {
gotoAndPlay (11);
} else if ((_parent.latch == 2) && (_parent.direct == 2)) {
gotoAndPlay (18);
} else if ((_parent.latch == 2) && (_parent.direct == 1)) {
gotoAndPlay (16);
} else if ((!_parent.onGround) && (_parent.direct == 1)) {
gotoAndPlay (8);
} else if ((!_parent.onGround) && (_parent.direct == 2)) {
gotoAndPlay (6);
} else if (_parent.direct == 1) {
gotoAndPlay (1);
} else if (_parent.direct == 2) {
gotoAndPlay (3);
}
Symbol 287 MovieClip Frame 4
if ((_parent.latch == 1) && (_parent.direct == 1)) {
gotoAndPlay (13);
} else if ((_parent.latch == 1) && (_parent.direct == 2)) {
gotoAndPlay (11);
} else if ((_parent.latch == 2) && (_parent.direct == 2)) {
gotoAndPlay (18);
} else if ((_parent.latch == 2) && (_parent.direct == 1)) {
gotoAndPlay (16);
} else if ((!_parent.onGround) && (_parent.direct == 1)) {
gotoAndPlay (8);
} else if ((!_parent.onGround) && (_parent.direct == 2)) {
gotoAndPlay (6);
} else if (_parent.direct == 1) {
gotoAndPlay (1);
} else if (_parent.direct == 2) {
gotoAndPlay (3);
}
Symbol 287 MovieClip Frame 7
if ((_parent.latch == 1) && (_parent.direct == 1)) {
gotoAndPlay (13);
} else if ((_parent.latch == 1) && (_parent.direct == 2)) {
gotoAndPlay (11);
} else if ((_parent.latch == 2) && (_parent.direct == 2)) {
gotoAndPlay (18);
} else if ((_parent.latch == 2) && (_parent.direct == 1)) {
gotoAndPlay (16);
} else if ((!_parent.onGround) && (_parent.direct == 1)) {
gotoAndPlay (8);
} else if ((!_parent.onGround) && (_parent.direct == 2)) {
gotoAndPlay (6);
} else if (_parent.direct == 1) {
gotoAndPlay (1);
} else if (_parent.direct == 2) {
gotoAndPlay (3);
}
Symbol 287 MovieClip Frame 9
if ((_parent.latch == 1) && (_parent.direct == 1)) {
gotoAndPlay (13);
} else if ((_parent.latch == 1) && (_parent.direct == 2)) {
gotoAndPlay (11);
} else if ((_parent.latch == 2) && (_parent.direct == 2)) {
gotoAndPlay (18);
} else if ((_parent.latch == 2) && (_parent.direct == 1)) {
gotoAndPlay (16);
} else if ((!_parent.onGround) && (_parent.direct == 1)) {
gotoAndPlay (8);
} else if ((!_parent.onGround) && (_parent.direct == 2)) {
gotoAndPlay (6);
} else if (_parent.direct == 1) {
gotoAndPlay (1);
} else if (_parent.direct == 2) {
gotoAndPlay (3);
}
Symbol 287 MovieClip Frame 12
if ((_parent.latch == 1) && (_parent.direct == 1)) {
gotoAndPlay (13);
} else if ((_parent.latch == 1) && (_parent.direct == 2)) {
gotoAndPlay (11);
} else if ((_parent.latch == 2) && (_parent.direct == 2)) {
gotoAndPlay (18);
} else if ((_parent.latch == 2) && (_parent.direct == 1)) {
gotoAndPlay (16);
} else if ((!_parent.onGround) && (_parent.direct == 1)) {
gotoAndPlay (8);
} else if ((!_parent.onGround) && (_parent.direct == 2)) {
gotoAndPlay (6);
} else if (_parent.direct == 1) {
gotoAndPlay (1);
} else if (_parent.direct == 2) {
gotoAndPlay (3);
}
Symbol 287 MovieClip Frame 14
if ((_parent.latch == 1) && (_parent.direct == 1)) {
gotoAndPlay (13);
} else if ((_parent.latch == 1) && (_parent.direct == 2)) {
gotoAndPlay (11);
} else if ((_parent.latch == 2) && (_parent.direct == 2)) {
gotoAndPlay (18);
} else if ((_parent.latch == 2) && (_parent.direct == 1)) {
gotoAndPlay (16);
} else if ((!_parent.onGround) && (_parent.direct == 1)) {
gotoAndPlay (8);
} else if ((!_parent.onGround) && (_parent.direct == 2)) {
gotoAndPlay (6);
} else if (_parent.direct == 1) {
gotoAndPlay (1);
} else if (_parent.direct == 2) {
gotoAndPlay (3);
}
Symbol 287 MovieClip Frame 17
if ((_parent.latch == 1) && (_parent.direct == 1)) {
gotoAndPlay (13);
} else if ((_parent.latch == 1) && (_parent.direct == 2)) {
gotoAndPlay (11);
} else if ((_parent.latch == 2) && (_parent.direct == 2)) {
gotoAndPlay (18);
} else if ((_parent.latch == 2) && (_parent.direct == 1)) {
gotoAndPlay (16);
} else if ((!_parent.onGround) && (_parent.direct == 1)) {
gotoAndPlay (8);
} else if ((!_parent.onGround) && (_parent.direct == 2)) {
gotoAndPlay (6);
} else if (_parent.direct == 1) {
gotoAndPlay (1);
} else if (_parent.direct == 2) {
gotoAndPlay (3);
}
Symbol 287 MovieClip Frame 19
if ((_parent.latch == 1) && (_parent.direct == 1)) {
gotoAndPlay (13);
} else if ((_parent.latch == 1) && (_parent.direct == 2)) {
gotoAndPlay (11);
} else if ((_parent.latch == 2) && (_parent.direct == 2)) {
gotoAndPlay (18);
} else if ((_parent.latch == 2) && (_parent.direct == 1)) {
gotoAndPlay (16);
} else if ((!_parent.onGround) && (_parent.direct == 1)) {
gotoAndPlay (8);
} else if ((!_parent.onGround) && (_parent.direct == 2)) {
gotoAndPlay (6);
} else if (_parent.direct == 1) {
gotoAndPlay (1);
} else if (_parent.direct == 2) {
gotoAndPlay (3);
}
Symbol 288 MovieClip [Werewolf] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if (action == 0) {
run = 0;
jump = 0;
launch = 0;
latch = 0;
if ((onGround && (xspeed == 0)) && (this._x < _root.clip.char._x)) {
direct = 1;
} else if ((onGround && (xspeed == 0)) && (_root.clip.char._x < this._x)) {
direct = 2;
}
if (onGround && (this._x < (_root.clip.char._x - 40))) {
direct = 1;
}
if (onGround && ((_root.clip.char._x + 40) < this._x)) {
direct = 2;
}
if (random(3) == 0) {
jump = 1;
if (random(4) == 0) {
launch = 1;
}
} else {
run = 1;
}
action = 1;
}
if (jump == 1) {
if (onGround) {
yspeed = -jumpspeed;
}
if (latch == 1) {
if (direct == 1) {
xspeed = 2 * speed;
} else if (direct == 2) {
xspeed = -2 * speed;
}
} else if (direct == 1) {
xspeed = speed;
} else if (direct == 2) {
xspeed = -speed;
}
} else if (run == 1) {
if (direct == 1) {
xspeed = speed;
} else if (direct == 2) {
xspeed = -speed;
}
}
if (latch == 2) {
yspeed = 0.6 * jumpspeed;
if (direct == 1) {
xspeed = -2.6 * speed;
} else if (direct == 2) {
xspeed = 2.6 * speed;
}
}
}
if (((latch == 0) && (0 < yspeed)) && (launch == 1)) {
latch = 1;
yspeed = 0;
xspeed = 3 * xspeed;
}
if (latch == 0) {
yspeed = yspeed + gravity;
} else if (latch == 1) {
yspeed = 0;
}
if ((!onGround) && (latch == 0)) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
if (latch == 0) {
action = 0;
xspeed = 0;
} else if (latch == 1) {
if (launch == 1) {
jump = 0;
run = 1;
latch = 2;
launch = 0;
}
} else {
latch = 0;
xspeed = 0;
}
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
if ((latch == 0) && (onGround)) {
action = 0;
xspeed = 0;
} else if (latch == 1) {
if (launch == 1) {
jump = 0;
run = 1;
latch = 2;
launch = 0;
}
} else {
latch = 0;
xspeed = 0;
}
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (0 < latch) {
action = 0;
latch = 0;
xspeed = 0;
}
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.Gold = _root.Gold + 350;
_root.BossesBeaten[2] = 1;
_root.active[placer] = 0;
_root.gotoAndPlay(19);
this.removeMovieClip();
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.char._x - 49) < this._x)) && (this._x < (_root.clip.char._x + 49))) && ((_root.clip.char._y - 33) < this._y)) && (this._y < (_root.clip.char._y + 33))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.char._x - 49) < this._x)) && (this._x < (_root.clip.char._x + 49))) && ((_root.clip.char._y - 33) < this._y)) && (this._y < (_root.clip.char._y + 33))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.char._x - 49) < this._x)) && (this._x < (_root.clip.char._x + 49))) && ((_root.clip.char._y - 33) < this._y)) && (this._y < (_root.clip.char._y + 33))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.char._x - 49) < this._x)) && (this._x < (_root.clip.char._x + 49))) && ((_root.clip.char._y - 33) < this._y)) && (this._y < (_root.clip.char._y + 33))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.char._x - 49) < this._x)) && (this._x < (_root.clip.char._x + 49))) && ((_root.clip.char._y - 33) < this._y)) && (this._y < (_root.clip.char._y + 33))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && ((_root.clip.char._x - 49) < this._x)) && (this._x < (_root.clip.char._x + 49))) && ((_root.clip.char._y - 33) < this._y)) && (this._y < (_root.clip.char._y + 33))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((!_root.Attacking) && (0 < EHealth)) && ((_root.clip.char._x - 40) < this._x)) && (this._x < (_root.clip.char._x + 40))) && ((_root.clip.char._y - 30) < this._y)) && (this._y < (_root.clip.char._y + 30))) {
if (latch == 2) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", -5);
} else {
_root.clip.char.PlayerHit("right", -5);
}
} else if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 3);
} else {
_root.clip.char.PlayerHit("right", 3);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((WT == 3) && ((JustHit + 150) < getTimer())) {
JustHit = getTimer();
this.attachMovie("Hit", "Hit", 1);
EHealth = EHealth - 1;
}
}
speed = 7;
jumpspeed = 18;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 2;
EHealth = 12;
JustHit = getTimer() + 10;
latch = 0;
Instance of Symbol 109 MovieClip [empty] in Symbol 288 MovieClip [Werewolf] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 313 MovieClip Frame 2
if ((_parent.slash == 1) && (_parent.direct == 1)) {
gotoAndPlay (6);
} else if ((_parent.slash == 1) && (_parent.direct == 2)) {
gotoAndPlay (25);
} else if (_parent.EHealth < 1) {
gotoAndPlay (44);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 313 MovieClip Frame 4
if ((_parent.slash == 1) && (_parent.direct == 1)) {
gotoAndPlay (6);
} else if ((_parent.slash == 1) && (_parent.direct == 2)) {
gotoAndPlay (25);
} else if (_parent.EHealth < 1) {
gotoAndPlay (44);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 313 MovieClip Frame 21
if (((((0 < _parent.EHealth) && ((_root.clip.char._x - 60) < _parent._x)) && (_parent._x < (_root.clip.char._x + 0))) && ((_root.clip.char._y - 30) < _parent._y)) && (_parent._y < (_root.clip.char._y + 30))) {
if (_parent._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", -6);
} else {
_root.clip.char.PlayerHit("right", -6);
}
}
Symbol 313 MovieClip Frame 22
if (((((0 < _parent.EHealth) && ((_root.clip.char._x - 60) < _parent._x)) && (_parent._x < (_root.clip.char._x + 0))) && ((_root.clip.char._y - 30) < _parent._y)) && (_parent._y < (_root.clip.char._y + 30))) {
if (_parent._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", -6);
} else {
_root.clip.char.PlayerHit("right", -6);
}
}
Symbol 313 MovieClip Frame 23
if (((((0 < _parent.EHealth) && ((_root.clip.char._x - 60) < _parent._x)) && (_parent._x < (_root.clip.char._x + 0))) && ((_root.clip.char._y - 30) < _parent._y)) && (_parent._y < (_root.clip.char._y + 30))) {
if (_parent._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", -6);
} else {
_root.clip.char.PlayerHit("right", -6);
}
}
_parent.slash = 0;
gotoAndPlay (3);
Symbol 313 MovieClip Frame 40
if (((((0 < _parent.EHealth) && ((_root.clip.char._x - 0) < _parent._x)) && (_parent._x < (_root.clip.char._x + 60))) && ((_root.clip.char._y - 30) < _parent._y)) && (_parent._y < (_root.clip.char._y + 30))) {
if (_parent._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", -6);
} else {
_root.clip.char.PlayerHit("right", -6);
}
}
Symbol 313 MovieClip Frame 41
if (((((0 < _parent.EHealth) && ((_root.clip.char._x - 0) < _parent._x)) && (_parent._x < (_root.clip.char._x + 60))) && ((_root.clip.char._y - 30) < _parent._y)) && (_parent._y < (_root.clip.char._y + 30))) {
if (_parent._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", -6);
} else {
_root.clip.char.PlayerHit("right", -6);
}
}
Symbol 313 MovieClip Frame 42
if (((((0 < _parent.EHealth) && ((_root.clip.char._x - 0) < _parent._x)) && (_parent._x < (_root.clip.char._x + 60))) && ((_root.clip.char._y - 30) < _parent._y)) && (_parent._y < (_root.clip.char._y + 30))) {
if (_parent._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", -6);
} else {
_root.clip.char.PlayerHit("right", -6);
}
}
_parent.slash = 0;
gotoAndPlay (1);
Symbol 313 MovieClip Frame 56
if (random(9) == 0) {
_root.clip.attachMovie("ACC", "ACC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["ACC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["ACC_" + _parent.placer].ypos = _parent.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("GCC", "GCC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["GCC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["GCC_" + _parent.placer].ypos = _parent.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("SCC", "SCC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["SCC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["SCC_" + _parent.placer].ypos = _parent.ypos - 10;
}
_parent.removeMovieClip();
Symbol 314 MovieClip [Skeleton2] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if ((xspeed == 0) && (this._x < _root.clip.char._x)) {
direct = 1;
} else if ((xspeed == 0) && (_root.clip.char._x < this._x)) {
direct = 2;
}
if (this._x < (_root.clip.char._x - 40)) {
direct = 1;
}
if ((_root.clip.char._x + 40) < this._x) {
direct = 2;
}
if ((direct == 1) && (slash == 0)) {
xspeed = speed;
} else if ((direct == 2) && (slash == 0)) {
xspeed = -speed;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
this.removeMovieClip();
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 20) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 20))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 28) < this._x)) && (this._x < (_root.clip.char._x + 28))) && ((_root.clip.char._y - 30) < this._y)) && (this._y < (_root.clip.char._y + 30))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 3);
} else {
_root.clip.char.PlayerHit("right", 3);
}
}
if (((((0 < EHealth) && ((_root.clip.char._x - 50) < this._x)) && (this._x < (_root.clip.char._x + 50))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
slash = 1;
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
if (dir == "right") {
xspeed = -2 * speed;
} else {
xspeed = 2 * speed;
}
if (4 < WT) {
this.attachMovie("Hit", "Hit", 1);
}
if (WT == 6) {
EHealth = EHealth - 3;
} else if (WT == 7) {
EHealth = EHealth - 7;
} else if (4 < WT) {
EHealth = EHealth - WT;
}
}
}
speed = 4;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 25;
slash = 0;
JustHit = getTimer() + 10;
Instance of Symbol 109 MovieClip [empty] in Symbol 314 MovieClip [Skeleton2] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 315 MovieClip [Skeleton] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if ((xspeed == 0) && (this._x < _root.clip.char._x)) {
direct = 1;
} else if ((xspeed == 0) && (_root.clip.char._x < this._x)) {
direct = 2;
}
if (this._x < (_root.clip.char._x - 40)) {
direct = 1;
}
if ((_root.clip.char._x + 40) < this._x) {
direct = 2;
}
if ((direct == 1) && (slash == 0)) {
xspeed = speed;
} else if ((direct == 2) && (slash == 0)) {
xspeed = -speed;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
this.removeMovieClip();
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 20) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 20))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 28) < this._x)) && (this._x < (_root.clip.char._x + 28))) && ((_root.clip.char._y - 30) < this._y)) && (this._y < (_root.clip.char._y + 30))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 3);
} else {
_root.clip.char.PlayerHit("right", 3);
}
}
if (((((0 < EHealth) && ((_root.clip.char._x - 50) < this._x)) && (this._x < (_root.clip.char._x + 50))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
slash = 1;
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
if (dir == "right") {
xspeed = -2 * speed;
} else {
xspeed = 2 * speed;
}
if (2 < WT) {
this.attachMovie("Hit", "Hit", 1);
}
if (WT == 6) {
EHealth = EHealth - 2;
} else if (WT == 7) {
EHealth = EHealth - 5;
} else if (2 < WT) {
EHealth = EHealth - WT;
}
}
}
speed = 3;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 14;
slash = 0;
JustHit = getTimer() + 10;
Instance of Symbol 109 MovieClip [empty] in Symbol 315 MovieClip [Skeleton] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 325 MovieClip Frame 2
if (_parent.EHealth < 1) {
gotoAndPlay (11);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 325 MovieClip Frame 4
if (_parent.EHealth < 1) {
gotoAndPlay (11);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 325 MovieClip Frame 23
if (random(8) == 0) {
_root.clip.attachMovie("ACC", "ACC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["ACC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["ACC_" + _parent.placer].ypos = _parent.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("GCC", "GCC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["GCC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["GCC_" + _parent.placer].ypos = _parent.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("SCC", "SCC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["SCC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["SCC_" + _parent.placer].ypos = _parent.ypos - 10;
}
_parent.removeMovieClip();
Symbol 326 MovieClip [Golem] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if ((xspeed == 0) && (this._x < _root.clip.char._x)) {
direct = 1;
} else if ((xspeed == 0) && (_root.clip.char._x < this._x)) {
direct = 2;
}
if (this._x < (_root.clip.char._x - 40)) {
direct = 1;
}
if ((_root.clip.char._x + 40) < this._x) {
direct = 2;
}
if (direct == 1) {
xspeed = speed;
} else if (direct == 2) {
xspeed = -speed;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
this.removeMovieClip();
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 20) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 20))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 20) < this._x)) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 3);
} else {
_root.clip.char.PlayerHit("right", 3);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
if (dir == "right") {
xspeed = -2 * speed;
} else {
xspeed = 2 * speed;
}
if ((WT != 6) && (3 < WT)) {
this.attachMovie("Hit", "Hit", 1);
}
if (WT == 7) {
EHealth = EHealth - 4;
} else if ((WT == 4) || (WT == 5)) {
EHealth = EHealth - 3;
}
}
}
speed = 2;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 12;
JustHit = getTimer() + 10;
Instance of Symbol 109 MovieClip [empty] in Symbol 326 MovieClip [Golem] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 330 MovieClip [GreenLight] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
xspeed = speed;
}
yspeed = 0;
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if ((0 < EHealth) && ((_root.clip.char._x + 40) < this._x)) {
_root.clip.char.PlayerHit("right", 50);
}
this.render();
}
}
speed = 1;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 2;
JustHit = getTimer() + 10;
Instance of Symbol 109 MovieClip [empty] in Symbol 330 MovieClip [GreenLight] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 331 MovieClip [SearisShade] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (activate == 0) {
_parent.attachMovie("SearisEnergy_Circle", ("SearisEnergy_Circle_" + (10 * placer)) + 1, (99000 + (10 * placer)) + 1);
_parent[("SearisEnergy_Circle_" + (10 * placer)) + 1].placer = placer;
_parent[("SearisEnergy_Circle_" + (10 * placer)) + 1].offset = 0;
_parent.attachMovie("SearisEnergy_Circle", ("SearisEnergy_Circle_" + (10 * placer)) + 2, (99000 + (10 * placer)) + 2);
_parent[("SearisEnergy_Circle_" + (10 * placer)) + 2].placer = placer;
_parent[("SearisEnergy_Circle_" + (10 * placer)) + 2].offset = 250;
_parent.attachMovie("SearisEnergy_Circle", ("SearisEnergy_Circle_" + (10 * placer)) + 3, (99000 + (10 * placer)) + 3);
_parent[("SearisEnergy_Circle_" + (10 * placer)) + 3].placer = placer;
_parent[("SearisEnergy_Circle_" + (10 * placer)) + 3].offset = 500;
_parent.attachMovie("SearisEnergy_Circle", ("SearisEnergy_Circle_" + (10 * placer)) + 4, (99000 + (10 * placer)) + 4);
_parent[("SearisEnergy_Circle_" + (10 * placer)) + 4].placer = placer;
_parent[("SearisEnergy_Circle_" + (10 * placer)) + 4].offset = 750;
_parent.attachMovie("SearisEnergy_Circle", ("SearisEnergy_Circle_" + (10 * placer)) + 5, (99000 + (10 * placer)) + 5);
_parent[("SearisEnergy_Circle_" + (10 * placer)) + 5].placer = placer;
_parent[("SearisEnergy_Circle_" + (10 * placer)) + 5].offset = 1000;
activate = 1;
}
if (FreezeEnemy < getTimer()) {
if ((0 < EHealth) && ((JustShot + 1750) < getTimer())) {
JustShot = getTimer();
_parent.attachMovie("SearisEnergy", "SearisEnergy_" + ((10 * placer) + ShotNum), 13000 + ((10 * placer) + ShotNum));
_parent["SearisEnergy_" + ((10 * placer) + ShotNum)].placer = placer;
rot = Math.atan((this._y - _root.clip.char._y) / (this._x - _root.clip.char._x)) * 57.2957795130823;
if ((this._x - _root.clip.char._x) < 0) {
rot = rot + 180;
}
if (((this._x - _root.clip.char._x) >= 0) && ((this._y - _root.clip.char._y) < 0)) {
rot = rot + 360;
}
_parent["SearisEnergy_" + ((10 * placer) + ShotNum)].rot = rot;
ShotNum = ShotNum + 1;
if (ShotNum >= 10) {
ShotNum = 0;
}
}
if ((xspeed == 0) && (this._x < _root.clip.char._x)) {
direct = 1;
} else if ((xspeed == 0) && (_root.clip.char._x < this._x)) {
direct = 2;
}
if (this._x < (_root.clip.char._x - 40)) {
direct = 1;
}
if ((_root.clip.char._x + 40) < this._x) {
direct = 2;
}
if (direct == 1) {
xspeed = speed;
} else if (direct == 2) {
xspeed = -speed;
}
angle = getTimer() / 250;
yspeed = 2.5 * Math.sin(angle);
}
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.active[placer] = 0;
_root.BossesBeaten[4] = 1;
_root.travelling = "forward";
_root.gotoAndPlay(32);
FreezeEnemy = getTimer() + 5000;
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
this.removeMovieClip();
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 30) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 30))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 30) < this._x)) && (this._x < (_root.clip.char._x + 30))) && ((_root.clip.char._y - 50) < this._y)) && (this._y < (_root.clip.char._y + 50))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 7);
} else {
_root.clip.char.PlayerHit("right", 7);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
if (dir == "right") {
xspeed = -2 * speed;
} else {
xspeed = 2 * speed;
}
this.attachMovie("Hit", "Hit", 1);
EHealth = EHealth - 1;
}
}
speed = 5;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 15;
JustHit = getTimer() + 10;
JustShot = getTimer() - 100;
ShotNum = 0;
angle = 0;
activate = 0;
Instance of Symbol 109 MovieClip [empty] in Symbol 331 MovieClip [SearisShade] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 341 MovieClip Frame 2
if (_parent.EHealth < 1) {
gotoAndPlay (11);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 341 MovieClip Frame 4
if (_parent.EHealth < 1) {
gotoAndPlay (11);
} else if (_parent.direct == 1) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 341 MovieClip Frame 23
if (random(10) == 0) {
_root.clip.attachMovie("GCC", "GCC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["GCC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["GCC_" + _parent.placer].ypos = _parent.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("SCC", "SCC_" + _parent.placer, 12000 + _parent.placer);
_root.clip["SCC_" + _parent.placer].xpos = _parent.xpos;
_root.clip["SCC_" + _parent.placer].ypos = _parent.ypos - 10;
}
_parent.removeMovieClip();
Symbol 342 MovieClip [Goblin] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if ((xspeed == 0) && (this._x < _root.clip.char._x)) {
direct = 1;
} else if ((xspeed == 0) && (_root.clip.char._x < this._x)) {
direct = 2;
}
if (this._x < (_root.clip.char._x - 40)) {
direct = 1;
}
if ((_root.clip.char._x + 40) < this._x) {
direct = 2;
}
if (direct == 1) {
xspeed = speed;
} else if (direct == 2) {
xspeed = -speed;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
FreezeEnemy = getTimer() + 5000;
this.removeMovieClip();
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 20) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 20))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 20) < this._x)) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 1);
} else {
_root.clip.char.PlayerHit("right", 1);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
if (dir == "right") {
xspeed = -2 * speed;
} else {
xspeed = 2 * speed;
}
this.attachMovie("Hit", "Hit", 1);
if (WT == 1) {
EHealth = EHealth - 1;
} else {
EHealth = EHealth - 2;
}
}
}
speed = 4;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
direct = 1;
EHealth = 2;
JustHit = getTimer() + 10;
Instance of Symbol 109 MovieClip [empty] in Symbol 342 MovieClip [Goblin] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 348 MovieClip Frame 1
if (_parent.EHealth < 1) {
gotoAndPlay (14);
}
Symbol 348 MovieClip Frame 2
if ((_root.active[0] == 0) && (_root.active[1] == 0)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 348 MovieClip Frame 8
if (_parent.EHealth < 1) {
gotoAndPlay (14);
} else if ((_root.active[0] == 0) && (_root.active[1] == 0)) {
gotoAndPlay (7);
} else {
play();
}
Symbol 348 MovieClip Frame 13
gotoAndPlay (1);
Symbol 348 MovieClip Frame 21
_root.active[placer] = 0;
_root.Gold = _root.Gold + 100;
_root.BossesBeaten[1] = 1;
_root.gotoAndPlay(11);
_parent.removeMovieClip();
Symbol 349 MovieClip [SuperPlant] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
}
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
FreezeEnemy = getTimer() + 5000;
}
if ((_root.active[0] == 0) && (_root.active[1] == 0)) {
if ((((((0 < EHealth) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((0 < EHealth) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((0 < EHealth) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((0 < EHealth) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((0 < EHealth) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((0 < EHealth) && (getTimer() < _root.GuidedStrike)) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((((0 < EHealth) && (_root.Attacking)) && (((_root.clip.char.Strike._x + _root.clip.char._x) - 30) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 30))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((((0 < EHealth) && (_root.Lit)) && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 30) < this._x)) && (this._x < (_root.clip.char._x + 30))) && ((_root.clip.char._y - 30) < this._y)) && (this._y < (_root.clip.char._y + 30))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 2);
} else {
_root.clip.char.PlayerHit("right", 2);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
this.attachMovie("Hit", "Hit", 1);
if (WT == 6) {
EHealth = EHealth - 1;
}
}
}
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
EHealth = 20;
JustHit = getTimer() + 10;
JustShot = getTimer() - 100;
Justdied = getTimer();
ShotNum = 0;
Instance of Symbol 109 MovieClip [empty] in Symbol 349 MovieClip [SuperPlant] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 361 MovieClip Frame 1
if (_parent.EHealth < 1) {
gotoAndPlay (14);
}
Symbol 361 MovieClip Frame 13
gotoAndPlay (1);
Symbol 361 MovieClip Frame 25
if (_parent.EHealth < 1) {
gotoAndPlay (24);
}
Symbol 361 MovieClip Frame 36
gotoAndPlay (1);
Symbol 362 MovieClip [SuperPlant_SideKick] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if ((((JustShot + 1500) < getTimer()) && (Math.abs(this._x - _root.clip.char._x) < 200)) && (Math.abs(this._y - _root.clip.char._y) < 200)) {
JustShot = getTimer();
_parent.attachMovie("SuperPlantshot", "SuperPlantshot_" + ((10 * placer) + ShotNum), 13000 + ((10 * placer) + ShotNum));
_parent["SuperPlantshot_" + ((10 * placer) + ShotNum)].placer = placer;
rot = Math.atan((this._y - _root.clip.char._y) / (this._x - _root.clip.char._x)) * 57.2957795130823;
if ((this._x - _root.clip.char._x) < 0) {
rot = rot + 180;
}
if (((this._x - _root.clip.char._x) >= 0) && ((this._y - _root.clip.char._y) < 0)) {
rot = rot + 360;
}
_parent["SuperPlantshot_" + ((10 * placer) + ShotNum)].rot = rot;
ShotNum = ShotNum + 1;
if (ShotNum >= 10) {
ShotNum = 0;
}
}
}
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
FreezeEnemy = getTimer() + 5000;
_root.active[placer] = 0;
if (Justdied < getTimer()) {
Justdied = getTimer() + 10000;
} else if ((Justdied - 100) < getTimer()) {
EHealth = 5;
_root.active[placer] = 1;
FreezeEnemy = getTimer();
}
}
if ((((((0 < EHealth) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((0 < EHealth) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((0 < EHealth) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((0 < EHealth) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((0 < EHealth) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((0 < EHealth) && (getTimer() < _root.GuidedStrike)) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((((0 < EHealth) && (_root.Attacking)) && (((_root.clip.char.Strike._x + _root.clip.char._x) - 30) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 30))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((((0 < EHealth) && (_root.Lit)) && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 30) < this._x)) && (this._x < (_root.clip.char._x + 30))) && ((_root.clip.char._y - 30) < this._y)) && (this._y < (_root.clip.char._y + 30))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 2);
} else {
_root.clip.char.PlayerHit("right", 2);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
this.attachMovie("Hit", "Hit", 1);
if (WT == 6) {
EHealth = EHealth - 2;
} else {
EHealth = EHealth - 1;
}
}
}
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
EHealth = 5;
JustHit = getTimer() + 10;
JustShot = getTimer() - 100;
Justdied = getTimer();
ShotNum = 0;
Instance of Symbol 109 MovieClip [empty] in Symbol 362 MovieClip [SuperPlant_SideKick] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 373 MovieClip [Plant_anim] Frame 2
if (_parent.EHealth < 1) {
gotoAndPlay (8);
} else if ((_parent._x - _root.clip.char._x) < 0) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 373 MovieClip [Plant_anim] Frame 4
if (_parent.EHealth < 1) {
gotoAndPlay (8);
} else if ((_parent._x - _root.clip.char._x) < 0) {
gotoAndPlay (3);
} else {
gotoAndPlay (1);
}
Symbol 373 MovieClip [Plant_anim] Frame 23
this._alpha = 70;
Symbol 373 MovieClip [Plant_anim] Frame 26
this._alpha = 40;
Symbol 373 MovieClip [Plant_anim] Frame 29
this._alpha = 20;
Symbol 373 MovieClip [Plant_anim] Frame 32
_parent.removeMovieClip();
Symbol 374 MovieClip [Plant] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if ((((0 < EHealth) && ((JustShot + 1500) < getTimer())) && (Math.abs(this._x - _root.clip.char._x) < 200)) && (Math.abs(this._y - _root.clip.char._y) < 200)) {
JustShot = getTimer();
_parent.attachMovie("Plantshot", "Plantshot_" + ((10 * placer) + ShotNum), 13000 + ((10 * placer) + ShotNum));
_parent["Plantshot_" + ((10 * placer) + ShotNum)].placer = placer;
rot = Math.atan((this._y - _root.clip.char._y) / (this._x - _root.clip.char._x)) * 57.2957795130823;
if ((this._x - _root.clip.char._x) < 0) {
rot = rot + 180;
}
if (((this._x - _root.clip.char._x) >= 0) && ((this._y - _root.clip.char._y) < 0)) {
rot = rot + 360;
}
_parent["Plantshot_" + ((10 * placer) + ShotNum)].rot = rot;
ShotNum = ShotNum + 1;
if (ShotNum >= 10) {
ShotNum = 0;
}
}
}
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if ((0 >= EHealth) && (FreezeEnemy < getTimer())) {
if (random(12) == 0) {
_root.clip.attachMovie("ACC", "ACC_" + placer, 12000 + placer);
_root.clip["ACC_" + placer].xpos = this.xpos;
_root.clip["ACC_" + placer].ypos = this.ypos - 10;
} else if (random(3) == 0) {
_root.clip.attachMovie("GCC", "GCC_" + placer, 12000 + placer);
_root.clip["GCC_" + placer].xpos = this.xpos;
_root.clip["GCC_" + placer].ypos = this.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("SCC", "SCC_" + placer, 12000 + placer);
_root.clip["SCC_" + placer].xpos = this.xpos;
_root.clip["SCC_" + placer].ypos = this.ypos - 10;
}
FreezeEnemy = getTimer() + 50000;
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 30) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 30))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if ((((((0 < EHealth) && (!_root.Attacking)) && ((_root.clip.char._x - 20) < this._x)) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 2);
} else {
_root.clip.char.PlayerHit("right", 2);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
this.attachMovie("Hit", "Hit", 1);
if (WT == 6) {
EHealth = EHealth - 2;
} else if (WT == 7) {
EHealth = EHealth - 3;
} else {
EHealth = EHealth - WT;
}
}
}
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
EHealth = 3;
JustHit = getTimer() + 10;
JustShot = getTimer() - 100;
ShotNum = 0;
Die = 0;
Instance of Symbol 373 MovieClip [Plant_anim] in Symbol 374 MovieClip [Plant] Frame 1
onClipEvent (enterFrame) {
if ((_parent.EHealth < 1) && (_root.active[placer] != 0)) {
this._rotation = 0;
_root.active[_parent.placer] = 0;
} else {
ova = (_parent._y - _root.clip.char._y) / (_parent._x - _root.clip.char._x);
this._rotation = Math.atan(ova) * 57.2957795130823;
gotoAndPlay (1);
if ((_parent._x - _root.clip.char._x) < 0) {
this._rotation = this._rotation + 180;
gotoAndPlay (3);
}
if (((_parent._x - _root.clip.char._x) >= 0) && ((_parent._y - _root.clip.char._y) < 0)) {
this._rotation = this._rotation + 360;
gotoAndPlay (1);
}
}
}
Instance of Symbol 109 MovieClip [empty] in Symbol 374 MovieClip [Plant] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 382 MovieClip [Springy2] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if (onGround && ((justLandedTimer + 100) < getTimer())) {
yspeed = -jumpspeed;
if (this._x < _root.clip.char._x) {
xspeed = speed;
} else if (_root.clip.char._x < this._x) {
xspeed = -speed;
}
airmotion = xspeed;
}
if (!onGround) {
xspeed = airmotion;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
if (random(6) == 0) {
_root.clip.attachMovie("ACC", "ACC_" + placer, 12000 + placer);
_root.clip["ACC_" + placer].xpos = this.xpos;
_root.clip["ACC_" + placer].ypos = this.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("GCC", "GCC_" + placer, 12000 + placer);
_root.clip["GCC_" + placer].xpos = this.xpos;
_root.clip["GCC_" + placer].ypos = this.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("SCC", "SCC_" + placer, 12000 + placer);
_root.clip["SCC_" + placer].xpos = this.xpos;
_root.clip["SCC_" + placer].ypos = this.ypos - 10;
}
_root.active[placer] = 0;
this.removeMovieClip();
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
this.removeMovieClip();
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 20) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 20))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if (((((!_root.Attacking) && ((_root.clip.char._x - 20) < this._x)) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 6);
} else {
_root.clip.char.PlayerHit("right", 6);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
if (dir == "right") {
xspeed = -2 * speed;
} else {
xspeed = 2 * speed;
}
this.attachMovie("Hit", "Hit", 1);
if (WT == 6) {
EHealth = EHealth - 2;
} else if (WT == 7) {
EHealth = EHealth - 4;
} else {
EHealth = EHealth - WT;
}
}
}
speed = 4;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
EHealth = 20;
JustHit = getTimer() + 10;
Instance of Symbol 109 MovieClip [empty] in Symbol 382 MovieClip [Springy2] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 383 MovieClip [Springy] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
LastHit = JustHit;
if (_root.Paused < getTimer()) {
if (FreezeEnemy < getTimer()) {
if (onGround && ((justLandedTimer + 100) < getTimer())) {
yspeed = -jumpspeed;
if (this._x < _root.clip.char._x) {
xspeed = speed;
} else if (_root.clip.char._x < this._x) {
xspeed = -speed;
}
airmotion = xspeed;
}
if (!onGround) {
xspeed = airmotion;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
}
onGround = true;
} else {
onGround = false;
}
if (0 >= EHealth) {
if (random(10) == 0) {
_root.clip.attachMovie("ACC", "ACC_" + placer, 12000 + placer);
_root.clip["ACC_" + placer].xpos = this.xpos;
_root.clip["ACC_" + placer].ypos = this.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("GCC", "GCC_" + placer, 12000 + placer);
_root.clip["GCC_" + placer].xpos = this.xpos;
_root.clip["GCC_" + placer].ypos = this.ypos - 10;
} else if (random(2) == 0) {
_root.clip.attachMovie("SCC", "SCC_" + placer, 12000 + placer);
_root.clip["SCC_" + placer].xpos = this.xpos;
_root.clip["SCC_" + placer].ypos = this.ypos - 10;
}
_root.active[placer] = 0;
this.removeMovieClip();
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
this.removeMovieClip();
}
if ((((((_root.clip.FB_fireball_0.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_0._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_0._x + 20))) && ((_root.clip.FB_fireball_0._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_0._y + 20))) {
_root.clip.FB_fireball_0.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_1.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_1._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_1._x + 20))) && ((_root.clip.FB_fireball_1._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_1._y + 20))) {
_root.clip.FB_fireball_1.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_2.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_2._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_2._x + 20))) && ((_root.clip.FB_fireball_2._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_2._y + 20))) {
_root.clip.FB_fireball_2.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_3.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_3._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_3._x + 20))) && ((_root.clip.FB_fireball_3._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_3._y + 20))) {
_root.clip.FB_fireball_3.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if ((((((_root.clip.FB_fireball_4.dying == 0) && ((JustHit + 400) < getTimer())) && ((_root.clip.FB_fireball_4._x - 20) < this._x)) && (this._x < (_root.clip.FB_fireball_4._x + 20))) && ((_root.clip.FB_fireball_4._y - 20) < this._y)) && (this._y < (_root.clip.FB_fireball_4._y + 20))) {
_root.clip.FB_fireball_4.gotoAndPlay(4);
if (this._x < _root.clip.char._x) {
ImHit("right", 6);
} else {
ImHit("left", 6);
}
}
if (getTimer() < _root.GuidedStrike) {
if (this._x < _root.clip.char._x) {
ImHit("right", 1);
} else {
ImHit("left", 1);
}
}
if ((((_root.Attacking && (((_root.clip.char.Strike._x + _root.clip.char._x) - 20) < this._x)) && (this._x < ((_root.clip.char.Strike._x + _root.clip.char._x) + 20))) && (((_root.clip.char.Strike._y + _root.clip.char._y) - 30) < this._y)) && (this._y < ((_root.clip.char.Strike._y + _root.clip.char._y) + 30))) {
if (this._x < _root.clip.char._x) {
ImHit("right", _root.WeaponType);
} else {
ImHit("left", _root.WeaponType);
}
} else if ((((_root.Lit && (((_root.clip.char.L_Bolt._x + _root.clip.char._x) - 50) < this._x)) && (this._x < ((_root.clip.char.L_Bolt._x + _root.clip.char._x) + 50))) && (((_root.clip.char.L_Bolt._y + _root.clip.char._y) - 50) < this._y)) && (this._y < ((_root.clip.char.L_Bolt._y + _root.clip.char._y) + 50))) {
if (this._x < _root.clip.char._x) {
ImHit("right", 7);
} else {
ImHit("left", 7);
}
} else if (((((!_root.Attacking) && ((_root.clip.char._x - 20) < this._x)) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 2);
} else {
_root.clip.char.PlayerHit("right", 2);
}
}
this.render();
}
}
function ImHit(dir, WT) {
if ((JustHit + 150) < getTimer()) {
JustHit = getTimer();
FreezeEnemy = getTimer() + 400;
if (dir == "right") {
xspeed = -2 * speed;
} else {
xspeed = 2 * speed;
}
this.attachMovie("Hit", "Hit", 1);
if (WT == 6) {
EHealth = EHealth - 2;
} else if (WT == 7) {
EHealth = EHealth - 4;
} else {
EHealth = EHealth - WT;
}
}
}
speed = 4;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
EHealth = 7;
JustHit = getTimer() + 10;
Instance of Symbol 109 MovieClip [empty] in Symbol 383 MovieClip [Springy] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 389 MovieClip Frame 1
if (_root.WeaponType == 2) {
gotoAndPlay ("Sword");
}
if (_root.WeaponType == 3) {
gotoAndPlay ("Silver Sword");
}
if (_root.WeaponType == 4) {
gotoAndPlay ("Magic Sword");
}
if (_root.WeaponType == 5) {
gotoAndPlay ("Imbued Sword");
}
Symbol 389 MovieClip Frame 2
gotoAndPlay ("Dagger");
Symbol 389 MovieClip Frame 3
if (_root.WeaponType == 1) {
gotoAndPlay ("Dagger");
}
if (_root.WeaponType == 3) {
gotoAndPlay ("Silver Sword");
}
if (_root.WeaponType == 4) {
gotoAndPlay ("Magic Sword");
}
if (_root.WeaponType == 5) {
gotoAndPlay ("Imbued Sword");
}
Symbol 389 MovieClip Frame 4
gotoAndPlay ("Sword");
Symbol 389 MovieClip Frame 5
if (_root.WeaponType == 1) {
gotoAndPlay ("Dagger");
}
if (_root.WeaponType == 2) {
gotoAndPlay ("Sword");
}
if (_root.WeaponType == 4) {
gotoAndPlay ("Magic Sword");
}
if (_root.WeaponType == 5) {
gotoAndPlay ("Imbued Sword");
}
Symbol 389 MovieClip Frame 6
gotoAndPlay ("Silver Sword");
Symbol 389 MovieClip Frame 7
if (_root.WeaponType == 1) {
gotoAndPlay ("Dagger");
}
if (_root.WeaponType == 3) {
gotoAndPlay ("Silver Sword");
}
if (_root.WeaponType == 4) {
gotoAndPlay ("Magic Sword");
}
if (_root.WeaponType == 5) {
gotoAndPlay ("Imbued Sword");
}
Symbol 389 MovieClip Frame 8
gotoAndPlay ("Magic Sword");
Symbol 389 MovieClip Frame 9
if (_root.WeaponType == 1) {
gotoAndPlay ("Dagger");
}
if (_root.WeaponType == 2) {
gotoAndPlay ("Sword");
}
if (_root.WeaponType == 3) {
gotoAndPlay ("Silver Sword");
}
if (_root.WeaponType == 4) {
gotoAndPlay ("Magic Sword");
}
Symbol 389 MovieClip Frame 10
gotoAndPlay ("Imbued Sword");
Symbol 463 MovieClip [c_anim] Frame 2
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.facing == 2) {
gotoAndPlay (15);
} else if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
gotoAndPlay (30);
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 3
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (13);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (90);
} else if (_parent.facing == 2) {
gotoAndPlay (25);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 4
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (13);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (90);
} else if (_parent.facing == 2) {
gotoAndPlay (25);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 5
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (13);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (90);
} else if (_parent.facing == 2) {
gotoAndPlay (25);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 6
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (13);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (90);
} else if (_parent.facing == 2) {
gotoAndPlay (25);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 7
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (13);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (90);
} else if (_parent.facing == 2) {
gotoAndPlay (25);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 8
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (13);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (90);
} else if (_parent.facing == 2) {
gotoAndPlay (25);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 9
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (13);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (90);
} else if (_parent.facing == 2) {
gotoAndPlay (25);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 10
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (13);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (90);
} else if (_parent.facing == 2) {
gotoAndPlay (25);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 11
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (13);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (90);
} else if (_parent.facing == 2) {
gotoAndPlay (25);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 12
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (13);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (90);
} else if (_parent.facing == 2) {
gotoAndPlay (25);
} else {
gotoAndPlay (11);
}
Symbol 463 MovieClip [c_anim] Frame 14
gotoAndPlay (1);
Symbol 463 MovieClip [c_anim] Frame 16
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.facing == 1) {
gotoAndPlay (1);
} else if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
gotoAndPlay (48);
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 17
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (27);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (100);
} else if (_parent.facing == 1) {
gotoAndPlay (11);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 18
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (27);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (100);
} else if (_parent.facing == 1) {
gotoAndPlay (11);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 19
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (27);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (100);
} else if (_parent.facing == 1) {
gotoAndPlay (11);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 20
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (27);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (100);
} else if (_parent.facing == 1) {
gotoAndPlay (11);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 21
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (27);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (100);
} else if (_parent.facing == 1) {
gotoAndPlay (11);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 22
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (27);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (100);
} else if (_parent.facing == 1) {
gotoAndPlay (11);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 23
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (27);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (100);
} else if (_parent.facing == 1) {
gotoAndPlay (11);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 24
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (27);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (100);
} else if (_parent.facing == 1) {
gotoAndPlay (11);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 25
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (27);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (100);
} else if (_parent.facing == 1) {
gotoAndPlay (11);
} else {
play();
}
Symbol 463 MovieClip [c_anim] Frame 26
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (_parent.onGround) {
gotoAndPlay (27);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (100);
} else if (_parent.facing == 1) {
gotoAndPlay (11);
} else {
gotoAndPlay (25);
}
Symbol 463 MovieClip [c_anim] Frame 28
gotoAndPlay (15);
Symbol 463 MovieClip [c_anim] Frame 30
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 31
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 32
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 33
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 34
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 35
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 36
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 37
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 38
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 39
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 40
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 41
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 42
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 43
if (!_parent.onGround) {
gotoAndPlay (3);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (70);
} else if (Key.isDown(39)) {
play();
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 44
gotoAndPlay (30);
Symbol 463 MovieClip [c_anim] Frame 48
if (_root.Health < 1) {
this.gotoAndPlay(110);
} else if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 49
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 50
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 51
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 52
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 53
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 54
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 55
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 56
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 57
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 58
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 59
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 60
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 61
if (!_parent.onGround) {
gotoAndPlay (17);
} else if (_parent.Slash == true) {
_parent.Slash = false;
gotoAndPlay (80);
} else if (Key.isDown(37)) {
play();
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 62
gotoAndPlay (48);
Symbol 463 MovieClip [c_anim] Frame 75
if (!_parent.onGround) {
gotoAndPlay (11);
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 85
if (!_parent.onGround) {
gotoAndPlay (25);
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 95
if (!_parent.onGround) {
gotoAndPlay (11);
} else {
gotoAndPlay (1);
}
Symbol 463 MovieClip [c_anim] Frame 105
if (!_parent.onGround) {
gotoAndPlay (25);
} else {
gotoAndPlay (15);
}
Symbol 463 MovieClip [c_anim] Frame 119
stop();
Symbol 464 MovieClip [char] Frame 1
function render() {
_y = Math.round(ypos);
_x = Math.round(xpos);
}
function updateEdges() {
downY = Math.floor((ypos + 15) / tileH);
upY = Math.floor((ypos - 15) / tileH);
leftX = Math.floor((xpos - 15) / tileW);
rightX = Math.floor((xpos + 15) / tileW);
downY2 = Math.floor((ypos + 14) / tileH);
upY2 = Math.floor((ypos - 14) / tileH);
}
function control(dir) {
if (_root.Paused < getTimer()) {
if (FreezePlayer < getTimer()) {
if (getTimer() < SpeedBoost) {
speed = 15;
} else {
speed = 5;
}
if ((Key.isDown(38) && (onGround)) && ((justLandedTimer + 100) < getTimer())) {
yspeed = -jumpspeed;
}
if ((((!Key.isDown(38)) && (_root.CurrentSkill != 4)) && (!onGround)) && (yspeed < 0)) {
yspeed = 0;
}
if (Key.isDown(37)) {
xspeed = -speed;
facing = 2;
}
if (Key.isDown(39)) {
xspeed = speed;
facing = 1;
}
if (Key.isDown(32) && ((ChangedWeapTimer + 200) < getTimer())) {
_root.WeaponType++;
ChangedWeapTimer = getTimer();
if (_root.MaxWeap < _root.WeaponType) {
_root.WeaponType = 1;
}
}
if ((Key.isDown(80) && (_root.Health < 50)) && ((UsedPotion + 200) < getTimer())) {
UsedPotion = getTimer();
if (_root.Health >= 30) {
if (0 < _root.PotionS) {
_root.PotionS--;
_root.Health = 50;
} else if (0 < _root.PotionM) {
_root.PotionM--;
_root.Health = 50;
} else if (0 < _root.PotionL) {
_root.PotionL--;
_root.Health = 50;
}
} else if (_root.Health >= 15) {
if (0 < _root.PotionM) {
_root.PotionM--;
_root.Health = 50;
} else if (0 < _root.PotionL) {
_root.PotionL--;
_root.Health = 50;
} else if (0 < _root.PotionS) {
_root.PotionS--;
_root.Health = _root.Health + 20;
}
} else if (0 < _root.PotionL) {
_root.PotionL--;
_root.Health = 50;
} else if (0 < _root.PotionM) {
_root.PotionM--;
_root.Health = _root.Health + 35;
} else if (0 < _root.PotionS) {
_root.PotionS--;
_root.Health = _root.Health + 20;
}
}
if (Key.isDown(83) && ((justAttackedTimer + 400) < getTimer())) {
if (2 >= _root.WeaponType) {
justAttackedTimer = getTimer();
FreezePlayer = getTimer() + 400;
if (onGround) {
xspeed = 0;
}
Slash = true;
this.attachMovie("Sstrike", "Strike", 0);
_root.SEffect.attachSound("SE_Strike");
_root.SEffect.start(0, 1);
}
if (_root.WeaponType == 3) {
justAttackedTimer = getTimer();
FreezePlayer = getTimer() + 400;
if (onGround) {
xspeed = 0;
}
Slash = true;
this.attachMovie("SSstrike", "Strike", 0);
_root.SEffect.attachSound("SE_Strike");
_root.SEffect.start(0, 1);
}
if (_root.WeaponType == 4) {
justAttackedTimer = getTimer();
FreezePlayer = getTimer() + 400;
if (onGround) {
xspeed = 0;
}
Slash = true;
this.attachMovie("Mstrike", "Strike", 0);
_root.SEffect.attachSound("SE_Strike");
_root.SEffect.start(0, 1);
}
if (_root.WeaponType == 5) {
justAttackedTimer = getTimer();
FreezePlayer = getTimer() + 400;
if (onGround) {
xspeed = 0;
}
Slash = true;
this.attachMovie("Istrike", "Strike", 0);
_root.SEffect.attachSound("SE_Strike");
_root.SEffect.start(0, 1);
}
}
if (Key.isDown(68) && (FreezeSkills < getTimer())) {
if ((_root.CurrentSkill == 1) && (_root.Magic >= 5)) {
FreezeSkills = getTimer() + 400;
_root.Magic = _root.Magic - 5;
_root.clip.attachMovie("FB_fireball", "FB_fireball_" + FireCounter, 20002 + FireCounter);
_root.SEffect.attachSound("SE_Fireball");
_root.SEffect.start(0, 1);
FireCounter++;
if (FireCounter >= 5) {
FireCounter = 0;
}
}
if (((_root.CurrentSkill == 2) && (onGround)) && (_root.Magic >= 10)) {
if (speed == 5) {
_root.Magic = _root.Magic - 10;
this.attachMovie("S_Speedburst_Collage", "S_Speedburst_Collage", 7);
SpeedBoost = getTimer() + 750;
FreezeSkills = getTimer() + 300;
}
}
if (((_root.CurrentSkill == 3) && (_root.Magic >= 3)) && (_root.Health < 50)) {
FreezeSkills = getTimer() + 125;
_root.Magic = _root.Magic - 3;
_root.Health = _root.Health + 1;
this.attachMovie("H_Aura", "H_Aura", 8);
}
if ((((_root.CurrentSkill == 4) && (onGround)) && ((justLandedTimer + 100) < getTimer())) && (_root.Magic >= 10)) {
FreezeSkills = getTimer() + 600;
_root.Magic = _root.Magic - 10;
this.attachMovie("SJ_smoke", "SJ_smoke", 9);
_root.SEffect.attachSound("SE_SJ");
_root.SEffect.start(0, 1);
yspeed = -2 * jumpspeed;
}
if ((_root.CurrentSkill == 5) && (_root.Magic >= 10)) {
FreezeSkills = getTimer() + 400;
_root.Magic = _root.Magic - 10;
this.attachMovie("L_Bolt", "L_Bolt", 10);
_root.SEffect.attachSound("SE_Lit");
_root.SEffect.start(0, 1);
}
if ((_root.CurrentSkill == 6) && (_root.Magic >= 15)) {
FreezeSkills = getTimer() + 400;
Slash = true;
_root.Magic = _root.Magic - 15;
this.attachMovie("GS_Flash", "GS_Flash", 11);
this.GS_Flash._alpha = 50;
_root.GuidedStrike = getTimer() + 100;
}
}
if (Key.isDown(49) && (_root.Skill1Active == 1)) {
_root.CurrentSkill = 1;
}
if (Key.isDown(50) && (_root.Skill2Active == 1)) {
_root.CurrentSkill = 2;
}
if (Key.isDown(51) && (_root.Skill3Active == 1)) {
_root.CurrentSkill = 3;
}
if (Key.isDown(52) && (_root.Skill4Active == 1)) {
_root.CurrentSkill = 4;
}
if (Key.isDown(53) && (_root.Skill5Active == 1)) {
_root.CurrentSkill = 5;
}
if (Key.isDown(54) && (_root.Skill6Active == 1)) {
_root.CurrentSkill = 6;
}
}
yspeed = yspeed + gravity;
if (!onGround) {
yspeed = yspeed * airFriction;
}
if (onGround) {
xspeed = xspeed * groundFriction;
}
ypos = ypos + yspeed;
xpos = xpos + xspeed;
updateEdges();
if (((9 < cMap[downY2][leftX]) && (cMap[downY2][leftX] < 50)) || ((9 < cMap[upY2][leftX]) && (cMap[upY2][leftX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
if (((9 < cMap[downY2][rightX]) && (cMap[downY2][rightX] < 50)) || ((9 < cMap[upY2][rightX]) && (cMap[upY2][rightX] < 50))) {
xpos = xpos - xspeed;
xspeed = 0;
updateEdges();
}
m = 100;
while (m < 130) {
if ((((cMap[downY2][leftX] == m) || (cMap[upY2][leftX] == m)) || (cMap[downY2][rightX] == m)) || (cMap[upY2][rightX] == m)) {
if (_root._currentframe < (m - 97)) {
_root.travelling = "forward";
} else {
_root.travelling = "back";
}
_root.gotoAndPlay(m - 97);
}
m++;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 131) || (cMap[upY2][leftX] == 131)) || (cMap[downY2][rightX] == 131)) || (cMap[upY2][rightX] == 131))) {
if (_root.Skill2Active == 0) {
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
_root.Event.EventData = [[4, "BattleMage spell books. These should be useful."], [4, "The Mark of Gale: gives the user the ability to overcome obstacles in times of need."], [4, "This looks complex, but I think I can handle it. Just give me some time..."], [4, "JOSH EARNS THE MARK OF GALE!!!"], [4, "What a strange spell... there's an emblem on my forearm now that matches the one in this book. It must have worked."], [4, "Now, I wonder what else can I learn from these books?"], [4, "JOSH LEARNS SPEED!!!"], [4, "JOSH LEARNS HEAL!!!"], [4, "These should be very handy! I'll be able to make longer jumps, and heal up whenever I take a breather!"], [0, " "]];
_root.Skill2Active = 1;
_root.Skill3Active = 1;
_root.Paused = getTimer() + 99999999;
}
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 132) || (cMap[upY2][leftX] == 132)) || (cMap[downY2][rightX] == 132)) || (cMap[upY2][rightX] == 132))) {
PCA = int((((_root.Gold + (_root.MaxWeap * 100000)) + (_root.PotionL * 1000000)) + (_root.PotionM * 10000000)) + (_root.PotionS * 100000000)) * 7;
PCB = int(((((_root.Skill1Active + (_root.Skill2Active * 2)) + (_root.Skill3Active * 4)) + (_root.Skill4Active * 8)) + (_root.Skill5Active * 16)) + (_root.Skill6Active * 32));
PCB = PCB + int(_root._currentframe * 100);
PCB = PCB + int(_root.Health * 10000);
PCB = PCB * 307;
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
_root.Event.EventData = [[2, (("Your PassCode is:\r" + PCA) + "-") + PCB], [0, " "]];
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 134) || (cMap[upY2][leftX] == 134)) || (cMap[downY2][rightX] == 134)) || (cMap[upY2][rightX] == 134))) {
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
_root.Event.EventData = [[3, "Thanks again for saving me. My grandfather is just ahead, waiting to speak with you."], [3, "Also, if you are going into the swamp, be wary of the waters; they are poisonous, and will sap your strength if you touch them."], [0, " "]];
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 135) || (cMap[upY2][leftX] == 135)) || (cMap[downY2][rightX] == 135)) || (cMap[upY2][rightX] == 135))) {
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
if (_root.Skill1Active == 0) {
_root.Event.EventData = [[5, "You are the one who saved my daughter, yes? I owe you a great debt."], [4, "It was nothing, sir; but I was wondering what you could tell me of the BattleMages?"], [5, "Ah yes, she did mention you asking about that. As you probably know, the BattleMages were an elite group of warrior-spellcasters, sworn to defend the kingdom from all enemies."], [5, "They generally only fought the most dangerous foes, those that only they could bring down. Some of the evil they fought is better left buried and unmentioned."], [5, "Searis, the leader of the BattleMages when they vanished, was said to have faced Demon Lords and banished them back to whatever Hell they spawned from."], [5, "One day, however, the evils of this world succeeded in defeating the BattleMages in one fell swoop; years ago, a burst of green light took all the souls within the walls of the Keep."], [5, "There were no bodies, but things have deteriorated in the kingdom nonetheless in their absence."], [5, "I have even heard rumors that undead are returning; an evil the BattleMages warded against with powerful magic."], [4, "So their old wards are weakening?"], [5, "It would appear so. Soon vandals will become bold enough to try the shields that prevent the Keep from being robbed, and then the old magics will likely be lost to all."], [4, "Speaking of that, your daughter mentioned you know some minor magics."], [5, "Indeed I do. Would you like to learn some? It may help you pass through the swamp."], [4, "That would be most helpful, thank you!"], [1, "JOSH LEARNS FIREBALL!!!"], [5, "Return here should you need guidance; if I can, I will help you find your way."], [0, " "]];
_root.Skill1Active = 1;
} else if ((_root.Skill2Active == 1) && (_root.Skill4Active == 0)) {
_root.Event.EventData = [[4, "What should I do now?"], [5, "Your new magic should allow you to enter Pecal, and find the source of the evil there."], [4, "Thanks, I won't let you down!"], [0, " "]];
} else if ((_root.Skill4Active == 1) && (_root.MaxWeap < 4)) {
_root.Event.EventData = [[4, "Searis is alive! What should I do now?"], [5, "Explore the keep; if Searis is the cause of all this, there should be clues as to where to find him."], [4, "Thanks, I'll go explore."], [5, "Be careful! Searis would have prepared for just such an event. There will likely be powerful traps."], [4, "I'll be careful, don't worry. Searis has to be stopped!"], [0, " "]];
} else {
_root.Event.EventData = [[5, "I can do nothing for you right now. Best of luck to you, my boy."], [0, " "]];
}
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 136) || (cMap[upY2][leftX] == 136)) || (cMap[downY2][rightX] == 136)) || (cMap[upY2][rightX] == 136))) {
_root.attachMovie("StoreBox", "Store", 25011);
_root.Store._x = 365;
_root.Store._y = 230;
_root.Store.StoreList = [["Small Potion", 50], ["Stay at Inn", 20]];
_root.Store.Face = 6;
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 137) || (cMap[upY2][leftX] == 137)) || (cMap[downY2][rightX] == 137)) || (cMap[upY2][rightX] == 137))) {
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
_root.Event.EventData = [[7, "We have a limited supply of silver here, and so our weapons are expensive; Pecal sells silvered weapons at a much cheaper price."], [0, " "]];
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 138) || (cMap[upY2][leftX] == 138)) || (cMap[downY2][rightX] == 138)) || (cMap[upY2][rightX] == 138))) {
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
_root.Event.EventData = [[8, "The path diverges just outside of town. Going east will take you to Pecal, past the plains. Go north into the highlands to reach BattleMage Keep."], [0, " "]];
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 139) || (cMap[upY2][leftX] == 139)) || (cMap[downY2][rightX] == 139)) || (cMap[upY2][rightX] == 139))) {
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
_root.Event.EventData = [[9, "Be wary when traversing the highlands; there are werebeasts that are impervious to ordinary steel."], [0, " "]];
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 140) || (cMap[upY2][leftX] == 140)) || (cMap[downY2][rightX] == 140)) || (cMap[upY2][rightX] == 140))) {
_root.attachMovie("StoreBox", "Store", 25011);
_root.Store._x = 365;
_root.Store._y = 230;
_root.Store.StoreList = [["Small Potion", 50], ["Medium Potion", 100], ["Stay at Inn", 30]];
_root.Store.Face = 10;
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 141) || (cMap[upY2][leftX] == 141)) || (cMap[downY2][rightX] == 141)) || (cMap[upY2][rightX] == 141))) {
_root.attachMovie("StoreBox", "Store", 25011);
_root.Store._x = 365;
_root.Store._y = 230;
_root.Store.StoreList = [["Sword", 250], ["Silver Sword", 5000]];
_root.Store.Face = 11;
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 142) || (cMap[upY2][leftX] == 142)) || (cMap[downY2][rightX] == 142)) || (cMap[upY2][rightX] == 142))) {
_root.attachMovie("StoreBox", "Store", 25011);
_root.Store._x = 365;
_root.Store._y = 230;
_root.Store.StoreList = [["Small Potion", 50], ["Medium Potion", 100], ["Sword", 225], ["Silver Sword", 375]];
_root.Store.Face = 12;
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 143) || (cMap[upY2][leftX] == 143)) || (cMap[downY2][rightX] == 143)) || (cMap[upY2][rightX] == 143))) {
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
_root.Event.EventData = [[13, "I'm sorry, but Pecal has been quarentined."], [13, "There have been rumors that undead have broken out of the cemetary, but the city guard are taking care of the situation, don't worry."], [4, "But how can the city guard handle undead without the BattleMages?"], [13, "We can take care of things fine on our own. Move along."], [4, "(I better find a way into the city...)"], [0, " "]];
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 144) || (cMap[upY2][leftX] == 144)) || (cMap[downY2][rightX] == 144)) || (cMap[upY2][rightX] == 144))) {
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
_root.Event.EventData = [[4, "This is a statue of Searis, leader of the BattleMages. He doesn't look much older than me in this carving."], [0, " "]];
_root.Paused = getTimer() + 99999999;
}
if ((((cMap[downY2][leftX] == 145) || (cMap[upY2][leftX] == 145)) || (cMap[downY2][rightX] == 145)) || (cMap[upY2][rightX] == 145)) {
_root.travelling = "forward";
_root.BossesBeaten[3] = 1;
_root.Skill4Active = 1;
_root.gotoAndPlay(64);
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 146) || (cMap[upY2][leftX] == 146)) || (cMap[downY2][rightX] == 146)) || (cMap[upY2][rightX] == 146))) {
if (_root.Skill5Active == 0) {
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
_root.Event.EventData = [[4, "Finally, more BattleMage spell books! I'm sure these will come in handy."], [4, "JOSH LEARNS LIGHTNING!!!"], [4, "JOSH LEARNS GUIDED STRIKE!!!"], [0, " "]];
_root.Skill5Active = 1;
_root.Skill6Active = 1;
_root.Paused = getTimer() + 99999999;
_root.gotoAndPlay(26);
}
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 147) || (cMap[upY2][leftX] == 147)) || (cMap[downY2][rightX] == 147)) || (cMap[upY2][rightX] == 147))) {
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
_root.Event.EventData = [[4, "Sage! What are you doing here?"], [5, "Waiting for you. You have come far, but there is still far to go."], [4, "I know. Searis is hiding in the Mists; his shade told me a lot before it tried to kill me."], [5, "You should know; there are creatures in the Mists that cannot be harmed by manmade weapons."], [4, "Then what can I do?"], [5, "Avoid them if you can; see if you can find the Fairies, they may help you."], [4, "Fairies? There are really Fairies in the Mists?"], [5, "Yes; they are some of the tamer creatures lurking there. If you amuse them, they are harmless."], [4, "What if I don't amuse them?"], [5, "Then they will probably kill you. I have confidence you will find a way."], [4, "Let's hope. Thanks for all your help; I'm going to finish this fight, if I can."], [0, " "]];
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 148) || (cMap[upY2][leftX] == 148)) || (cMap[downY2][rightX] == 148)) || (cMap[upY2][rightX] == 148))) {
_root.attachMovie("StoreBox", "Store", 25011);
_root.Store._x = 365;
_root.Store._y = 230;
_root.Store.StoreList = [["Small Potion", 50], ["Medium Potion", 100], ["Large Potion", 200], ["Stay at Inn", 45]];
_root.Store.Face = 14;
_root.Paused = getTimer() + 99999999;
}
if (((_root.EventEnded + 2000) < getTimer()) && ((((cMap[downY2][leftX] == 151) || (cMap[upY2][leftX] == 151)) || (cMap[downY2][rightX] == 151)) || (cMap[upY2][rightX] == 151))) {
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
_root.Event.EventData = [[4, "What the? Faeries?"], [16, "Ooh, a human! How neat!"], [4, "I must pass this way. I am looking for..."], [16, "Boring! Human things are soooo boring. How about a game?"], [4, "I don't have time for a game!"], [16, "Ugh, mean human. Mean boring human should be hurt for not playing."], [4, "OK! I'll play. What's the game?"], [16, "A race, silly! You're so fast and powerful, but I bet you can't beat yourself!"], [4, "Myself? Alright, what are the stakes?"], [16, "You win, we help you with boring human quest. We win, we see how you look all stabby."], [4, "Then I better not lose. Alright, let's go!"], [0, " "]];
_root.Paused = getTimer() + 99999999;
}
if ((((_root.EventEnded + 2000) < getTimer()) && (_root.MaxWeap < 5)) && ((((cMap[downY2][leftX] == 152) || (cMap[upY2][leftX] == 152)) || (cMap[downY2][rightX] == 152)) || (cMap[upY2][rightX] == 152))) {
_root.attachMovie("EventBox", "Event", 25010);
_root.Event._x = 365;
_root.Event._y = 125;
_root.Event.EventData = [[16, "Poo, you win. Ok, we give you help."], [4, "I need to get through the Mists to find Searis, but I can't hit anything!"], [16, "Dumb human weapons don't work here! You need our help. Here!"], [4, "JOSH'S BLADE IS IMBUED!!!"], [16, "There, that will hurt nasty Mist beasts, and hit stupid normal beasts harder, too."], [4, "Thank you for your..."], [16, "Human boring again. Go do silly human quest! We're going to find something more interesting."], [4, "Well, that was... strange. But I'm here, with the power to fight back. Time to pay, Searis."], [0, " "]];
_root.Paused = getTimer() + 99999999;
_root.BossesBeaten[6] = 1;
_root.MaxWeap = 5;
_root.WeaponType = 5;
}
if (((JustDrained + 500) < getTimer()) && ((((cMap[upY2][leftX] == 200) || (cMap[upY2][rightX] == 200)) || (cMap[upY2][leftX] == 202)) || (cMap[upY2][rightX] == 202))) {
_root.Health = _root.Health - 1;
JustDrained = getTimer();
}
if (((JustDrained + 100) < getTimer()) && ((((cMap[upY2][leftX] == 201) || (cMap[upY2][rightX] == 201)) || (cMap[upY2][leftX] == 203)) || (cMap[upY2][rightX] == 203))) {
_root.Health = _root.Health - 1;
JustDrained = getTimer();
}
if ((cMap[upY2][leftX] == 205) || (cMap[upY2][rightX] == 205)) {
PlayerHit("none", 2);
}
if ((cMap[upY2][leftX] == 206) || (cMap[upY2][rightX] == 206)) {
PlayerHit("none", 6);
}
m = 220;
while (m < 260) {
if ((((cMap[downY2][leftX] == m) || (cMap[upY2][leftX] == m)) || (cMap[downY2][rightX] == m)) || (cMap[upY2][rightX] == m)) {
if (_root._currentframe < (m - 190)) {
_root.travelling = "forward";
} else {
_root.travelling = "back";
}
_root.gotoAndPlay(m - 190);
}
m++;
}
if ((cMap[upY2][leftX] == 500) || (cMap[upY2][rightX] == 500)) {
}
if (((9 < cMap[upY][leftX]) && (cMap[upY][leftX] < 50)) || ((9 < cMap[upY][rightX]) && (cMap[upY][rightX] < 50))) {
var roof = ((upY * tileH) + (tileH * 1.5));
ypos = roof - gravity;
yspeed = 0;
}
if (((9 < cMap[downY][leftX]) && (cMap[downY][leftX] < 50)) || ((9 < cMap[downY][rightX]) && (cMap[downY][rightX] < 50))) {
var ground = ((downY * tileH) - (tileH / 2));
ypos = ground + gravity;
yspeed = 0;
if (!onGround) {
justLandedTimer = getTimer();
if (facing == 1) {
c_anim.gotoAndPlay(1);
} else if (facing == 2) {
c_anim.gotoAndPlay(15);
}
}
onGround = true;
} else {
onGround = false;
}
if (_root.Health < 1) {
_root.Paused = getTimer() + 999999;
_root.attachMovie("GameOver", "GameOver", 20001);
_root.GameOver._x = 365;
_root.GameOver._y = 224;
_root.GameOver.play();
}
this.render();
}
if (5 < (this._x - _root.CenterMark._x)) {
_root.doScroll("right");
} else if ((this._x - _root.CenterMark._x) < -5) {
_root.doScroll("left");
}
if (5 < (this._y - _root.CenterMark._y)) {
_root.doScroll("down");
} else if ((this._y - _root.CenterMark._y) < -5) {
_root.doScroll("up");
}
if (25 < (this._y - _root.CenterMark._y)) {
_root.doScroll("down");
} else if ((this._y - _root.CenterMark._y) < -25) {
_root.doScroll("up");
}
if (25 < (this._x - _root.CenterMark._x)) {
_root.doScroll("right");
} else if ((this._x - _root.CenterMark._x) < -25) {
_root.doScroll("left");
}
if (55 < (this._y - _root.CenterMark._y)) {
_root.doScroll("down");
} else if ((this._y - _root.CenterMark._y) < -55) {
_root.doScroll("up");
}
if (55 < (this._x - _root.CenterMark._x)) {
_root.doScroll("right");
} else if ((this._x - _root.CenterMark._x) < -55) {
_root.doScroll("left");
}
}
function PlayerHit(dir, Damage) {
if ((LastHit + 600) < getTimer()) {
LastHit = getTimer();
FreezePlayer = getTimer() + 200;
if (0 < Damage) {
if (dir == "right") {
xspeed = -speed;
} else if (dir == "left") {
xspeed = speed;
}
this.attachMovie("Hit", "Hit", 1);
_root.Health = _root.Health - Damage;
} else {
if (dir == "right") {
xspeed = -10 * speed;
} else {
xspeed = 10 * speed;
}
this.attachMovie("Hit", "Hit", 1);
_root.Health = _root.Health + Damage;
}
}
}
speed = 5;
jumpspeed = 12;
cMap = _parent._parent.cMap;
tileW = _parent._parent.tileW;
tileH = _parent._parent.tileH;
gravity = 0.8;
groundFriction = 0.8;
airFriction = 0.98;
Slash = false;
FireCounter = 0;
facing = 1;
LastHit = getTimer() + 10;
UsedPotion = getTimer();
Instance of Symbol 109 MovieClip [empty] in Symbol 464 MovieClip [char] Frame 1
onClipEvent (enterFrame) {
_parent.control();
}
Symbol 477 MovieClip Frame 1
if (_root.CurrentSkill != 0) {
gotoAndPlay((_root.CurrentSkill * 2) + 1);
}
Symbol 477 MovieClip Frame 2
gotoAndPlay (1);
Symbol 477 MovieClip Frame 3
if (_root.CurrentSkill != 1) {
gotoAndPlay((_root.CurrentSkill * 2) + 1);
}
Symbol 477 MovieClip Frame 4
gotoAndPlay (3);
Symbol 477 MovieClip Frame 5
if (_root.CurrentSkill != 2) {
gotoAndPlay((_root.CurrentSkill * 2) + 1);
}
Symbol 477 MovieClip Frame 6
gotoAndPlay (5);
Symbol 477 MovieClip Frame 7
if (_root.CurrentSkill != 3) {
gotoAndPlay((_root.CurrentSkill * 2) + 1);
}
Symbol 477 MovieClip Frame 8
gotoAndPlay (7);
Symbol 477 MovieClip Frame 9
if (_root.CurrentSkill != 4) {
gotoAndPlay((_root.CurrentSkill * 2) + 1);
}
Symbol 477 MovieClip Frame 10
gotoAndPlay (9);
Symbol 477 MovieClip Frame 11
if (_root.CurrentSkill != 5) {
gotoAndPlay((_root.CurrentSkill * 2) + 1);
}
Symbol 477 MovieClip Frame 12
gotoAndPlay (11);
Symbol 477 MovieClip Frame 13
if (_root.CurrentSkill != 6) {
gotoAndPlay((_root.CurrentSkill * 2) + 1);
}
Symbol 477 MovieClip Frame 14
gotoAndPlay (13);
Symbol 487 Button
on (release) {
_root._quality = "LOW";
}
Symbol 490 Button
on (release) {
_root._quality = "MEDIUM";
}
Symbol 493 Button
on (release) {
_root._quality = "HIGH";
}
Symbol 496 Button
on (release) {
_root._quality = "BEST";
}
Symbol 504 Button
on (release) {
if (_root.Paused < getTimer()) {
_root.Paused = getTimer() + 99999999;
} else {
_root.Paused = getTimer();
}
}
Symbol 506 Button
on (release) {
if (this._currentframe == 2) {
gotoAndStop (1);
_root.Paused = getTimer();
} else if (_root.Paused < getTimer()) {
gotoAndStop (2);
_root.Paused = getTimer() + 99999999;
}
}
Symbol 508 MovieClip Frame 11
gotoAndPlay (1);
Symbol 520 MovieClip Frame 61
stop();
Symbol 550 Button
on (release) {
if ((0 < _root.PotionS) && (_root.Health < 50)) {
_root.PotionS--;
_root.Health = _root.Health + 20;
if (50 < _root.Health) {
_root.Health = 50;
}
}
}
Symbol 552 Button
on (release) {
if ((0 < _root.PotionM) && (_root.Health < 50)) {
_root.PotionM--;
_root.Health = _root.Health + 35;
if (50 < _root.Health) {
_root.Health = 50;
}
}
}
Symbol 565 Button
on (release) {
if ((0 < _root.PotionL) && (_root.Health < 50)) {
_root.PotionL--;
_root.Health = 50;
}
}
Instance of Symbol 548 MovieClip in Symbol 566 MovieClip [Menu] Frame 1
onClipEvent (enterFrame) {
gotoAndStop(_root._currentframe - 2);
}
Symbol 567 MovieClip [Cover] Frame 1
stop();
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 49) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 48) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 47) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 46) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 45) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 44) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 43) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 42) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 41) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 40) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 39) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 38) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 37) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 36) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 35) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 34) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 33) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 32) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 31) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 30) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 29) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 28) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 27) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 26) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 25) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 24) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 23) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 22) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 21) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 20) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 19) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 18) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 16) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 15) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 14) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 13) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 12) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 11) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 10) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 9) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 8) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 7) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 6) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 5) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 4) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 3) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 2) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 1) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 50) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 480 MovieClip [Healthbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Health >= 17) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 49) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 48) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 47) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 46) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 45) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 44) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 43) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 42) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 41) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 40) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 39) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 38) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 37) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 36) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 35) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 34) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 33) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 32) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 31) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 30) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 29) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 28) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 27) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 26) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 25) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 24) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 23) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 22) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 21) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 20) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 19) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 18) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 16) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 15) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 14) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 13) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 12) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 11) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 10) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 9) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 8) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 7) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 6) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 5) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 4) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 3) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 2) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 1) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 50) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 482 MovieClip [Magicbar] in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (_root.Magic >= 17) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Instance of Symbol 508 MovieClip in Symbol 567 MovieClip [Cover] Frame 1
onClipEvent (enterFrame) {
if (getTimer() < _root.Paused) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
Symbol 573 MovieClip [Istrike] Frame 1
_root.Attacking = true;
if (_parent.facing == 1) {
this._x = _root.char._x + 25;
} else if (_parent.facing == 2) {
this._x = _root.char._x - 25;
this._xscale = -100;
}
this._y = _root.char._y - 5;
Symbol 573 MovieClip [Istrike] Frame 2
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 573 MovieClip [Istrike] Frame 3
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 573 MovieClip [Istrike] Frame 4
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 573 MovieClip [Istrike] Frame 5
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 573 MovieClip [Istrike] Frame 6
_root.Attacking = false;
this.removeMovieClip();
Symbol 579 MovieClip [SSstrike] Frame 1
_root.Attacking = true;
if (_parent.facing == 1) {
this._x = _root.char._x + 25;
} else if (_parent.facing == 2) {
this._x = _root.char._x - 25;
this._xscale = -100;
}
this._y = _root.char._y - 5;
Symbol 579 MovieClip [SSstrike] Frame 2
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 579 MovieClip [SSstrike] Frame 3
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 579 MovieClip [SSstrike] Frame 4
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 579 MovieClip [SSstrike] Frame 5
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 579 MovieClip [SSstrike] Frame 6
_root.Attacking = false;
this.removeMovieClip();
Symbol 585 MovieClip [Sstrike] Frame 1
_root.Attacking = true;
if (_parent.facing == 1) {
this._x = _root.char._x + 25;
} else if (_parent.facing == 2) {
this._x = _root.char._x - 25;
this._xscale = -100;
}
this._y = _root.char._y - 5;
Symbol 585 MovieClip [Sstrike] Frame 2
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 585 MovieClip [Sstrike] Frame 3
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 585 MovieClip [Sstrike] Frame 4
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 585 MovieClip [Sstrike] Frame 5
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 585 MovieClip [Sstrike] Frame 6
_root.Attacking = false;
this.removeMovieClip();
Symbol 591 MovieClip [Mstrike] Frame 1
_root.Attacking = true;
if (_parent.facing == 1) {
this._x = _root.char._x + 25;
} else if (_parent.facing == 2) {
this._x = _root.char._x - 25;
this._xscale = -100;
}
this._y = _root.char._y - 5;
Symbol 591 MovieClip [Mstrike] Frame 2
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 591 MovieClip [Mstrike] Frame 3
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 591 MovieClip [Mstrike] Frame 4
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 591 MovieClip [Mstrike] Frame 5
if (Key.isDown(37) && (_parent.facing == 1)) {
_parent.xspeed = 0;
}
if (Key.isDown(39) && (_parent.facing == 2)) {
_parent.xspeed = 0;
}
Symbol 591 MovieClip [Mstrike] Frame 6
_root.Attacking = false;
this.removeMovieClip();
Symbol 595 MovieClip [SJ_smoke] Frame 11
stop();
Symbol 599 MovieClip [Hit] Frame 4
if ((_parent.LastHit + 600) < getTimer()) {
_parent._alpha = 100;
this.removeMovieClip();
} else {
_parent._alpha = 20;
}
Symbol 599 MovieClip [Hit] Frame 7
_parent._alpha = 100;
Symbol 599 MovieClip [Hit] Frame 10
gotoAndPlay (4);
Symbol 605 MovieClip [SuperPlantshot] Frame 1
this._y = _root.clip["SuperPlant_SideKick_" + placer]._y;
this._x = _root.clip["SuperPlant_SideKick_" + placer]._x;
Symbol 605 MovieClip [SuperPlantshot] Frame 2
if (_root.Paused < getTimer()) {
speed = 6;
xinc = Math.floor(speed * Math.sin(((rot - 90) / 180) * Math.PI));
yinc = -1 * Math.floor(speed * Math.cos(((rot - 90) / 180) * Math.PI));
this._x = this._x + xinc;
this._y = this._y + yinc;
if ((500 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y))) {
gotoAndPlay (4);
}
if (((((_root.clip.char._x - 20) < this._x) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 2);
} else {
_root.clip.char.PlayerHit("right", 2);
}
gotoAndPlay (4);
}
}
Symbol 605 MovieClip [SuperPlantshot] Frame 3
gotoAndPlay (2);
Symbol 605 MovieClip [SuperPlantshot] Frame 8
this.removeMovieClip();
Symbol 606 MovieClip [SearisEnergy_Circle] Frame 1
this._y = _root.clip["SearisShade_" + placer]._y;
this._x = _root.clip["SearisShade_" + placer]._x;
centerx = _root.clip["SearisShade_" + placer]._x;
centery = _root.clip["SearisShade_" + placer]._y;
cordlength = 0;
speed = getTimer() / 200;
expand = 0;
Symbol 606 MovieClip [SearisEnergy_Circle] Frame 2
if (_root.Paused < getTimer()) {
centerx = _root.clip["SearisShade_" + placer]._x;
centery = _root.clip["SearisShade_" + placer]._y;
this._x = centerx + (cordlength * Math.cos(speed));
this._y = centery + (cordlength * Math.sin(speed));
speed = (getTimer() / 200) + offset;
if (cordlength < 40) {
cordlength = cordlength + 4;
} else if ((40 < cordlength) && (expand == 0)) {
cordlength = cordlength - 10;
speed = (getTimer() / 800) + offset;
} else if ((cordlength < 1440) && (expand == 1)) {
cordlength = cordlength + 10;
speed = (getTimer() / 800) + offset;
} else {
expand = 0;
}
if (getTimer() < _root.GuidedStrike) {
expand = 1;
}
}
if (((((_root.clip.char._x - 40) < this._x) && (this._x < (_root.clip.char._x + 40))) && ((_root.clip.char._y - 40) < this._y)) && (this._y < (_root.clip.char._y + 40))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 7);
} else {
_root.clip.char.PlayerHit("right", 7);
}
}
Symbol 606 MovieClip [SearisEnergy_Circle] Frame 3
gotoAndPlay (2);
Symbol 607 MovieClip [DemonDrain] Frame 1
this._y = _root.clip["MistDemon_" + placer]._y;
this._x = _root.clip["MistDemon_" + placer]._x;
Symbol 607 MovieClip [DemonDrain] Frame 2
if (_root.Paused < getTimer()) {
speed = 6;
xinc = Math.floor(speed * Math.sin(((rot - 90) / 180) * Math.PI));
yinc = -1 * Math.floor(speed * Math.cos(((rot - 90) / 180) * Math.PI));
this._x = this._x + xinc;
this._y = this._y + yinc;
if ((500 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y))) {
gotoAndPlay (4);
}
if (((((_root.clip.char._x - 25) < this._x) && (this._x < (_root.clip.char._x + 25))) && ((_root.clip.char._y - 25) < this._y)) && (this._y < (_root.clip.char._y + 25))) {
_root.clip.char.attachMovie("Drain2", "Drain", 1035);
gotoAndPlay (4);
}
}
Symbol 607 MovieClip [DemonDrain] Frame 3
gotoAndPlay (2);
Symbol 607 MovieClip [DemonDrain] Frame 8
this.removeMovieClip();
Symbol 608 MovieClip [SearisDrain] Frame 1
this._y = _root.clip["Searis_" + placer]._y;
this._x = _root.clip["Searis_" + placer]._x;
Symbol 608 MovieClip [SearisDrain] Frame 2
if (_root.Paused < getTimer()) {
speed = 5;
xinc = Math.floor(speed * Math.sin(((rot - 90) / 180) * Math.PI));
yinc = -1 * Math.floor(speed * Math.cos(((rot - 90) / 180) * Math.PI));
this._x = this._x + xinc;
this._y = this._y + yinc;
if ((500 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y))) {
gotoAndPlay (4);
}
if (((((_root.clip.char._x - 25) < this._x) && (this._x < (_root.clip.char._x + 25))) && ((_root.clip.char._y - 25) < this._y)) && (this._y < (_root.clip.char._y + 25))) {
_root.clip.char.attachMovie("Drain", "Drain", 1035);
gotoAndPlay (4);
}
}
Symbol 608 MovieClip [SearisDrain] Frame 3
gotoAndPlay (2);
Symbol 608 MovieClip [SearisDrain] Frame 8
this.removeMovieClip();
Symbol 609 MovieClip [SearisEnergy2] Frame 1
this._y = _root.clip["Searis_" + placer]._y;
this._x = _root.clip["Searis_" + placer]._x;
Symbol 609 MovieClip [SearisEnergy2] Frame 2
if (_root.Paused < getTimer()) {
speed = 10;
xinc = Math.floor(speed * Math.sin(((rot - 90) / 180) * Math.PI));
yinc = -1 * Math.floor(speed * Math.cos(((rot - 90) / 180) * Math.PI));
this._x = this._x + xinc;
this._y = this._y + yinc;
if ((500 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y))) {
gotoAndPlay (4);
}
if (((((_root.clip.char._x - 25) < this._x) && (this._x < (_root.clip.char._x + 25))) && ((_root.clip.char._y - 25) < this._y)) && (this._y < (_root.clip.char._y + 25))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 7);
} else {
_root.clip.char.PlayerHit("right", 7);
}
gotoAndPlay (4);
}
}
Symbol 609 MovieClip [SearisEnergy2] Frame 3
gotoAndPlay (2);
Symbol 609 MovieClip [SearisEnergy2] Frame 8
this.removeMovieClip();
Symbol 610 MovieClip [SearisEnergy] Frame 1
this._y = _root.clip["SearisShade_" + placer]._y;
this._x = _root.clip["SearisShade_" + placer]._x;
Symbol 610 MovieClip [SearisEnergy] Frame 2
if (_root.Paused < getTimer()) {
speed = 10;
xinc = Math.floor(speed * Math.sin(((rot - 90) / 180) * Math.PI));
yinc = -1 * Math.floor(speed * Math.cos(((rot - 90) / 180) * Math.PI));
this._x = this._x + xinc;
this._y = this._y + yinc;
if ((500 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y))) {
gotoAndPlay (4);
}
if (((((_root.clip.char._x - 25) < this._x) && (this._x < (_root.clip.char._x + 25))) && ((_root.clip.char._y - 25) < this._y)) && (this._y < (_root.clip.char._y + 25))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 5);
} else {
_root.clip.char.PlayerHit("right", 5);
}
gotoAndPlay (4);
}
}
Symbol 610 MovieClip [SearisEnergy] Frame 3
gotoAndPlay (2);
Symbol 610 MovieClip [SearisEnergy] Frame 8
this.removeMovieClip();
Symbol 615 MovieClip [Red_Shuriken] Frame 1
this._y = _root.clip["Red_Ninja_" + placer]._y;
this._x = _root.clip["Red_Ninja_" + placer]._x;
Symbol 615 MovieClip [Red_Shuriken] Frame 2
if (_root.Paused < getTimer()) {
this._x = this._x + xspeed;
this._y = this._y + yspeed;
if (((((_root.clip.char._x - 20) < this._x) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 5);
} else {
_root.clip.char.PlayerHit("right", 5);
}
gotoAndPlay (4);
} else if (500 < Math.abs(this._x - _root.clip.char._x)) {
gotoAndPlay (4);
}
}
Symbol 615 MovieClip [Red_Shuriken] Frame 3
gotoAndPlay (2);
Symbol 615 MovieClip [Red_Shuriken] Frame 6
this.removeMovieClip();
Symbol 616 MovieClip [Shuriken] Frame 1
this._y = _root.clip["Ninja_" + placer]._y;
this._x = _root.clip["Ninja_" + placer]._x;
Symbol 616 MovieClip [Shuriken] Frame 2
if (_root.Paused < getTimer()) {
this._x = this._x + xspeed;
this._y = this._y + yspeed;
if (((((_root.clip.char._x - 20) < this._x) && (this._x < (_root.clip.char._x + 20))) && ((_root.clip.char._y - 20) < this._y)) && (this._y < (_root.clip.char._y + 20))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", 1);
} else {
_root.clip.char.PlayerHit("right", 1);
}
gotoAndPlay (4);
} else if (500 < Math.abs(this._x - _root.clip.char._x)) {
gotoAndPlay (4);
}
}
Symbol 616 MovieClip [Shuriken] Frame 3
gotoAndPlay (2);
Symbol 616 MovieClip [Shuriken] Frame 6
this.removeMovieClip();
Symbol 617 MovieClip [FB_fireball] Frame 1
dying = 0;
this._y = _root.clip.char._y;
if (_root.clip.char.facing == 1) {
this._x = _root.clip.char._x + 15;
facing = 1;
} else if (_root.clip.char.facing == 2) {
this._x = _root.clip.char._x - 15;
facing = 2;
}
Instance of Symbol 54 MovieClip in Symbol 617 MovieClip [FB_fireball] Frame 1
onClipEvent (load) {
if (_root.clip.char.facing == 1) {
this._rotation = 270;
}
}
Symbol 617 MovieClip [FB_fireball] Frame 2
if (_root.Paused < getTimer()) {
if (facing == 1) {
this._x = this._x + 10;
} else if (facing == 2) {
this._x = this._x - 10;
}
if ((dying == 0) && (500 < Math.abs(this._x - _root.clip.char._x))) {
gotoAndPlay (4);
}
if (dying == 1) {
this.removeMovieClip();
}
}
Symbol 617 MovieClip [FB_fireball] Frame 3
gotoAndPlay (2);
Symbol 617 MovieClip [FB_fireball] Frame 4
dying = 1;
Symbol 617 MovieClip [FB_fireball] Frame 9
this.removeMovieClip();
Symbol 618 MovieClip [Magic_Regen] Frame 10
if (_root.Paused < getTimer()) {
if ((_root.Magic < 50) && (_root.clip.char.FreezeSkills < getTimer())) {
_root.Magic++;
}
gotoAndPlay (1);
}
Symbol 625 MovieClip [S_Speedburst] Frame 13
this.removeMovieClip();
Symbol 626 MovieClip [S_Speedburst_Collage] Frame 28
this.removeMovieClip();
Symbol 628 MovieClip [GS_Flash] Frame 3
this.removeMovieClip();
Symbol 634 MovieClip [Drain2] Frame 1
if (Key.isDown(68) && (_root.CurrentSkill == 3)) {
this.removeMovieClip();
}
_root.Health = _root.Health - 2;
Symbol 634 MovieClip [Drain2] Frame 2
if (Key.isDown(68) && (_root.CurrentSkill == 3)) {
this.removeMovieClip();
}
Symbol 634 MovieClip [Drain2] Frame 3
if (Key.isDown(68) && (_root.CurrentSkill == 3)) {
this.removeMovieClip();
}
Symbol 634 MovieClip [Drain2] Frame 4
if (Key.isDown(68) && (_root.CurrentSkill == 3)) {
this.removeMovieClip();
}
Symbol 634 MovieClip [Drain2] Frame 5
if (Key.isDown(68) && (_root.CurrentSkill == 3)) {
this.removeMovieClip();
}
Symbol 638 MovieClip [Drain] Frame 1
if (Key.isDown(68) && (_root.CurrentSkill == 3)) {
this.removeMovieClip();
}
_root.Health = _root.Health - 1;
Symbol 638 MovieClip [Drain] Frame 2
if (Key.isDown(68) && (_root.CurrentSkill == 3)) {
this.removeMovieClip();
}
Symbol 638 MovieClip [Drain] Frame 3
if (Key.isDown(68) && (_root.CurrentSkill == 3)) {
this.removeMovieClip();
}
Symbol 638 MovieClip [Drain] Frame 4
if (Key.isDown(68) && (_root.CurrentSkill == 3)) {
this.removeMovieClip();
}
Symbol 638 MovieClip [Drain] Frame 5
if (Key.isDown(68) && (_root.CurrentSkill == 3)) {
this.removeMovieClip();
}
Symbol 644 MovieClip [H_Aura] Frame 6
this.removeMovieClip();
Symbol 652 MovieClip [GameOver] Frame 158
_root.char.removeMovieClip();
_root.clip.removeMovieClip();
_root.Cover.removeMovieClip();
_root.Paused = getTimer();
_root.gotoAndPlay(50);
this.removeMovieClip();
Symbol 655 MovieClip [RdyGo] Frame 4
_root.Paused = getTimer() + 999999;
Symbol 655 MovieClip [RdyGo] Frame 50
_root.Paused = getTimer() + 10;
Symbol 655 MovieClip [RdyGo] Frame 60
this.removeMovieClip();
Symbol 663 MovieClip [L_Bolt] Frame 1
_root.Lit = true;
this._x = _root.char._x;
this._y = _root.char._y;
Symbol 663 MovieClip [L_Bolt] Frame 6
_root.Lit = false;
this.removeMovieClip();
Symbol 684 MovieClip Frame 1
gotoAndStop(_parent.Face);
Symbol 688 MovieClip [EventBox] Frame 1
n = 0;
Next = getTimer();
Symbol 688 MovieClip [EventBox] Frame 9
Face = EventData[n][0];
TextBox = EventData[n][1];
Symbol 688 MovieClip [EventBox] Frame 32
if (Key.isDown(13) && ((Next + 500) < getTimer())) {
if (EventData[n + 1][0] == 0) {
_root.EventEnded = getTimer();
_root.Paused = getTimer();
this.removeMovieClip();
} else {
n = n + 1;
Next = getTimer();
gotoAndPlay (9);
}
} else {
_root.Paused = getTimer() + 99999999;
}
gotoAndPlay (31);
Symbol 694 MovieClip [StoreBox] Frame 7
StoreListL = StoreList.length;
k = 0;
while (k < StoreListL) {
this.attachMovie("Store_Inventory", "Store_Inventory_" + k, k);
this["Store_Inventory_" + k]._x = 75;
this["Store_Inventory_" + k]._y = -125 + (k * 40);
this["Store_Inventory_" + k].Item = StoreList[k][0];
this["Store_Inventory_" + k].Price = StoreList[k][1];
k++;
}
this.attachMovie("Store_Exit", "Exit", StoreListL);
this.Exit._x = 75;
this.Exit._y = -125 + (StoreListL * 40);
this.attachMovie("StoreCursor", "Cursor", StoreListL + 1);
this.Cursor._x = 75;
this.Cursor._y = -125;
this.Cursor._alpha = 65;
n = 0;
Symbol 694 MovieClip [StoreBox] Frame 15
if ((((JustMoved + 200) < getTimer()) && (Key.isDown(40))) && (n < StoreListL)) {
this.Cursor._y = this.Cursor._y + 40;
n++;
JustMoved = getTimer();
} else if ((((JustMoved + 200) < getTimer()) && (Key.isDown(38))) && (0 < n)) {
this.Cursor._y = this.Cursor._y - 40;
n--;
JustMoved = getTimer();
} else if (Key.isDown(13) && (n == StoreListL)) {
gotoAndPlay (17);
} else if (Key.isDown(13) && (_root.Gold >= StoreList[n][1])) {
if ((StoreList[n][0] == "Small Potion") && (_root.PotionS < 10)) {
_root.PotionS++;
_root.Gold = _root.Gold - StoreList[n][1];
}
if ((StoreList[n][0] == "Medium Potion") && (_root.PotionM < 10)) {
_root.PotionM++;
_root.Gold = _root.Gold - StoreList[n][1];
}
if ((StoreList[n][0] == "Large Potion") && (_root.PotionL < 10)) {
_root.PotionL++;
_root.Gold = _root.Gold - StoreList[n][1];
}
if ((StoreList[n][0] == "Sword") && (_root.MaxWeap < 2)) {
_root.MaxWeap = 2;
_root.Gold = _root.Gold - StoreList[n][1];
}
if ((StoreList[n][0] == "Silver Sword") && (_root.MaxWeap < 3)) {
_root.MaxWeap = 3;
_root.Gold = _root.Gold - StoreList[n][1];
}
if ((StoreList[n][0] == "Stay at Inn") && (_root.Health < 50)) {
_root.Health = 50;
_root.Gold = _root.Gold - StoreList[n][1];
}
gotoAndPlay (17);
}
Symbol 694 MovieClip [StoreBox] Frame 16
gotoAndPlay (15);
Symbol 694 MovieClip [StoreBox] Frame 21
k = 0;
while (k < StoreListL) {
this["Store_Inventory_" + k].removeMovieClip();
k++;
}
this.Exit.removeMovieClip();
this.Cursor.removeMovieClip();
Symbol 694 MovieClip [StoreBox] Frame 32
_root.EventEnded = getTimer();
_root.Paused = getTimer();
this.removeMovieClip();
Symbol 704 MovieClip [SB1A] Frame 1
this._y = _root.clip["SB1_" + placer]._y;
this._x = _root.clip["SB1_" + placer]._x;
centerx = this._x;
centery = this._y;
cordlength = 0;
speed = getTimer() / 1000;
Symbol 704 MovieClip [SB1A] Frame 2
if (_root.Paused < getTimer()) {
this._x = centerx + (cordlength * Math.cos(speed));
this._y = centery + (cordlength * Math.sin(speed));
speed = getTimer() / 500;
if (cordlength < 120) {
cordlength = cordlength + 3;
}
}
if (((((_root.clip.char._x - 40) < this._x) && (this._x < (_root.clip.char._x + 40))) && ((_root.clip.char._y - 40) < this._y)) && (this._y < (_root.clip.char._y + 40))) {
if (this._x < _root.clip.char._x) {
_root.clip.char.PlayerHit("left", -7);
} else {
_root.clip.char.PlayerHit("right", -7);
}
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
this.removeMovieClip();
}
Symbol 704 MovieClip [SB1A] Frame 3
gotoAndPlay (2);
Symbol 706 MovieClip [SpikedBall_ChainBorder_anim] Frame 1
if (_root.Paused < getTimer()) {
this._x = _root.clip["SB1_" + placer]._x + ((_root.clip[("SB1A_" + (10 * placer)) + 9].cordlength * percentage) * Math.cos(speed));
this._y = _root.clip["SB1_" + placer]._y + ((_root.clip[("SB1A_" + (10 * placer)) + 9].cordlength * percentage) * Math.sin(speed));
speed = getTimer() / 500;
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
this.removeMovieClip();
}
Symbol 706 MovieClip [SpikedBall_ChainBorder_anim] Frame 2
gotoAndPlay (1);
Symbol 708 MovieClip [SpikedBall_Chain_anim] Frame 1
if (_root.Paused < getTimer()) {
this._x = _root.clip["SB1_" + placer]._x + ((_root.clip[("SB1A_" + (10 * placer)) + 9].cordlength * percentage) * Math.cos(speed));
this._y = _root.clip["SB1_" + placer]._y + ((_root.clip[("SB1A_" + (10 * placer)) + 9].cordlength * percentage) * Math.sin(speed));
speed = getTimer() / 500;
}
if (((JustHit + 200) < getTimer()) && ((600 < Math.abs(this._x - _root.clip.char._x)) || (500 < Math.abs(this._y - _root.clip.char._y)))) {
_root.active[placer] = 0;
this.removeMovieClip();
}
Symbol 708 MovieClip [SpikedBall_Chain_anim] Frame 2
gotoAndPlay (1);
Symbol 711 MovieClip [Ghost_Kill] Frame 1
this._x = _root.clip.char._x;
this._y = _root.clip.char._y;
Symbol 711 MovieClip [Ghost_Kill] Frame 2
this._x = _root.clip.char._x;
this._y = _root.clip.char._y;
Symbol 711 MovieClip [Ghost_Kill] Frame 3
this._x = _root.clip.char._x;
this._y = _root.clip.char._y;
Symbol 711 MovieClip [Ghost_Kill] Frame 4
this._x = _root.clip.char._x;
this._y = _root.clip.char._y;
Symbol 711 MovieClip [Ghost_Kill] Frame 5
this._x = _root.clip.char._x;
this._y = _root.clip.char._y;
Symbol 711 MovieClip [Ghost_Kill] Frame 6
this._x = _root.clip.char._x;
this._y = _root.clip.char._y;
Symbol 711 MovieClip [Ghost_Kill] Frame 7
this._x = _root.clip.char._x;
this._y = _root.clip.char._y;
Symbol 711 MovieClip [Ghost_Kill] Frame 8
this._x = _root.clip.char._x;
this._y = _root.clip.char._y;
Symbol 711 MovieClip [Ghost_Kill] Frame 9
this._x = _root.clip.char._x;
this._y = _root.clip.char._y;
Symbol 711 MovieClip [Ghost_Kill] Frame 10
this._x = _root.clip.char._x;
this._y = _root.clip.char._y;
Symbol 711 MovieClip [Ghost_Kill] Frame 11
this._x = _root.clip.char._x;
this._y = _root.clip.char._y;
Symbol 711 MovieClip [Ghost_Kill] Frame 12
this._x = _root.clip.char._x;
this._y = _root.clip.char._y;
Symbol 711 MovieClip [Ghost_Kill] Frame 13
_root.clip.char.PlayerHit("right", -50);
Symbol 711 MovieClip [Ghost_Kill] Frame 26
this.removeMovieClip();
Symbol 717 Button
on (release) {
getURL ("http://www.armorgames.com", "_blank");
}
Symbol 745 Button
on (release) {
gotoAndPlay (5);
}
Symbol 749 Button
on (release) {
_root.play();
}
Symbol 789 Button
on (release) {
_root.play();
}
Symbol 790 MovieClip Frame 143
_parent.play();
stop();
Symbol 815 MovieClip Frame 309
_parent.play();
Symbol 816 MovieClip Frame 1
_root.stop();
BytesLoaded = _root.getBytesLoaded();
BytesTotal = _root.getBytesTotal();
PercentLoaded = Math.floor((_root.getBytesLoaded() / _root.getBytesTotal()) * 100);
TimePassed = Math.round(getTimer() / 1000);
TimeLeft = Math.round(((100 / Percentloaded) * (getTimer() / 1000)) - TimePassed);
if (PercentLoaded != 100) {
setProperty(bar, _xscale , PercentLoaded);
} else {
gotoAndStop ("loaded");
}
Symbol 816 MovieClip Frame 2
gotoAndPlay (1);
Symbol 816 MovieClip Frame 3
stop();
Symbol 816 MovieClip Frame 5
stop();
Symbol 816 MovieClip Frame 6
stop();
Symbol 816 MovieClip Frame 7
_root.play();
Symbol 823 Button
on (release) {
_root.gotoAndPlay(60);
}
Symbol 824 Button
on (release) {
this.gotoAndPlay(119);
}
Symbol 833 Button
on (release) {
_root.Passcode();
}
Instance of Symbol 520 MovieClip in Symbol 834 MovieClip Frame 1
onClipEvent (load) {
stop();
}
Symbol 834 MovieClip Frame 118
gotoAndPlay (95);
Symbol 834 MovieClip Frame 170
gotoAndPlay (150);
Symbol 848 MovieClip Frame 1
stop();
Symbol 849 Button
on (release) {
_root.gotoAndPlay(1);
}
Instance of Symbol 852 MovieClip in Symbol 853 MovieClip Frame 2
onClipEvent (enterFrame) {
if (-1250 < this._y) {
this._y = this._y - 2;
}
}
Symbol 853 MovieClip Frame 3
gotoAndPlay (2);
Instance of Symbol 857 MovieClip in Symbol 858 MovieClip Frame 1
onClipEvent (load) {
target = _parent._parent;
cam = _parent;
cam._visible = false;
sX = _root.stageWidth;
sY = _root.stageHeight;
cX = sX / 2;
cY = sY / 2;
camColor = new Color(cam);
parentColor = new Color(target);
}
onClipEvent (enterFrame) {
parentColor.setTransform(camColor.getTransform());
scaleX = sX / _parent._width;
scaleY = sY / _parent._height;
target._x = cX - (cam._x * scaleX);
target._y = cY - (cam._y * scaleY);
target._xscale = 100 * scaleX;
target._yscale = 100 * scaleY;
}
onClipEvent (unload) {
resetTrans = {ra:100, rb:0, ga:100, gb:0, ba:100, bb:0, aa:100, ab:0};
parentColor.setTransform(resetTrans);
target._xscale = 100;
target._yscale = 100;
target._x = 0;
target._y = 0;
}
Symbol 860 MovieClip Frame 1
i = 1;
SubText = Text.substring(0, i);
if (Pauser == 1) {
_parent.stop();
}
Symbol 860 MovieClip Frame 2
SubText = Text.substring(0, i);
Symbol 860 MovieClip Frame 4
if (i == (Text.length + 15)) {
stop();
if (Pauser == 1) {
_parent.play();
}
}
i++;
gotoAndPlay (2);
Symbol 897 MovieClip Frame 1
Voices = new Sound(this);
loop = 0;
Instance of Symbol 860 MovieClip in Symbol 897 MovieClip Frame 3
onClipEvent (load) {
Text = "BattleMage: Chapter 1 \n\n The Journey Begins";
Pauser = 1;
}
Symbol 897 MovieClip Frame 10
Voices.stop();
Voices.attachSound("Voice_PC_1");
Voices.start(0);
Symbol 897 MovieClip Frame 77
loop++;
Symbol 897 MovieClip Frame 78
if (loop < 150) {
gotoAndPlay (77);
}
Symbol 897 MovieClip Frame 79
loop = 0;
Symbol 897 MovieClip Frame 113
Voices.stop();
Voices.attachSound("Voice_PC_2");
Voices.start(0);
Symbol 897 MovieClip Frame 149
loop++;
Symbol 897 MovieClip Frame 150
if (loop < 80) {
gotoAndPlay (149);
}
Symbol 897 MovieClip Frame 151
loop = 0;
Symbol 897 MovieClip Frame 152
Voices.stop();
Voices.attachSound("Voice_PC_3");
Voices.start(0);
Symbol 897 MovieClip Frame 153
loop++;
Symbol 897 MovieClip Frame 154
if (loop < 150) {
gotoAndPlay (153);
}
Symbol 897 MovieClip Frame 155
loop = 0;
Symbol 897 MovieClip Frame 196
loop++;
Symbol 897 MovieClip Frame 197
if (loop < 150) {
gotoAndPlay (196);
}
Symbol 897 MovieClip Frame 198
loop = 0;
Symbol 897 MovieClip Frame 202
Voices.stop();
Voices.attachSound("Voice_PC_4");
Voices.start(0);
Symbol 897 MovieClip Frame 233
loop++;
Symbol 897 MovieClip Frame 234
if (loop < 300) {
gotoAndPlay (233);
}
Symbol 897 MovieClip Frame 235
loop = 0;
Symbol 897 MovieClip Frame 251
Voices.stop();
Voices.attachSound("Voice_PC_5");
Voices.start(0);
Symbol 897 MovieClip Frame 267
loop++;
Symbol 897 MovieClip Frame 268
if (loop < 120) {
gotoAndPlay (267);
}
Symbol 897 MovieClip Frame 269
loop = 0;
Symbol 897 MovieClip Frame 275
Voices.stop();
Voices.attachSound("Voice_PC_6");
Voices.start(0);
Symbol 897 MovieClip Frame 300
loop++;
Symbol 897 MovieClip Frame 301
if (loop < 200) {
gotoAndPlay (300);
}
Symbol 897 MovieClip Frame 302
loop = 0;
Symbol 897 MovieClip Frame 307
Voices.stop();
Voices.attachSound("Voice_PC_7");
Voices.start(0);
Symbol 897 MovieClip Frame 308
loop++;
Symbol 897 MovieClip Frame 309
if (loop < 150) {
gotoAndPlay (308);
}
Symbol 897 MovieClip Frame 310
loop = 0;
Symbol 897 MovieClip Frame 336
loop++;
Symbol 897 MovieClip Frame 337
if (loop < 100) {
gotoAndPlay (336);
}
Symbol 897 MovieClip Frame 338
loop = 0;
Symbol 897 MovieClip Frame 343
Voices.stop();
Voices.attachSound("Voice_PC_8");
Voices.start(0);
Symbol 897 MovieClip Frame 368
loop++;
Symbol 897 MovieClip Frame 369
if (loop < 280) {
gotoAndPlay (368);
}
Symbol 897 MovieClip Frame 370
loop = 0;
Symbol 897 MovieClip Frame 371
Voices.stop();
Voices.attachSound("Voice_PC_9");
Voices.start(0);
Symbol 897 MovieClip Frame 372
loop++;
Symbol 897 MovieClip Frame 373
if (loop < 100) {
gotoAndPlay (372);
}
Symbol 897 MovieClip Frame 374
loop = 0;
Symbol 897 MovieClip Frame 406
loop++;
Symbol 897 MovieClip Frame 407
if (loop < 100) {
gotoAndPlay (406);
}
Symbol 897 MovieClip Frame 408
loop = 0;
Symbol 897 MovieClip Frame 431
_root.gotoAndPlay(3);
Symbol 899 Button
on (release) {
_root.gotoAndPlay(3);
}
Symbol 902 MovieClip Frame 1
Voices = new Sound(this);
loop = 0;
Symbol 902 MovieClip Frame 3
Voices.stop();
Voices.attachSound("Voice_Ellie_1");
Voices.start(0);
Symbol 902 MovieClip Frame 17
loop++;
Symbol 902 MovieClip Frame 18
if (loop < 100) {
gotoAndPlay (17);
}
Symbol 902 MovieClip Frame 19
loop = 0;
Symbol 902 MovieClip Frame 36
Voices.stop();
Voices.attachSound("Voice_Bandit_1");
Voices.start(0);
Symbol 902 MovieClip Frame 61
loop++;
Symbol 902 MovieClip Frame 62
if (loop < 50) {
gotoAndPlay (61);
}
Symbol 902 MovieClip Frame 63
loop = 0;
Symbol 902 MovieClip Frame 64
Voices.stop();
Voices.attachSound("Voice_PC_10");
Voices.start(0);
Symbol 902 MovieClip Frame 65
loop++;
Symbol 902 MovieClip Frame 66
if (loop < 120) {
gotoAndPlay (65);
}
Symbol 902 MovieClip Frame 67
loop = 0;
Symbol 902 MovieClip Frame 68
Voices.stop();
Voices.attachSound("Voice_Bandit_2");
Voices.start(0);
Symbol 902 MovieClip Frame 70
loop++;
Symbol 902 MovieClip Frame 71
if (loop < 200) {
gotoAndPlay (70);
}
Symbol 902 MovieClip Frame 72
loop = 0;
Symbol 902 MovieClip Frame 92
_root.gotoAndPlay(5);
Symbol 903 Button
on (release) {
_root.gotoAndPlay(5);
}
Symbol 905 MovieClip Frame 1
Voices = new Sound(this);
loop = 0;
Instance of Symbol 860 MovieClip in Symbol 905 MovieClip Frame 2
onClipEvent (load) {
Text = "BattleMage: Chapter 2 \n\n Quest for the Keep";
Pauser = 1;
}
Symbol 905 MovieClip Frame 6
Voices.stop();
Voices.attachSound("Voice_CS3_Convo");
Voices.start(0);
Symbol 905 MovieClip Frame 18
loop++;
Symbol 905 MovieClip Frame 19
if (loop < 400) {
gotoAndPlay (17);
}
Symbol 905 MovieClip Frame 20
loop = 0;
Symbol 905 MovieClip Frame 62
loop++;
Symbol 905 MovieClip Frame 63
if (loop < 500) {
gotoAndPlay (61);
}
Symbol 905 MovieClip Frame 64
loop = 0;
Symbol 905 MovieClip Frame 73
loop++;
Symbol 905 MovieClip Frame 74
if (loop < 1300) {
gotoAndPlay (72);
}
Symbol 905 MovieClip Frame 75
loop = 0;
Symbol 905 MovieClip Frame 93
_root.gotoAndPlay(6);
Symbol 906 Button
on (release) {
_root.gotoAndPlay(6);
}
Symbol 909 MovieClip Frame 1
Voices = new Sound(this);
loop = 0;
Instance of Symbol 860 MovieClip in Symbol 909 MovieClip Frame 2
onClipEvent (load) {
Text = "BattleMage: Chapter 3 \n\n The True Face of Evil";
Pauser = 1;
}
Symbol 909 MovieClip Frame 6
Voices.stop();
Voices.attachSound("Voice_PC_16");
Voices.start(0);
Symbol 909 MovieClip Frame 7
loop++;
Symbol 909 MovieClip Frame 8
if (loop < 30) {
gotoAndPlay (7);
}
Symbol 909 MovieClip Frame 9
loop = 0;
Symbol 909 MovieClip Frame 15
loop++;
Symbol 909 MovieClip Frame 16
if (loop < 30) {
gotoAndPlay (15);
}
Symbol 909 MovieClip Frame 17
loop = 0;
Symbol 909 MovieClip Frame 20
Voices.stop();
Voices.attachSound("Voice_PC_17");
Voices.start(0);
Symbol 909 MovieClip Frame 62
loop++;
Symbol 909 MovieClip Frame 63
if (loop < 30) {
gotoAndPlay (62);
}
Symbol 909 MovieClip Frame 64
loop = 0;
Symbol 909 MovieClip Frame 71
loop++;
Symbol 909 MovieClip Frame 72
if (loop < 50) {
gotoAndPlay (71);
}
Symbol 909 MovieClip Frame 73
loop = 0;
Symbol 909 MovieClip Frame 125
_root.gotoAndPlay(23);
Symbol 910 Button
on (release) {
_root.gotoAndPlay(23);
}
Symbol 916 MovieClip Frame 1
Voices = new Sound(this);
loop = 0;
Symbol 916 MovieClip Frame 33
loop++;
Symbol 916 MovieClip Frame 34
if (loop < 30) {
gotoAndPlay (33);
}
Symbol 916 MovieClip Frame 35
loop = 0;
Symbol 916 MovieClip Frame 111
Voices.stop();
Voices.attachSound("Voice_CS5_Convo");
Voices.start(0);
Instance of Symbol 860 MovieClip in Symbol 916 MovieClip Frame 112
onClipEvent (load) {
Text = "Sorry: Camera does not change here. Just listen to the plot, or skip.";
Pauser = 0;
}
Symbol 916 MovieClip Frame 119
loop++;
Symbol 916 MovieClip Frame 120
if (loop < 4800) {
gotoAndPlay (119);
}
Symbol 916 MovieClip Frame 121
loop = 0;
Symbol 916 MovieClip Frame 142
_root.gotoAndPlay(24);
Symbol 917 Button
on (release) {
_root.gotoAndPlay(24);
}
Symbol 920 MovieClip Frame 1
Voices = new Sound(this);
loop = 0;
Instance of Symbol 860 MovieClip in Symbol 920 MovieClip Frame 2
onClipEvent (load) {
Text = "BattleMage: Chapter 4 \n\n Into the Mists";
Pauser = 1;
}
Symbol 920 MovieClip Frame 24
Voices.stop();
Voices.attachSound("Voice_CS6_Convo");
Voices.start(0);
Symbol 920 MovieClip Frame 33
loop++;
Symbol 920 MovieClip Frame 34
if (loop < 100) {
gotoAndPlay (33);
}
Symbol 920 MovieClip Frame 35
loop = 0;
Symbol 920 MovieClip Frame 75
loop++;
Symbol 920 MovieClip Frame 76
if (loop < 800) {
gotoAndPlay (75);
}
Symbol 920 MovieClip Frame 77
loop = 0;
Symbol 920 MovieClip Frame 121
loop++;
Symbol 920 MovieClip Frame 122
if (loop < 900) {
gotoAndPlay (121);
}
Symbol 920 MovieClip Frame 123
loop = 0;
Symbol 920 MovieClip Frame 142
_root.gotoAndPlay(31);
Symbol 921 Button
on (release) {
_root.gotoAndPlay(31);
}
Symbol 932 MovieClip Frame 1
Voices = new Sound(this);
loop = 0;
Instance of Symbol 860 MovieClip in Symbol 932 MovieClip Frame 2
onClipEvent (load) {
Text = "BattleMage: Chapter 5 \n\n Shadows and Light";
Pauser = 1;
}
Symbol 932 MovieClip Frame 32
Voices.stop();
Voices.attachSound("Voice_PC_30");
Voices.start(0);
Symbol 932 MovieClip Frame 34
loop++;
Symbol 932 MovieClip Frame 35
if (loop < 100) {
gotoAndPlay (34);
}
Symbol 932 MovieClip Frame 36
loop = 0;
Symbol 932 MovieClip Frame 40
Voices.stop();
Voices.attachSound("Voice_Searis_7");
Voices.start(0);
Symbol 932 MovieClip Frame 43
loop++;
Symbol 932 MovieClip Frame 44
if (loop < 360) {
gotoAndPlay (43);
}
Symbol 932 MovieClip Frame 45
loop = 0;
Symbol 932 MovieClip Frame 48
Voices.stop();
Voices.attachSound("Voice_PC_31");
Voices.start(0);
Symbol 932 MovieClip Frame 50
loop++;
Symbol 932 MovieClip Frame 51
if (loop < 140) {
gotoAndPlay (50);
}
Symbol 932 MovieClip Frame 52
loop = 0;
Symbol 932 MovieClip Frame 56
Voices.stop();
Voices.attachSound("Voice_CS7_Convo");
Voices.start(0);
Symbol 932 MovieClip Frame 61
loop++;
Symbol 932 MovieClip Frame 62
if (loop < 1250) {
gotoAndPlay (61);
}
Symbol 932 MovieClip Frame 63
loop = 0;
Symbol 932 MovieClip Frame 122
loop++;
Symbol 932 MovieClip Frame 123
if (loop < 100) {
gotoAndPlay (122);
}
Symbol 932 MovieClip Frame 124
loop = 0;
Symbol 932 MovieClip Frame 142
_root.gotoAndPlay(38);
Symbol 933 Button
on (release) {
_root.gotoAndPlay(38);
}
Symbol 937 MovieClip Frame 1
Voices = new Sound(this);
loop = 0;
Symbol 937 MovieClip Frame 5
Voices.stop();
Voices.attachSound("Voice_PC_34");
Voices.start(0);
Symbol 937 MovieClip Frame 6
loop++;
Symbol 937 MovieClip Frame 7
if (loop < 100) {
gotoAndPlay (6);
}
Symbol 937 MovieClip Frame 8
loop = 0;
Symbol 937 MovieClip Frame 13
Voices.stop();
Voices.attachSound("Voice_Searis_11");
Voices.start(0);
Symbol 937 MovieClip Frame 24
loop++;
Symbol 937 MovieClip Frame 25
if (loop < 330) {
gotoAndPlay (24);
}
Symbol 937 MovieClip Frame 26
loop = 0;
Symbol 937 MovieClip Frame 28
Voices.stop();
Voices.attachSound("Voice_PC_35");
Voices.start(0);
Symbol 937 MovieClip Frame 49
loop++;
Symbol 937 MovieClip Frame 50
if (loop < 60) {
gotoAndPlay (49);
}
Symbol 937 MovieClip Frame 51
loop = 0;
Symbol 937 MovieClip Frame 72
loop++;
Symbol 937 MovieClip Frame 73
if (loop < 50) {
gotoAndPlay (72);
}
Symbol 937 MovieClip Frame 74
loop = 0;
Symbol 937 MovieClip Frame 100
Voices.stop();
Voices.attachSound("Voice_PC_37");
Voices.start(0);
Symbol 937 MovieClip Frame 101
loop++;
Symbol 937 MovieClip Frame 102
if (loop < 60) {
gotoAndPlay (101);
}
Symbol 937 MovieClip Frame 103
loop = 0;
Symbol 937 MovieClip Frame 122
_root.gotoAndPlay(39);
Symbol 938 Button
on (release) {
_root.gotoAndPlay(39);
}
Symbol 949 MovieClip Frame 1
Voices = new Sound(this);
loop = 0;
Symbol 949 MovieClip Frame 3
Voices.stop();
Voices.attachSound("Voice_CS9_Convo");
Voices.start(0);
Symbol 949 MovieClip Frame 18
loop++;
Symbol 949 MovieClip Frame 19
if (loop < 160) {
gotoAndPlay (18);
}
Symbol 949 MovieClip Frame 20
loop = 0;
Symbol 949 MovieClip Frame 33
loop++;
Symbol 949 MovieClip Frame 34
if (loop < 6) {
gotoAndPlay (30);
}
Symbol 949 MovieClip Frame 35
loop = 0;
Symbol 949 MovieClip Frame 52
loop++;
Symbol 949 MovieClip Frame 53
if (loop < 100) {
gotoAndPlay (52);
}
Symbol 949 MovieClip Frame 54
loop = 0;
Symbol 949 MovieClip Frame 66
loop++;
Symbol 949 MovieClip Frame 67
if (loop < 100) {
gotoAndPlay (66);
}
Symbol 949 MovieClip Frame 68
loop = 0;
Symbol 949 MovieClip Frame 75
loop++;
Symbol 949 MovieClip Frame 76
if (loop < 100) {
gotoAndPlay (75);
}
Symbol 949 MovieClip Frame 77
loop = 0;
Symbol 949 MovieClip Frame 83
loop++;
Symbol 949 MovieClip Frame 84
if (loop < 200) {
gotoAndPlay (83);
}
Symbol 949 MovieClip Frame 85
loop = 0;
Symbol 949 MovieClip Frame 90
loop++;
Symbol 949 MovieClip Frame 91
if (loop < 200) {
gotoAndPlay (90);
}
Symbol 949 MovieClip Frame 92
loop = 0;
Symbol 949 MovieClip Frame 101
loop++;
Symbol 949 MovieClip Frame 102
if (loop < 500) {
gotoAndPlay (101);
}
Symbol 949 MovieClip Frame 103
loop = 0;
Instance of Symbol 860 MovieClip in Symbol 949 MovieClip Frame 107
onClipEvent (load) {
Text = "THE END";
Pauser = 0;
}
Symbol 949 MovieClip Frame 112
loop++;
Symbol 949 MovieClip Frame 113
if (loop < 200) {
gotoAndPlay (110);
}
Symbol 949 MovieClip Frame 114
loop = 0;
Symbol 949 MovieClip Frame 138
_root.gotoAndPlay(50);
Symbol 950 Button
on (release) {
_root.gotoAndPlay(50);
}