Frame 1
stop();
play.onPress = function () {
gotoAndPlay (2);
};
howto.onPress = function () {
attachMovie("howtoplay", "howtoplay", this.getNextHighestDepth, {_x:100, _y:0});
};
closebutton.onPress = function () {
removeMovieClip("howtoplay");
};
source.onPress = function () {
getURL ("http://geheee.freespaces.com", "_blank");
};
Frame 2
stop();
play.onPress = function () {
gotoAndPlay (3);
};
howto.onPress = function () {
attachMovie("howtoplay", "howtoplay", this.getNextHighestDepth, {_x:100, _y:0});
};
closebutton.onPress = function () {
removeMovieClip("howtoplay");
};
source.onPress = function () {
getURL ("http://geheee.freespaces.com", "_blank");
};
Frame 3
vol = 100;
var musictrack1 = new Sound();
var musictrack2 = new Sound();
musictrack2.attachSound("song2");
musictrack1.attachSound("song1");
musictrack1.start();
songtitle = "Omegabyte";
songnumber = 1;
musictrack1.onSoundComplete = function () {
musictrack1.stop();
musictrack2.start();
songtitle = "Trancetype";
songnumber = 2;
};
musictrack2.onSoundComplete = function () {
musictrack2.stop();
musictrack1.start();
songtitle = "Omegabyte";
songnumber = 1;
};
attachMovie("map", "map", this.getNextHighestDepth(), {_x:0, _y:0});
numofcarsleft = 0;
numofcarsright = 0;
numofcarsdown = 0;
numofcarsup = 0;
timer = 0;
carsdone = 0;
addedcars = 0;
carfreq = 35;
xpos1 = 96;
ypos1 = 96;
xpos2 = 216;
ypos2 = 96;
xpos3 = 360;
ypos3 = 96;
xpos4 = 456;
ypos4 = 96;
xpos5 = 96;
ypos5 = 240;
xpos6 = 216;
ypos6 = 240;
xpos7 = 360;
ypos7 = 240;
xpos8 = 456;
ypos8 = 240;
xpos9 = 96;
ypos9 = 360;
xpos10 = 216;
ypos10 = 360;
xpos11 = 360;
ypos11 = 360;
xpos12 = 456;
ypos12 = 360;
Frame 4
nexttrack.onPress = function () {
if (songnumber == 1) {
musictrack1.stop();
musictrack2.start();
songtitle = "Trancetype";
songnumber = 2;
} else if (songnumber == 2) {
musictrack2.stop();
musictrack1.start();
songtitle = "Omegabyte";
songnumber = 1;
}
};
lasttrack.onPress = function () {
if (songnumber == 1) {
musictrack1.stop();
musictrack2.start();
songtitle = "Trancetype";
songnumber = 2;
} else if (songnumber == 2) {
musictrack2.stop();
musictrack1.start();
songtitle = "Omegabyte";
songnumber = 1;
}
};
volup.onPress = function () {
vol = vol + 10;
if (vol > 100) {
vol = 100;
}
musictrack1.setVolume(vol);
musictrack2.setVolume(vol);
};
voldown.onPress = function () {
vol = vol - 10;
if (vol < 0) {
vol = 0;
}
musictrack1.setVolume(vol);
musictrack2.setVolume(vol);
};
queue = 0;
var n = 1;
while (n <= numofcarsright) {
xpos = eval (("_root.carright" add n) add "._x");
ypos = eval (("_root.carright" add n) add "._y");
if (552 < xpos) {
setProperty(eval ("_root.carright" add n), _x , eval (("_root.carright" add numofcarsright) add "._x"));
setProperty(eval ("_root.carright" add n), _y , eval (("_root.carright" add numofcarsright) add "._y"));
removeMovieClip(eval ("_root.carright" add numofcarsright));
numofcarsright = numofcarsright - 1;
carsdone = carsdone + 1;
} else if (84 == ypos) {
if (((((60 == xpos) && (_root.map.trafficlight1.state == 0)) || ((180 == xpos) && (_root.map.trafficlight2.state == 0))) || ((324 == xpos) && (_root.map.trafficlight3.state == 0))) || ((420 == xpos) && (_root.map.trafficlight4.state == 0))) {
movecar = 0;
} else {
movecar = 1;
}
} else if (228 == ypos) {
if (((((60 == xpos) && (_root.map.trafficlight5.state == 0)) || ((180 == xpos) && (_root.map.trafficlight6.state == 0))) || ((324 == xpos) && (_root.map.trafficlight7.state == 0))) || ((420 == xpos) && (_root.map.trafficlight8.state == 0))) {
movecar = 0;
} else {
movecar = 1;
}
} else if (348 == ypos) {
if (((((60 == xpos) && (_root.map.trafficlight9.state == 0)) || ((180 == xpos) && (_root.map.trafficlight10.state == 0))) || ((324 == xpos) && (_root.map.trafficlight11.state == 0))) || ((420 == ypos) && (_root.map.trafficlight12.state == 0))) {
movecar = 0;
} else {
movecar = 1;
}
} else {
movecar = 1;
}
if (movecar == 1) {
movecarfinal = 1;
var p = 1;
while (p <= numofcarsright) {
if (((xpos > (eval (("_root.carright" add p) add "._x") - 30)) && (xpos < eval (("_root.carright" add p) add "._x"))) && (ypos == eval (("_root.carright" add p) add "._y"))) {
movecarfinal = 0;
}
p++;
}
if (((((60 <= xpos) && (132 >= xpos)) || ((180 <= xpos) && (252 >= xpos))) || ((324 <= xpos) && (396 >= xpos))) || ((420 <= xpos) && (492 >= xpos))) {
var r = 1;
while (r <= numofcarsdown) {
if ((((xpos > (eval (("_root.cardown" add r) add "._x") - 26)) && (xpos < eval (("_root.cardown" add r) add "._x"))) && (ypos > (eval (("_root.cardown" add r) add "._y") - 15))) && (ypos < (eval (("_root.cardown" add r) add "._y") + 15))) {
movecarfinal = 0;
}
r++;
}
var r = 1;
while (r <= numofcarsup) {
if ((((xpos > (eval (("_root.carup" add r) add "._x") - 26)) && (xpos < eval (("_root.carup" add r) add "._x"))) && (ypos > (eval (("_root.carup" add r) add "._y") - 15))) && (ypos < (eval (("_root.carup" add r) add "._y") + 15))) {
movecarfinal = 0;
}
r++;
}
}
}
if (movecarfinal == 1) {
setProperty(eval ("_root.carright" add n), _x , eval (("_root.carright" add n) add "._x") + 2);
}
if (0 == xpos) {
queue = queue + 1;
}
movecarfinal = 0;
n++;
}
var n = 1;
while (n <= numofcarsleft) {
xpos = eval (("_root.carleft" add n) add "._x");
ypos = eval (("_root.carleft" add n) add "._y");
if (0 > xpos) {
setProperty(eval ("_root.carleft" add n), _x , eval (("_root.carleft" add numofcarsleft) add "._x"));
setProperty(eval ("_root.carleft" add n), _y , eval (("_root.carleft" add numofcarsleft) add "._y"));
removeMovieClip(eval ("_root.carleft" add numofcarsleft));
numofcarsleft = numofcarsleft - 1;
carsdone = carsdone + 1;
}
if (104 == ypos) {
if (((((132 == xpos) && (_root.map.trafficlight1.state == 0)) || ((252 == xpos) && (_root.map.trafficlight2.state == 0))) || ((396 == xpos) && (_root.map.trafficlight3.state == 0))) || ((492 == xpos) && (_root.map.trafficlight4.state == 0))) {
movecar = 0;
} else {
movecar = 1;
}
} else if (248 == ypos) {
if (((((132 == xpos) && (_root.map.trafficlight5.state == 0)) || ((252 == xpos) && (_root.map.trafficlight6.state == 0))) || ((396 == xpos) && (_root.map.trafficlight7.state == 0))) || ((492 == xpos) && (_root.map.trafficlight8.state == 0))) {
movecar = 0;
} else {
movecar = 1;
}
} else if (368 == ypos) {
if (((((132 == xpos) && (_root.map.trafficlight9.state == 0)) || ((252 == xpos) && (_root.map.trafficlight10.state == 0))) || ((396 == xpos) && (_root.map.trafficlight11.state == 0))) || ((492 == xpos) && (_root.map.trafficlight12.state == 0))) {
movecar = 0;
} else {
movecar = 1;
}
} else {
movecar = 1;
}
if (movecar == 1) {
movecarfinal = 1;
var p = 1;
while (p <= numofcarsleft) {
if (((xpos > eval (("_root.carleft" add p) add "._x")) && (xpos < (eval (("_root.carleft" add p) add "._x") + 30))) && (ypos == eval (("_root.carleft" add p) add "._y"))) {
movecarfinal = 0;
}
p++;
}
if (((((60 <= xpos) && (132 >= xpos)) || ((180 <= xpos) && (252 >= xpos))) || ((324 <= xpos) && (396 >= xpos))) || ((420 <= xpos) && (492 >= xpos))) {
var r = 1;
while (r <= numofcarsdown) {
if ((((xpos > eval (("_root.cardown" add r) add "._x")) && (xpos < (eval (("_root.cardown" add r) add "._x") + 26))) && (ypos > (eval (("_root.cardown" add r) add "._y") - 15))) && (ypos < (eval (("_root.cardown" add r) add "._y") + 15))) {
movecarfinal = 0;
}
r++;
}
var r = 1;
while (r <= numofcarsup) {
if ((((xpos > eval (("_root.carup" add r) add "._x")) && (xpos < (eval (("_root.carup" add r) add "._x") + 26))) && (ypos > (eval (("_root.carup" add r) add "._y") - 15))) && (ypos < (eval (("_root.carup" add r) add "._y") + 15))) {
movecarfinal = 0;
}
r++;
}
}
}
if (movecarfinal == 1) {
setProperty(eval ("_root.carleft" add n), _x , eval (("_root.carleft" add n) add "._x") - 2);
}
if (552 == xpos) {
queue = queue + 1;
}
movecarfinal = 0;
n++;
}
var m = 1;
while (m <= numofcarsdown) {
xpos = eval (("_root.cardown" add m) add "._x");
ypos = eval (("_root.cardown" add m) add "._y");
if (456 < ypos) {
setProperty(eval ("_root.cardown" add m), _x , eval (("_root.cardown" add numofcarsdown) add "._x"));
setProperty(eval ("_root.cardown" add m), _y , eval (("_root.cardown" add numofcarsdown) add "._y"));
removeMovieClip(eval ("_root.cardown" add numofcarsdown));
numofcarsdown = numofcarsdown - 1;
carsdone = carsdone + 1;
}
if (60 == ypos) {
if (((((84 == xpos) && (_root.map.trafficlight1.state == 1)) || ((204 == xpos) && (_root.map.trafficlight2.state == 1))) || ((348 == xpos) && (_root.map.trafficlight3.state == 1))) || ((444 == xpos) && (_root.map.trafficlight4.state == 1))) {
movecar = 0;
} else {
movecar = 1;
}
} else if (204 == ypos) {
if (((((84 == xpos) && (_root.map.trafficlight5.state == 1)) || ((204 == xpos) && (_root.map.trafficlight6.state == 1))) || ((348 == xpos) && (_root.map.trafficlight7.state == 1))) || ((444 == xpos) && (_root.map.trafficlight8.state == 1))) {
movecar = 0;
} else {
movecar = 1;
}
} else if (324 == ypos) {
if (((((84 == xpos) && (_root.map.trafficlight9.state == 1)) || ((204 == xpos) && (_root.map.trafficlight10.state == 1))) || ((348 == xpos) && (_root.map.trafficlight11.state == 1))) || ((444 == xpos) && (_root.map.trafficlight12.state == 1))) {
movecar = 0;
} else {
movecar = 1;
}
} else {
movecar = 1;
}
if (movecar == 1) {
movecarfinal = 1;
var q = 1;
while (q <= numofcarsdown) {
if (((ypos > (eval (("_root.cardown" add q) add "._y") - 30)) && (ypos < eval (("_root.cardown" add q) add "._y"))) && (xpos == eval (("_root.cardown" add q) add "._x"))) {
movecarfinal = 0;
}
q++;
}
if ((((60 <= eval (("_root.cardown" add m) add "._y")) && (132 >= eval (("_root.cardown" add m) add "._y"))) || ((204 <= eval (("_root.cardown" add m) add "._y")) && (272 >= eval (("_root.cardown" add m) add "._y")))) || ((324 <= eval (("_root.cardown" add m) add "._y")) && (396 >= eval (("_root.cardown" add m) add "._y")))) {
var s = 1;
while (s <= numofcarsright) {
if ((((ypos > (eval (("_root.carright" add s) add "._y") - 26)) && (ypos < eval (("_root.carright" add s) add "._y"))) && (xpos > (eval (("_root.carright" add s) add "._x") - 15))) && (xpos < (eval (("_root.carright" add s) add "._x") + 15))) {
movecarfinal = 0;
}
s++;
}
var s = 1;
while (s <= numofcarsleft) {
if ((((ypos > (eval (("_root.carleft" add s) add "._y") - 26)) && (ypos < eval (("_root.carleft" add s) add "._y"))) && (xpos > (eval (("_root.carleft" add s) add "._x") - 15))) && (xpos < (eval (("_root.carleft" add s) add "._x") + 15))) {
movecarfinal = 0;
}
s++;
}
}
}
if (movecarfinal == 1) {
setProperty(eval ("_root.cardown" add m), _y , eval (("_root.cardown" add m) add "._y") + 2);
}
if (0 == ypos) {
queue = queue + 1;
}
movecarfinal = 0;
m++;
}
var m = 1;
while (m <= numofcarsup) {
xpos = eval (("_root.carup" add m) add "._x");
ypos = eval (("_root.carup" add m) add "._y");
if (0 > ypos) {
setProperty(eval ("_root.carup" add m), _x , eval (("_root.carup" add numofcarsup) add "._x"));
setProperty(eval ("_root.carup" add m), _y , eval (("_root.carup" add numofcarsup) add "._y"));
removeMovieClip(eval ("_root.carup" add numofcarsup));
numofcarsup = numofcarsup - 1;
carsdone = carsdone + 1;
}
if (132 == ypos) {
if (((((104 == xpos) && (_root.map.trafficlight1.state == 1)) || ((224 == xpos) && (_root.map.trafficlight2.state == 1))) || ((368 == xpos) && (_root.map.trafficlight3.state == 1))) || ((464 == xpos) && (_root.map.trafficlight4.state == 1))) {
movecar = 0;
} else {
movecar = 1;
}
} else if (276 == ypos) {
if (((((104 == xpos) && (_root.map.trafficlight5.state == 1)) || ((224 == xpos) && (_root.map.trafficlight6.state == 1))) || ((368 == xpos) && (_root.map.trafficlight7.state == 1))) || ((464 == xpos) && (_root.map.trafficlight8.state == 1))) {
movecar = 0;
} else {
movecar = 1;
}
} else if (396 == ypos) {
if (((((104 == xpos) && (_root.map.trafficlight9.state == 1)) || ((224 == xpos) && (_root.map.trafficlight10.state == 1))) || ((368 == xpos) && (_root.map.trafficlight11.state == 1))) || ((464 == xpos) && (_root.map.trafficlight12.state == 1))) {
movecar = 0;
} else {
movecar = 1;
}
} else {
movecar = 1;
}
if (movecar == 1) {
movecarfinal = 1;
var q = 1;
while (q <= numofcarsup) {
if (((ypos > eval (("_root.carup" add q) add "._y")) && (ypos < (eval (("_root.carup" add q) add "._y") + 30))) && (xpos == eval (("_root.carup" add q) add "._x"))) {
movecarfinal = 0;
}
q++;
}
if ((((60 <= ypos) && (132 >= ypos)) || ((204 <= ypos) && (272 >= ypos))) || ((324 <= ypos) && (396 >= ypos))) {
var s = 1;
while (s <= numofcarsright) {
if ((((ypos > eval (("_root.carright" add s) add "._y")) && (ypos < (eval (("_root.carright" add s) add "._y") + 26))) && (xpos > (eval (("_root.carright" add s) add "._x") - 15))) && (xpos < (eval (("_root.carright" add s) add "._x") + 15))) {
movecarfinal = 0;
}
s++;
}
var s = 1;
while (s <= numofcarsleft) {
if ((((ypos > eval (("_root.carleft" add s) add "._y")) && (ypos < (eval (("_root.carleft" add s) add "._y") + 26))) && (xpos > (eval (("_root.carleft" add s) add "._x") - 15))) && (xpos < (eval (("_root.carleft" add s) add "._x") + 15))) {
movecarfinal = 0;
}
s++;
}
}
}
if (movecarfinal == 1) {
setProperty(eval ("_root.carup" add m), _y , eval (("_root.carup" add m) add "._y") - 2);
}
if (456 == ypos) {
queue = queue + 1;
}
movecarfinal = 0;
m++;
}
_root.map.trafficlight1.onPress = function () {
if (_root.map.trafficlight1.state == 1) {
removeMovieClip("_root.map.trafficlightpicture1");
attachMovie("trafficlightupdown", "trafficlightpicture1", 10013, {_x:xpos1, _y:_root.ypos1});
_root.map.trafficlight1.state = 0;
} else {
removeMovieClip("_root.map.trafficlightpicture1");
attachMovie("trafficlightleftright", "trafficlightpicture1", 10013, {_x:xpos1, _y:ypos1});
_root.map.trafficlight1.state = 1;
}
};
_root.map.trafficlight2.onPress = function () {
if (_root.map.trafficlight2.state == 1) {
_removeMovieClip("_root.map.trafficlightpicture2");
attachMovie("trafficlightupdown", "trafficlightpicture2", 10002, {_x:xpos2, _y:_root.ypos2});
_root.map.trafficlight2.state = 0;
} else {
removeMovieClip("_root.map.trafficlightpicture2");
attachMovie("trafficlightleftright", "trafficlightpicture2", 10002, {_x:xpos2, _y:ypos2});
_root.map.trafficlight2.state = 1;
}
};
_root.map.trafficlight3.onPress = function () {
if (_root.map.trafficlight3.state == 1) {
removeMovieClip("_root.map.trafficlightpicture3");
attachMovie("trafficlightupdown", "trafficlightpicture3", 10003, {_x:xpos3, _y:_root.ypos3});
_root.map.trafficlight3.state = 0;
} else {
removeMovieClip("_root.map.trafficlightpicture3");
attachMovie("trafficlightleftright", "trafficlightpicture3", 10003, {_x:xpos3, _y:ypos3});
_root.map.trafficlight3.state = 1;
}
};
_root.map.trafficlight4.onPress = function () {
if (_root.map.trafficlight4.state == 1) {
_removeMovieClip("_root.map.trafficlightpicture4");
attachMovie("trafficlightupdown", "trafficlightpicture4", 10004, {_x:xpos4, _y:_root.ypos4});
_root.map.trafficlight4.state = 0;
} else {
removeMovieClip("_root.map.trafficlightpicture4");
attachMovie("trafficlightleftright", "trafficlightpicture4", 10004, {_x:xpos4, _y:ypos4});
_root.map.trafficlight4.state = 1;
}
};
_root.map.trafficlight5.onPress = function () {
if (_root.map.trafficlight5.state == 1) {
removeMovieClip("_root.map.trafficlightpicture5");
attachMovie("trafficlightupdown", "trafficlightpicture5", 10005, {_x:xpos5, _y:_root.ypos5});
_root.map.trafficlight5.state = 0;
} else {
removeMovieClip("_root.map.trafficlightpicture5");
attachMovie("trafficlightleftright", "trafficlightpicture5", 10005, {_x:xpos5, _y:ypos5});
_root.map.trafficlight5.state = 1;
}
};
_root.map.trafficlight6.onPress = function () {
if (_root.map.trafficlight6.state == 1) {
removeMovieClip("_root.map.trafficlightpicture6");
attachMovie("trafficlightupdown", "trafficlightpicture6", 10006, {_x:xpos6, _y:_root.ypos6});
_root.map.trafficlight6.state = 0;
} else {
removeMovieClip("_root.map.trafficlightpicture6");
attachMovie("trafficlightleftright", "trafficlightpicture6", 10006, {_x:xpos6, _y:ypos6});
_root.map.trafficlight6.state = 1;
}
};
_root.map.trafficlight7.onPress = function () {
if (_root.map.trafficlight7.state == 1) {
removeMovieClip("_root.map.trafficlightpicture7");
attachMovie("trafficlightupdown", "trafficlightpicture7", 10007, {_x:xpos7, _y:_root.ypos7});
_root.map.trafficlight7.state = 0;
} else {
removeMovieClip("_root.map.trafficlightpicture1");
attachMovie("trafficlightleftright", "trafficlightpicture7", 10007, {_x:xpos7, _y:ypos7});
_root.map.trafficlight7.state = 1;
}
};
_root.map.trafficlight8.onPress = function () {
if (_root.map.trafficlight8.state == 1) {
removeMovieClip("_root.map.trafficlightpicture8");
attachMovie("trafficlightupdown", "trafficlightpicture8", 10008, {_x:xpos8, _y:_root.ypos8});
_root.map.trafficlight8.state = 0;
} else {
removeMovieClip("_root.map.trafficlightpicture8");
attachMovie("trafficlightleftright", "trafficlightpicture8", 10008, {_x:xpos8, _y:ypos8});
_root.map.trafficlight8.state = 1;
}
};
_root.map.trafficlight9.onPress = function () {
if (_root.map.trafficlight9.state == 1) {
removeMovieClip("_root.map.trafficlightpicture9");
attachMovie("trafficlightupdown", "trafficlightpicture9", 10009, {_x:xpos9, _y:_root.ypos9});
_root.map.trafficlight9.state = 0;
} else {
removeMovieClip("_root.map.trafficlightpicture9");
attachMovie("trafficlightleftright", "trafficlightpicture9", 10009, {_x:xpos9, _y:ypos9});
_root.map.trafficlight9.state = 1;
}
};
_root.map.trafficlight10.onPress = function () {
if (_root.map.trafficlight10.state == 1) {
removeMovieClip("_root.map.trafficlightpicture10");
attachMovie("trafficlightupdown", "trafficlightpicture10", 10010, {_x:xpos10, _y:_root.ypos10});
_root.map.trafficlight10.state = 0;
} else {
removeMovieClip("_root.map.trafficlightpicture10");
attachMovie("trafficlightleftright", "trafficlightpicture10", 10010, {_x:xpos10, _y:ypos10});
_root.map.trafficlight10.state = 1;
}
};
_root.map.trafficlight11.onPress = function () {
if (_root.map.trafficlight11.state == 1) {
removeMovieClip("_root.map.trafficlightpicture11");
attachMovie("trafficlightupdown", "trafficlightpicture11", 10011, {_x:xpos11, _y:_root.ypos11});
_root.map.trafficlight11.state = 0;
} else {
removeMovieClip("_root.map.trafficlightpicture11");
attachMovie("trafficlightleftright", "trafficlightpicture11", 10011, {_x:xpos11, _y:ypos11});
_root.map.trafficlight11.state = 1;
}
};
_root.map.trafficlight12.onPress = function () {
if (_root.map.trafficlight12.state == 1) {
removeMovieClip("_root.map.trafficlightpicture12");
attachMovie("trafficlightupdown", "trafficlightpicture12", 10012, {_x:xpos12, _y:_root.ypos12});
_root.map.trafficlight12.state = 0;
} else {
removeMovieClip("_root.map.trafficlightpicture12");
attachMovie("trafficlightleftright", "trafficlightpicture12", 10012, {_x:xpos12, _y:ypos12});
_root.map.trafficlight12.state = 1;
}
};
Frame 5
if (queue == 5) {
gotoAndStop (6);
}
if (carsdone >= 20) {
carfreq = 30;
}
if (carsdone >= 40) {
carfreq = 25;
}
if (carsdone >= 60) {
carfreq = 20;
}
if (carsdone >= 80) {
carfreq = 15;
}
if (carsdone >= 100) {
carfreq = 10;
}
if (carsdone >= 120) {
carfreq = 5;
}
if (carsdone >= 140) {
carfreq = 2;
}
if (timer >= carfreq) {
cartype = random(4) + 1;
if (cartype == 1) {
carposition = random(3) + 1;
addedcars = addedcars + 1;
numofcarsright = numofcarsright + 1;
if (carposition == 1) {
attachMovie("carright", "carright" add numofcarsright, 100000 + addedcars, {_x:0, _y:84});
} else if (carposition == 2) {
attachMovie("carright", "carright" add numofcarsright, 100000 + addedcars, {_x:0, _y:228});
} else if (carposition == 3) {
attachMovie("carright", "carright" add numofcarsright, 100000 + addedcars, {_x:0, _y:348});
}
timer = 0;
} else if (cartype == 2) {
carposition = random(4) + 1;
addedcars = addedcars + 1;
numofcarsdown = numofcarsdown + 1;
if (carposition == 1) {
attachMovie("cardown", "cardown" add numofcarsdown, 100000 + addedcars, {_x:84, _y:0});
} else if (carposition == 2) {
attachMovie("cardown", "cardown" add numofcarsdown, 100000 + addedcars, {_x:204, _y:0});
} else if (carposition == 3) {
attachMovie("cardown", "cardown" add numofcarsdown, 100000 + addedcars, {_x:348, _y:0});
} else if (carposition == 4) {
attachMovie("cardown", "cardown" add numofcarsdown, 100000 + addedcars, {_x:444, _y:0});
}
timer = 0;
} else if (cartype == 3) {
carposition = random(3) + 1;
addedcars = addedcars + 1;
numofcarsleft = numofcarsleft + 1;
if (carposition == 1) {
attachMovie("carleft", "carleft" add numofcarsleft, 100000 + addedcars, {_x:552, _y:104});
} else if (carposition == 2) {
attachMovie("carleft", "carleft" add numofcarsleft, 100000 + addedcars, {_x:552, _y:248});
} else if (carposition == 3) {
attachMovie("carleft", "carleft" add numofcarsleft, 100000 + addedcars, {_x:552, _y:368});
}
timer = 0;
} else if (cartype == 4) {
carposition = random(4) + 1;
addedcars = addedcars + 1;
numofcarsup = numofcarsup + 1;
if (carposition == 1) {
attachMovie("carup", "carup" add numofcarsup, 100000 + addedcars, {_x:104, _y:456});
} else if (carposition == 2) {
attachMovie("carup", "carup" add numofcarsup, 100000 + addedcars, {_x:224, _y:456});
} else if (carposition == 3) {
attachMovie("carup", "carup" add numofcarsup, 100000 + addedcars, {_x:368, _y:456});
} else if (carposition == 4) {
attachMovie("carup", "carup" add numofcarsup, 100000 + addedcars, {_x:464, _y:456});
}
timer = 0;
}
}
timer = timer + 1;
gotoAndPlay (4);
Frame 6
attachMovie("youlose", "youlose", this.getNextHighestDepth(), {_x:0, _y:0});
musictrack1.stop();
musictrack2.stop();
stop();
_root.youlose.playagain.onPress = function () {
removeMovieClip("_root.map");
removeMovieClip("_root.map.trafficlightpicture1");
removeMovieClip("_root.map.trafficlightpicture2");
removeMovieClip("_root.map.trafficlightpicture3");
removeMovieClip("_root.map.trafficlightpicture4");
removeMovieClip("_root.map.trafficlightpicture5");
removeMovieClip("_root.map.trafficlightpicture6");
removeMovieClip("_root.map.trafficlightpicture7");
removeMovieClip("_root.map.trafficlightpicture8");
removeMovieClip("_root.map.trafficlightpicture9");
removeMovieClip("_root.map.trafficlightpicture10");
removeMovieClip("_root.map.trafficlightpicture11");
removeMovieClip("_root.map.trafficlightpicture12");
removeMovieClip("trafficlightpicture1");
removeMovieClip("trafficlightpicture2");
removeMovieClip("trafficlightpicture3");
removeMovieClip("trafficlightpicture4");
removeMovieClip("trafficlightpicture5");
removeMovieClip("trafficlightpicture6");
removeMovieClip("trafficlightpicture7");
removeMovieClip("trafficlightpicture8");
removeMovieClip("trafficlightpicture9");
removeMovieClip("trafficlightpicture10");
removeMovieClip("trafficlightpicture11");
removeMovieClip("trafficlightpicture12");
var n = 1;
while (n <= numofcarsright) {
removeMovieClip(eval ("_root.carright" add n));
n++;
}
var n = 1;
while (n <= numofcarsleft) {
removeMovieClip(eval ("_root.carleft" add n));
n++;
}
var n = 1;
while (n <= numofcarsup) {
removeMovieClip(eval ("_root.carup" add n));
n++;
}
var n = 1;
while (n <= numofcarsdown) {
removeMovieClip(eval ("_root.cardown" add n));
n++;
}
removeMovieClip("_root.youlose");
gotoAndPlay (2);
};
Symbol 3 MovieClip [map] Frame 1
M0 = new Array(0, 0, 0, 1, 2, 9, 0, 0, 1, 2, 0, 0, 0, 0, 1, 2, 0, 0, 1, 2, 10, 0, 0);
M1 = new Array(0, 7, 0, 1, 2, 0, 0, 0, 1, 2, 0, 9, 0, 0, 1, 2, 9, 0, 1, 2, 0, 0, 0);
M2 = new Array(0, 0, 0, 1, 2, 0, 0, 0, 1, 2, 0, 0, 0, 0, 1, 2, 0, 0, 1, 2, 0, 0, 0);
M3 = new Array(3, 3, 3, 5, 6, 3, 3, 3, 5, 6, 3, 3, 3, 3, 5, 6, 3, 3, 5, 6, 3, 3, 3);
M4 = new Array(4, 4, 4, 6, 6, 4, 4, 4, 6, 6, 4, 4, 4, 4, 6, 6, 4, 4, 6, 6, 4, 4, 4);
M5 = new Array(9, 0, 0, 1, 2, 9, 0, 0, 1, 2, 8, 0, 0, 0, 1, 2, 9, 0, 1, 2, 9, 0, 0);
M6 = new Array(0, 0, 0, 1, 2, 0, 0, 0, 1, 2, 0, 0, 0, 0, 1, 2, 0, 0, 1, 2, 0, 0, 0);
M7 = new Array(9, 0, 0, 1, 2, 0, 9, 0, 1, 2, 0, 0, 0, 0, 1, 2, 9, 0, 1, 2, 9, 0, 0);
M8 = new Array(0, 0, 0, 1, 2, 0, 0, 0, 1, 2, 0, 0, 0, 0, 1, 2, 0, 0, 1, 2, 0, 0, 0);
M9 = new Array(3, 3, 3, 5, 6, 3, 3, 3, 5, 6, 3, 3, 3, 3, 5, 6, 3, 3, 5, 6, 3, 3, 3);
M10 = new Array(4, 4, 4, 6, 6, 4, 4, 4, 6, 6, 4, 4, 4, 4, 6, 6, 4, 4, 6, 6, 4, 4, 4);
M11 = new Array(0, 0, 0, 1, 2, 10, 0, 0, 1, 2, 0, 0, 0, 0, 1, 2, 0, 0, 1, 2, 9, 0, 0);
M12 = new Array(0, 7, 0, 1, 2, 0, 0, 0, 1, 2, 0, 0, 0, 0, 1, 2, 0, 0, 1, 2, 0, 0, 0);
M13 = new Array(0, 0, 0, 1, 2, 0, 0, 0, 1, 2, 0, 0, 0, 0, 1, 2, 0, 0, 1, 2, 0, 0, 0);
M14 = new Array(3, 3, 3, 5, 6, 3, 3, 3, 5, 6, 3, 3, 3, 3, 5, 6, 3, 3, 5, 6, 3, 3, 3);
M15 = new Array(4, 4, 4, 6, 6, 4, 4, 4, 6, 6, 4, 4, 4, 4, 6, 6, 4, 4, 6, 6, 4, 4, 4);
M16 = new Array(10, 0, 0, 1, 2, 0, 0, 0, 1, 2, 0, 0, 0, 0, 1, 2, 9, 0, 1, 2, 0, 0, 0);
M17 = new Array(0, 0, 0, 1, 2, 0, 7, 0, 1, 2, 0, 0, 7, 0, 1, 2, 0, 0, 1, 2, 0, 7, 0);
M18 = new Array(0, 0, 0, 1, 2, 0, 0, 0, 1, 2, 0, 0, 0, 0, 1, 2, 0, 0, 1, 2, 0, 0, 0);
trafficlightnumber = 1;
n3 = 1;
var n1 = 0;
while (n1 <= 18) {
var n2 = 0;
while (n2 <= 22) {
if (eval ("M" add n1)[n2] == 0) {
attachMovie("trees", (("trees" add n1) add "-") add n2, n3, {_x:n2 * 24, _y:n1 * 24});
}
if (eval ("M" add n1)[n2] == 1) {
attachMovie("road1", (("road1" add n1) add "-") add n2, n3, {_x:(n2 * 24) + 12, _y:(n1 * 24) + 12});
}
if (eval ("M" add n1)[n2] == 2) {
attachMovie("road2", (("road2" add n1) add "-") add n2, n3, {_x:(n2 * 24) + 12, _y:(n1 * 24) + 12});
}
if (eval ("M" add n1)[n2] == 3) {
attachMovie("road3", (("road3" add n1) add "-") add n2, n3, {_x:(n2 * 24) + 12, _y:(n1 * 24) + 12});
}
if (eval ("M" add n1)[n2] == 4) {
attachMovie("road4", (("road4" add n1) add "-") add n2, n3, {_x:(n2 * 24) + 12, _y:(n1 * 24) + 12});
}
if (eval ("M" add n1)[n2] == 10) {
attachMovie("building2", (("building2" add n1) add "-") add n2, 5000 + n3, {_x:n2 * 24, _y:n1 * 24});
}
if (eval ("M" add n1)[n2] == 7) {
attachMovie("building", (("building" add n1) add "-") add n2, 5000 + n3, {_x:(n2 * 24) + 12, _y:(n1 * 24) + 12});
}
if (eval ("M" add n1)[n2] == 8) {
attachMovie("stadium", (("stadium" add n1) add "-") add n2, 5000 + n3, {_x:n2 * 24, _y:n1 * 24});
}
if (eval ("M" add n1)[n2] == 9) {
attachMovie("house", (("house" add n1) add "-") add n2, 5000 + n3, {_x:n2 * 24, _y:n1 * 24});
}
if (eval ("M" add n1)[n2] == 5) {
attachMovie("trafficlight", "trafficlight" add trafficlightnumber, n3);
attachMovie("trafficlightleftright", "trafficlightpicture" add trafficlightnumber, n3 + 1, {_x:(n2 * 24) + 24, _y:(n1 * 24) + 24});
eval ("trafficlight" add trafficlightnumber)._x = (n2 + 1) * 24;
eval ("trafficlight" add trafficlightnumber)._y = (n1 + 1) * 24;
eval ("trafficlight" add trafficlightnumber).state = 1;
trafficlightnumber = trafficlightnumber + 1;
}
n3 = n3 + 2;
n2++;
}
n2 = 0;
n1++;
}
Symbol 62 MovieClip [howtoplay] Frame 1
_root.howtoplay.closebutton.onPress = function () {
removeMovieClip("_root.howtoplay");
};
Symbol 69 Button
on (release) {
_root.play();
}
Symbol 70 MovieClip Frame 1
_root.stop();
PercentLoaded = (_root.getBytesLoaded() / _root.getBytesTotal()) * 100;
if (PercentLoaded != 100) {
setProperty(bar, _xscale , PercentLoaded);
} else {
gotoAndStop ("loaded");
}
Symbol 70 MovieClip Frame 2
gotoAndPlay (1);