Section 1
//alarm_17 (SIMAirTraffic_fla.alarm_17)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class alarm_17 extends MovieClip {
public function alarm_17(){
addFrameScript(9, frame10);
}
function frame10(){
stop();
}
}
}//package SIMAirTraffic_fla
Section 2
//choice_mc_65 (SIMAirTraffic_fla.choice_mc_65)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class choice_mc_65 extends MovieClip {
public var choice2:MovieClip;
public function choice_mc_65(){
addFrameScript(0, frame1, 9, frame10);
}
function frame10(){
stop();
}
function frame1(){
stop();
}
}
}//package SIMAirTraffic_fla
Section 3
//dead_plane2_20 (SIMAirTraffic_fla.dead_plane2_20)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class dead_plane2_20 extends MovieClip {
public function dead_plane2_20(){
addFrameScript(37, frame38);
}
function frame38(){
stop();
}
}
}//package SIMAirTraffic_fla
Section 4
//explosion_2_19 (SIMAirTraffic_fla.explosion_2_19)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class explosion_2_19 extends MovieClip {
public function explosion_2_19(){
addFrameScript(34, frame35);
}
function frame35(){
stop();
}
}
}//package SIMAirTraffic_fla
Section 5
//game_level_81 (SIMAirTraffic_fla.game_level_81)
package SIMAirTraffic_fla {
import flash.events.*;
import flash.media.*;
import flash.display.*;
import flash.ui.*;
import flash.net.*;
import flash.text.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.filters.*;
import flash.geom.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.system.*;
import flash.utils.*;
import flash.xml.*;
public dynamic class game_level_81 extends MovieClip {
public var retry_btn:SimpleButton;
public var cont_btn:SimpleButton;
public var more_games_btn:SimpleButton;
public var play_more_btn:SimpleButton;
public function game_level_81(){
addFrameScript(0, frame1, 1, frame2, 24, frame25, 79, frame80, 84, frame85, 109, frame110, 149, frame150, 154, frame155, 177, frame178, 204, frame205);
}
function frame110(){
stop();
}
function frame1(){
stop();
gotoAndPlay(52);
}
function frame178(){
stop();
}
function frame155(){
MovieClip(parent).p_btn.visible = false;
}
function frame80(){
stop();
}
function frame25(){
stop();
}
function frame85(){
MovieClip(parent).p_btn.visible = false;
}
function frame205(){
stop();
}
function frame2(){
MovieClip(root).game_menu.tutor.gotoAndStop(1);
}
function frame150(){
stop();
}
}
}//package SIMAirTraffic_fla
Section 6
//level_text__61 (SIMAirTraffic_fla.level_text__61)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class level_text__61 extends MovieClip {
public function level_text__61(){
addFrameScript(0, frame1);
}
function frame1(){
gotoAndStop((MovieClip(root).currentFrame - 18));
}
}
}//package SIMAirTraffic_fla
Section 7
//level_text_60 (SIMAirTraffic_fla.level_text_60)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class level_text_60 extends MovieClip {
public function level_text_60(){
addFrameScript(120, frame121);
}
function frame121(){
stop();
}
}
}//package SIMAirTraffic_fla
Section 8
//level2_42 (SIMAirTraffic_fla.level2_42)
package SIMAirTraffic_fla {
import flash.events.*;
import flash.media.*;
import flash.display.*;
import flash.ui.*;
import flash.net.*;
import flash.text.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.filters.*;
import flash.geom.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.system.*;
import flash.utils.*;
import flash.xml.*;
public dynamic class level2_42 extends MovieClip {
public function level2_42(){
addFrameScript(0, frame1);
}
function frame1(){
MovieClip(root).mySharedObject = SharedObject.getLocal("republicofcode");
if (MovieClip(root).mySharedObject.data.currentLevel >= "2"){
gotoAndStop(2);
} else {
gotoAndStop(1);
};
}
}
}//package SIMAirTraffic_fla
Section 9
//level3_44 (SIMAirTraffic_fla.level3_44)
package SIMAirTraffic_fla {
import flash.events.*;
import flash.media.*;
import flash.display.*;
import flash.ui.*;
import flash.net.*;
import flash.text.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.filters.*;
import flash.geom.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.system.*;
import flash.utils.*;
import flash.xml.*;
public dynamic class level3_44 extends MovieClip {
public function level3_44(){
addFrameScript(0, frame1);
}
function frame1(){
MovieClip(root).mySharedObject = SharedObject.getLocal("republicofcode");
if (MovieClip(root).mySharedObject.data.currentLevel >= "3"){
gotoAndStop(2);
} else {
gotoAndStop(1);
};
}
}
}//package SIMAirTraffic_fla
Section 10
//level4_46 (SIMAirTraffic_fla.level4_46)
package SIMAirTraffic_fla {
import flash.events.*;
import flash.media.*;
import flash.display.*;
import flash.ui.*;
import flash.net.*;
import flash.text.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.filters.*;
import flash.geom.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.system.*;
import flash.utils.*;
import flash.xml.*;
public dynamic class level4_46 extends MovieClip {
public function level4_46(){
addFrameScript(0, frame1);
}
function frame1(){
MovieClip(root).mySharedObject = SharedObject.getLocal("republicofcode");
if (MovieClip(root).mySharedObject.data.currentLevel >= "4"){
gotoAndStop(2);
} else {
gotoAndStop(1);
};
}
}
}//package SIMAirTraffic_fla
Section 11
//level5_48 (SIMAirTraffic_fla.level5_48)
package SIMAirTraffic_fla {
import flash.events.*;
import flash.media.*;
import flash.display.*;
import flash.ui.*;
import flash.net.*;
import flash.text.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.filters.*;
import flash.geom.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.system.*;
import flash.utils.*;
import flash.xml.*;
public dynamic class level5_48 extends MovieClip {
public function level5_48(){
addFrameScript(0, frame1);
}
function frame1(){
MovieClip(root).mySharedObject = SharedObject.getLocal("republicofcode");
if (MovieClip(root).mySharedObject.data.currentLevel >= "5"){
gotoAndStop(2);
} else {
gotoAndStop(1);
};
}
}
}//package SIMAirTraffic_fla
Section 12
//lights_27 (SIMAirTraffic_fla.lights_27)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class lights_27 extends MovieClip {
public var l1:MovieClip;
public var l2:MovieClip;
public var l3:MovieClip;
public var l4:MovieClip;
public var l5:MovieClip;
public var l6:MovieClip;
public var l7:MovieClip;
public var l8:MovieClip;
public function lights_27(){
addFrameScript(0, frame1);
}
function frame1(){
l1.gotoAndPlay(30);
l2.gotoAndPlay(30);
l3.gotoAndPlay(20);
l4.gotoAndPlay(20);
l5.gotoAndPlay(10);
l6.gotoAndPlay(10);
l7.gotoAndPlay(1);
l8.gotoAndPlay(1);
}
}
}//package SIMAirTraffic_fla
Section 13
//lights2_87 (SIMAirTraffic_fla.lights2_87)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class lights2_87 extends MovieClip {
public var l1:MovieClip;
public var l2:MovieClip;
public var l3:MovieClip;
public var l4:MovieClip;
public var l5:MovieClip;
public var l6:MovieClip;
public var l7:MovieClip;
public var l8:MovieClip;
public function lights2_87(){
addFrameScript(0, frame1);
}
function frame1(){
l8.gotoAndPlay(30);
l7.gotoAndPlay(30);
l6.gotoAndPlay(20);
l5.gotoAndPlay(20);
l4.gotoAndPlay(10);
l3.gotoAndPlay(10);
l2.gotoAndPlay(1);
l1.gotoAndPlay(1);
}
}
}//package SIMAirTraffic_fla
Section 14
//lights3_89 (SIMAirTraffic_fla.lights3_89)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class lights3_89 extends MovieClip {
public var l1:MovieClip;
public var l2:MovieClip;
public var l3:MovieClip;
public var l4:MovieClip;
public var l5:MovieClip;
public var l6:MovieClip;
public var l7:MovieClip;
public var l8:MovieClip;
public function lights3_89(){
addFrameScript(0, frame1);
}
function frame1(){
l8.gotoAndPlay(30);
l7.gotoAndPlay(30);
l6.gotoAndPlay(20);
l5.gotoAndPlay(20);
l4.gotoAndPlay(10);
l3.gotoAndPlay(10);
l2.gotoAndPlay(1);
l1.gotoAndPlay(1);
}
}
}//package SIMAirTraffic_fla
Section 15
//lights4_90 (SIMAirTraffic_fla.lights4_90)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class lights4_90 extends MovieClip {
public var l1:MovieClip;
public var l2:MovieClip;
public var l3:MovieClip;
public var l4:MovieClip;
public var l5:MovieClip;
public var l6:MovieClip;
public var l7:MovieClip;
public var l8:MovieClip;
public function lights4_90(){
addFrameScript(0, frame1);
}
function frame1(){
l8.gotoAndPlay(1);
l7.gotoAndPlay(1);
l6.gotoAndPlay(10);
l5.gotoAndPlay(10);
l4.gotoAndPlay(20);
l3.gotoAndPlay(20);
l2.gotoAndPlay(30);
l1.gotoAndPlay(30);
}
}
}//package SIMAirTraffic_fla
Section 16
//lights5_94 (SIMAirTraffic_fla.lights5_94)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class lights5_94 extends MovieClip {
public var l1:MovieClip;
public var l2:MovieClip;
public var l3:MovieClip;
public var l4:MovieClip;
public var l5:MovieClip;
public var l6:MovieClip;
public var l7:MovieClip;
public var l8:MovieClip;
public function lights5_94(){
addFrameScript(0, frame1);
}
function frame1(){
l8.gotoAndPlay(30);
l7.gotoAndPlay(30);
l6.gotoAndPlay(20);
l5.gotoAndPlay(20);
l4.gotoAndPlay(10);
l3.gotoAndPlay(10);
l2.gotoAndPlay(1);
l1.gotoAndPlay(1);
}
}
}//package SIMAirTraffic_fla
Section 17
//lights5_95 (SIMAirTraffic_fla.lights5_95)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class lights5_95 extends MovieClip {
public var l1:MovieClip;
public var l2:MovieClip;
public var l3:MovieClip;
public var l4:MovieClip;
public var l5:MovieClip;
public var l6:MovieClip;
public var l7:MovieClip;
public var l8:MovieClip;
public function lights5_95(){
addFrameScript(0, frame1);
}
function frame1(){
l8.gotoAndPlay(1);
l7.gotoAndPlay(1);
l6.gotoAndPlay(10);
l5.gotoAndPlay(10);
l4.gotoAndPlay(20);
l3.gotoAndPlay(20);
l2.gotoAndPlay(30);
l1.gotoAndPlay(30);
}
}
}//package SIMAirTraffic_fla
Section 18
//lights5_97 (SIMAirTraffic_fla.lights5_97)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class lights5_97 extends MovieClip {
public var l1:MovieClip;
public var l2:MovieClip;
public var l3:MovieClip;
public var l4:MovieClip;
public var l5:MovieClip;
public var l6:MovieClip;
public var l8:MovieClip;
public function lights5_97(){
addFrameScript(0, frame1);
}
function frame1(){
l8.gotoAndPlay(1);
l6.gotoAndPlay(10);
l5.gotoAndPlay(10);
l4.gotoAndPlay(20);
l3.gotoAndPlay(20);
l2.gotoAndPlay(30);
l1.gotoAndPlay(30);
}
}
}//package SIMAirTraffic_fla
Section 19
//lights5_98 (SIMAirTraffic_fla.lights5_98)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class lights5_98 extends MovieClip {
public var l1:MovieClip;
public var l2:MovieClip;
public var l3:MovieClip;
public var l4:MovieClip;
public var l5:MovieClip;
public var l6:MovieClip;
public var l7:MovieClip;
public var l8:MovieClip;
public function lights5_98(){
addFrameScript(0, frame1);
}
function frame1(){
l8.gotoAndPlay(1);
l7.gotoAndPlay(1);
l6.gotoAndPlay(10);
l5.gotoAndPlay(10);
l4.gotoAndPlay(20);
l3.gotoAndPlay(20);
l2.gotoAndPlay(30);
l1.gotoAndPlay(30);
}
}
}//package SIMAirTraffic_fla
Section 20
//main_menu_32 (SIMAirTraffic_fla.main_menu_32)
package SIMAirTraffic_fla {
import flash.events.*;
import flash.media.*;
import flash.display.*;
import flash.ui.*;
import flash.net.*;
import flash.text.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.filters.*;
import flash.geom.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.system.*;
import flash.utils.*;
import flash.xml.*;
public dynamic class main_menu_32 extends MovieClip {
public var minilogo:MovieClip;
public var btns:MovieClip;
public var levels:MovieClip;
public function main_menu_32(){
addFrameScript(49, frame50, 100, frame101, 184, frame185);
}
function frame185(){
MovieClip(root).addLevelListener();
stop();
}
function frame50(){
stop();
}
function frame101(){
stop();
MovieClip(root).canUnPause = true;
MovieClip(root).gotoAndPlay(19);
}
}
}//package SIMAirTraffic_fla
Section 21
//MainTimeline (SIMAirTraffic_fla.MainTimeline)
package SIMAirTraffic_fla {
import flash.events.*;
import flash.media.*;
import flash.display.*;
import flash.ui.*;
import flash.net.*;
import flash.text.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.filters.*;
import flash.geom.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.system.*;
import flash.utils.*;
import flash.xml.*;
public dynamic class MainTimeline extends MovieClip {
public var fogHolder:MovieClip;
public var sound_ON:Boolean;
public var ctxMenu:ContextMenu;
public var game_menu2:MovieClip;
public var cash:Number;
public var btnFoggy:SimpleButton;
public var addPlane_timer:Number;
public var addingPlane:Boolean;
public var bg:MovieClip;
public var fail_timer_start:Boolean;
public var bg_btn_press:Boolean;
public var okToPlay:Boolean;
public var Fail:Boolean;
public var Paused:Boolean;
public var addPlane2;
public var debug:Boolean;
public var urlToGame;
public var addingPlane2:Boolean;
public var ctxCopyright;
public var mcLogo:MovieClip;
public var Furl:String;
public var j:int;
public var snds_A:Array;
public var i:int;
public var CF:Number;
public var win_listener_added;
public var port:MovieClip;
public var increaseTakeOffSps_Pos:Number;
public var stagewidth:Number;
public var request_txt_2:MovieClip;
public var game_menu:MovieClip;
public var alarm_snd_timer:Number;
public var gameDura:int;
public var taxi_Pos;
public var arrivals:Number;
public var gameName:String;
public var MP:Number;
public var stageheight:Number;
public var planes_A:Array;
public var take_off:Number;
public var s:SoundTransform;
public var landingPos:Number;
public var request_txt:MovieClip;
public var FOGlock:Boolean;
public var ff:Boolean;
public var mySharedObject:SharedObject;
public var next_lvl:Boolean;
public var selected_one:Boolean;
public var win:MovieClip;
public var random_Y:Number;
public var ctxNotice;
public var explode:MovieClip;
public var fail_timer:Number;
public var lastPos:Number;
public var line:Number;
public var pre1:MovieClip;
public var flyAway_Pos:Number;
public var o_emo:MovieClip;
public var fail_listener_added;
public function MainTimeline(){
addFrameScript(0, frame1, 1, frame2, 2, frame3, 3, frame4, 9, frame10, 14, frame15, 18, frame19, 19, frame20, 20, frame21, 21, frame22, 22, frame23, 23, frame24, 24, frame25, 25, frame26, 26, frame27, 27, frame28, 28, frame29, 29, frame30);
}
public function useless_func(_arg1:MouseEvent){
bg_btn_press = true;
}
public function deleteAll(){
i = 0;
while (i < planes_A.length) {
removeChild(planes_A[i]);
planes_A.splice(i, 0);
i++;
};
removeChild(explode);
removeChild(o_emo);
removeChild(game_menu);
removeChild(bg);
removeChild(port);
}
public function more_games_func2(_arg1:MouseEvent){
trace("pressed");
var _local2:URLRequest = new URLRequest("http://www.freegamesforyourwebsite.com/?simairstraffic");
navigateToURL(_local2, "_blank");
}
public function s_func(_arg1:MouseEvent){
if (sound_ON){
s.volume = 0;
SoundMixer.soundTransform = s;
sound_ON = false;
} else {
s.volume = 1;
SoundMixer.soundTransform = s;
sound_ON = true;
};
}
function frame28(){
fail_timer = 150;
lastPos = 13;
flyAway_Pos = 7;
taxi_Pos = 3;
landingPos = 6;
take_off = 0;
arrivals = 0;
cash = 60000;
increaseTakeOffSps_Pos = 4;
addPlane_timer = 100;
random_Y = 0;
planes_A = new Array();
stop();
ff = false;
Paused = false;
selected_one = false;
Fail = false;
fail_timer_start = false;
bg_btn_press = false;
sound_ON = true;
next_lvl = false;
fail_listener_added = false;
win_listener_added = false;
game_menu.tutor.gotoAndStop((game_menu.tutor.currentFrame + 1));
request_txt.visible = false;
request_txt_2.visible = false;
port.radar.rotation = (Math.random() * 360);
stage.addEventListener(MouseEvent.MOUSE_DOWN, close_choice);
game_menu.ff_btn.addEventListener(MouseEvent.MOUSE_DOWN, ff_function);
game_menu.p_btn.addEventListener(MouseEvent.MOUSE_DOWN, p_function);
game_menu.s_btn.addEventListener(MouseEvent.MOUSE_DOWN, s_func);
game_menu.choice.choice2.do_btns.goRound_btn.addEventListener(MouseEvent.MOUSE_DOWN, goRound);
game_menu.choice.choice2.do_btns.slowDown_btn.addEventListener(MouseEvent.MOUSE_DOWN, slowDown_func);
game_menu.choice.choice2.do_btns.speedUp_btn.addEventListener(MouseEvent.MOUSE_DOWN, speedUp_func);
game_menu.choice.choice2.do_btns.getReady_btn.addEventListener(MouseEvent.MOUSE_DOWN, getReady_func);
game_menu.choice.choice2.do_btns.cross_btn.addEventListener(MouseEvent.MOUSE_DOWN, cross_func);
game_menu.choice.choice2.do_btns.taxi_btn.addEventListener(MouseEvent.MOUSE_DOWN, taxi_func);
game_menu.choice.choice2.addEventListener(MouseEvent.MOUSE_DOWN, useless_func);
game_menu.minilogo.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func2);
MP = (Math.PI / 180);
addEventListener(Event.ENTER_FRAME, on_enter_frame);
mySharedObject = SharedObject.getLocal("republicofcode");
if (mySharedObject.data.currentLevel < "5"){
mySharedObject.data.currentLevel = "5";
};
}
public function level_refresh(_arg1:MouseEvent){
trace("restart or continue");
game_menu.game_level.play();
game_menu.game_level.retry_btn.removeEventListener(MouseEvent.MOUSE_DOWN, level_refresh);
game_menu.game_level.cont_btn.removeEventListener(MouseEvent.MOUSE_DOWN, level_refresh);
game_menu.game_level.play_more_btn.removeEventListener(MouseEvent.MOUSE_DOWN, play_more_func2);
game_menu.game_level.more_games_btn.removeEventListener(MouseEvent.MOUSE_DOWN, more_games_func2);
fail_listener_added = false;
win_listener_added = false;
}
public function play_more_func(_arg1:MouseEvent){
play_snd(2);
var _local2:URLRequest = new URLRequest("http://www.freeonlinegames.com/?simairstraffic");
navigateToURL(_local2, "_blank");
}
public function take_off_loop(_arg1){
if ((((_arg1.currentPos == 3)) && (_arg1.taxiing))){
_arg1.taxiing_park = true;
_arg1.spd = 0;
};
if ((((((((_arg1.currentPos >= increaseTakeOffSps_Pos)) && (!(_arg1.flyaway)))) && (_arg1.canflyAway))) && (!(_arg1.taxiing)))){
_arg1.plane_shadow.gotoAndStop(_arg1.decent);
if (_arg1.decent > 1){
if (_arg1.decent > 250){
_arg1.decent = 250;
};
if (_arg1.spd >= 0.55){
if (!_arg1.snd_9){
play_snd(9);
_arg1.snd_9 = true;
};
if (!ff){
_arg1.decent = (_arg1.decent - 1);
} else {
_arg1.decent = (_arg1.decent - 5);
};
};
};
if (_arg1.spd >= 0.9){
_arg1.spd = 0.9;
} else {
if (!ff){
_arg1.spd = (_arg1.spd + 0.0024);
} else {
_arg1.spd = (_arg1.spd + 0.012);
};
};
};
if (((_arg1.selected_t) && ((_arg1.spd < 0.9)))){
game_menu.choice.choice2.do_btns.slowDown_btn.visible = false;
game_menu.choice.choice2.do_btns.speedUp_btn.visible = true;
} else {
if (((_arg1.selected_t) && ((_arg1.spd > 0.5)))){
game_menu.choice.choice2.do_btns.slowDown_btn.visible = true;
game_menu.choice.choice2.do_btns.speedUp_btn.visible = false;
};
};
if (((((!(_arg1.refueling)) && ((_arg1.currentPos == lastPos)))) && (!(_arg1.started_refuel)))){
_arg1.currentPos = 0;
if (CF == 20){
_arg1.pos_A_1 = new Array([260, 310]);
} else {
if (CF == 22){
_arg1.pos_A_1 = new Array([390, 310]);
} else {
if ((((CF == 24)) && ((_arg1.line == 0)))){
_arg1.pos_A_1 = new Array([340, 220]);
} else {
if ((((CF == 24)) && ((_arg1.line == 1)))){
_arg1.pos_A_1 = new Array([250, 220]);
} else {
if ((((CF == 26)) && ((_arg1.line == 0)))){
_arg1.pos_A_1 = new Array([305, 340]);
} else {
if ((((CF == 26)) && ((_arg1.line == 1)))){
_arg1.pos_A_1 = new Array([305, 340]);
} else {
if (CF == 28){
_arg1.pos_A_1 = new Array([345, 180]);
};
};
};
};
};
};
};
_arg1.refueling = true;
_arg1.started_refuel = true;
};
if (_arg1.refueling){
if (!ff){
_arg1.refuel_timer = (_arg1.refuel_timer - 1);
} else {
_arg1.refuel_timer = (_arg1.refuel_timer - 5);
};
if (_arg1.refuel_timer <= 0){
_arg1.canflyAway = true;
if (_arg1.ready_showed == false){
if (CF == 20){
request_txt.visible = true;
request_txt.gotoAndPlay(2);
} else {
if (CF == 22){
request_txt.visible = true;
request_txt.gotoAndPlay(2);
} else {
if ((((CF == 24)) && ((_arg1.line == 0)))){
request_txt.visible = true;
request_txt.gotoAndPlay(2);
} else {
if ((((CF == 24)) && ((_arg1.line == 1)))){
request_txt_2.visible = true;
request_txt_2.gotoAndPlay(2);
} else {
if (CF == 26){
request_txt.visible = true;
request_txt.gotoAndPlay(2);
} else {
if ((((CF == 28)) && ((_arg1.line == 0)))){
request_txt.visible = true;
request_txt.gotoAndPlay(2);
} else {
if ((((CF == 28)) && ((_arg1.line == 1)))){
request_txt_2.visible = true;
request_txt_2.gotoAndPlay(2);
} else {
if ((((CF == 28)) && ((_arg1.line == 2)))){
request_txt_2.visible = true;
request_txt_2.gotoAndPlay(2);
};
};
};
};
};
};
};
};
_arg1.currentPos = 0;
if (CF == 20){
_arg1.pos_A_1 = new Array([180, 260], [235, 210], [290, 235], [315, 240], [370, 350], [520, 400], [700, 300], [0, 0]);
} else {
if ((((CF == 22)) && ((_arg1.line == 0)))){
_arg1.pos_A_1 = new Array([260, 290], [215, 360], [180, 380], [160, 360], [180, 280], [250, 215], [190, -20], [0, 0]);
} else {
if ((((CF == 22)) && ((_arg1.line == 1)))){
_arg1.pos_A_1 = new Array([260, 310], [285, 320], [300, 340], [350, 320], [370, 300], [460, 170], [520, -20], [520, -20]);
} else {
if ((((CF == 24)) && ((_arg1.line == 0)))){
_arg1.pos_A_1 = new Array([410, 160], [370, 160], [325, 160], [315, 165], [320, 185], [345, 320], [400, 550], [0, 0]);
} else {
if ((((CF == 24)) && ((_arg1.line == 1)))){
_arg1.pos_A_1 = new Array([215, 430], [165, 440], [160, 360], [160, 360], [235, 342], [310, 330], [475, 400], [600, 550]);
} else {
if ((((CF == 26)) && ((_arg1.line == 0)))){
_arg1.pos_A_1 = new Array([380, 380], [425, 310], [400, 265], [385, 0xFF], [320, 240], [200, 220], [180, -20], [0, 0]);
} else {
if ((((CF == 26)) && ((_arg1.line == 1)))){
_arg1.pos_A_1 = new Array([380, 380], [300, 380], [265, 355], [270, 300], [280, 200], [280, -50], [280, -50], [0, 0]);
} else {
if ((((CF == 28)) && ((_arg1.line == 0)))){
_arg1.pos_A_1 = new Array([277, 225], [175, 200], [145, 220], [155, 250], [205, 250], [290, 265], [650, 230], [0, 0]);
} else {
if ((((CF == 28)) && ((_arg1.line == 1)))){
_arg1.pos_A_1 = new Array([415, 330], [415, 335], [395, 360], [395, 360], [260, 380], [-40, 415], [-40, 415], [0, 0]);
} else {
if ((((CF == 28)) && ((_arg1.line == 2)))){
_arg1.pos_A_1 = new Array([415, 330], [415, 335], [395, 360], [395, 360], [260, 380], [-40, 415], [-40, 415], [0, 0]);
};
};
};
};
};
};
};
};
};
};
play_snd(1);
_arg1.ready_showed = true;
};
if (_arg1.can_get_ready_for_take_off){
_arg1.refueling = false;
};
} else {
_arg1.spd = 0;
};
if (((_arg1.selected_t) && (_arg1.ready_showed))){
game_menu.choice.choice2.do_btns.gotoAndStop(3);
};
};
if ((((((_arg1.currentPos == flyAway_Pos)) && (!(_arg1.flyaway)))) && (_arg1.canflyAway))){
take_off = (take_off + 1);
cash = (cash + 1150);
if ((((_arg1.selected_t == true)) && ((game_menu.choice.currentFrame == 10)))){
game_menu.choice.play();
};
removeChild(_arg1);
planes_A.splice(i, 1);
_arg1.flyaway = true;
};
}
public function loadingBar(_arg1:Event):void{
var _local3:*;
var _local2:* = Math.random();
if (_local2 < ((loaderInfo.bytesLoaded / loaderInfo.bytesTotal) / 5)){
_local3 = new fog_1();
_local3.cacheAsBitmap = true;
_local3.x = (stagewidth / 2);
_local3.y = (stageheight / 2);
_local3.scaleX = (_local3.scaleY = 0);
_local3.gotoAndStop(((Math.random() * 10) + 1));
_local3.speed = 100;
_local3.alpha = 0;
_local3.grow = (Math.random() / 100);
_local3.fade = false;
_local3.targetX = (Math.random() * 10);
if (_local3.targetX < 5){
_local3.targetX = (Math.random() * 10);
if (_local3.targetX < 5){
_local3.targetX = -100;
} else {
_local3.targetX = (stagewidth + 100);
};
_local3.targetY = (Math.random() * stageheight);
} else {
_local3.targetY = (Math.random() * 10);
if (_local3.targetY < 5){
_local3.targetY = -100;
} else {
_local3.targetY = (stageheight + 100);
};
_local3.targetX = (Math.random() * stagewidth);
};
fogHolder.addChild(_local3);
_local3.addEventListener(Event.ENTER_FRAME, FOGFly);
};
}
public function addLevelListener(){
game_menu2.main_menu.levels.more_games_btn.addEventListener(MouseEvent.MOUSE_DOWN, more_games_func);
game_menu2.main_menu.levels.play_more_btn.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func);
game_menu2.main_menu.levels.levels.level1.addEventListener(MouseEvent.MOUSE_DOWN, level1func);
game_menu2.main_menu.levels.levels.level2.addEventListener(MouseEvent.MOUSE_DOWN, level2func);
game_menu2.main_menu.levels.levels.level3.addEventListener(MouseEvent.MOUSE_DOWN, level3func);
game_menu2.main_menu.levels.levels.level4.addEventListener(MouseEvent.MOUSE_DOWN, level4func);
game_menu2.main_menu.levels.levels.level5.addEventListener(MouseEvent.MOUSE_DOWN, level5func);
}
public function slowDown_func(_arg1:MouseEvent){
var _local2:*;
i = 0;
while (i < planes_A.length) {
_local2 = planes_A[i];
if (_local2.selected_t == true){
_local2.spd = 0.5;
};
i++;
};
}
public function showProgress(_arg1:Event):void{
pre1.percentGame = Math.floor(((loaderInfo.bytesLoaded / loaderInfo.bytesTotal) * 100));
pre1.percentDura = Math.floor(((getTimer() / pre1.dura) * 100));
pre1.percent = Math.min(pre1.percentGame, pre1.percentDura);
pre1.procent.text = Math.round(pre1.percent);
pre1.preRedBar.width = (Math.round(pre1.percent) * 0.98);
if (pre1.percent > 99){
Furl = loaderInfo.url;
stage.removeEventListener(Event.ENTER_FRAME, showProgress);
play();
};
loadingBar(_arg1);
}
public function loop_snd(_arg1){
var _local2:Sound = new (snds_A[_arg1]);
_local2.play(1, 9999);
}
public function f_rotation(_arg1:Number, _arg2:Number):Number{
return (((Math.atan2(_arg2, _arg1) * 180) / Math.PI));
}
public function taxi_func(_arg1:MouseEvent){
var _local2:*;
getReady_func(_local2);
i = 0;
while (i < planes_A.length) {
_local2 = planes_A[i];
if (_local2.selected_t == true){
_local2.taxiing = true;
};
i++;
};
}
function frame15(){
stop();
alarm_snd_timer = 35;
game_menu2.main_menu.btns.fogcom.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func);
game_menu2.main_menu.minilogo.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func);
game_menu2.main_menu.btns.play_btn.addEventListener(MouseEvent.MOUSE_DOWN, continue_func);
game_menu2.main_menu.btns.play_more_btn.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func);
game_menu2.main_menu.btns.more_games_btn.addEventListener(MouseEvent.MOUSE_DOWN, more_games_func);
fail_timer = 150;
lastPos = 11;
flyAway_Pos = 7;
taxi_Pos = 3;
landingPos = 6;
take_off = 0;
arrivals = 0;
cash = 20000;
increaseTakeOffSps_Pos = 4;
addPlane_timer = 100;
random_Y = 0;
line = 1;
CF = currentFrame;
addPlane2 = 200;
planes_A = new Array();
stop();
ff = false;
Paused = false;
selected_one = false;
Fail = false;
fail_timer_start = false;
bg_btn_press = false;
sound_ON = true;
addingPlane = false;
addingPlane2 = false;
next_lvl = false;
fail_listener_added = false;
win_listener_added = false;
game_menu.tutor.gotoAndStop((game_menu.tutor.currentFrame + 1));
request_txt.visible = false;
MP = (Math.PI / 180);
removeEventListener(Event.ENTER_FRAME, on_enter_frame);
}
public function ADDPLANE2(){
}
public function ADDPLANE(){
var _local1:Plane;
addingPlane = true;
if (!Paused){
if (!ff){
addPlane_timer = (addPlane_timer - 1);
} else {
addPlane_timer = (addPlane_timer - 5);
};
if (addPlane_timer <= 0){
_local1 = new Plane();
_local1.selected_t = false;
if ((((((((CF == 20)) || ((CF == 22)))) || ((CF == 24)))) || ((CF == 26)))){
line = Math.round((Math.random() * 1));
} else {
if (CF == 28){
line = Math.round((Math.random() * 2));
};
};
_local1.line = line;
if (CF == 20){
addingPlane = false;
addPlane_timer = Math.round(((Math.random() * 1850) + 200));
_local1.x = -150;
_local1.y = 400;
} else {
if ((((CF == 22)) && ((_local1.line == 0)))){
addingPlane = false;
addPlane_timer = Math.round(((Math.random() * 1200) + 200));
random_Y = (Math.random() * 200);
_local1.x = 620;
_local1.y = random_Y;
} else {
if ((((CF == 22)) && ((_local1.line == 1)))){
addingPlane = false;
addPlane_timer = Math.round(((Math.random() * 1100) + 200));
_local1.x = 50;
_local1.y = -50;
} else {
if ((((CF == 24)) && ((_local1.line == 0)))){
addingPlane = false;
addPlane_timer = Math.round(((Math.random() * 800) + 200));
_local1.x = 290;
_local1.y = -200;
} else {
if ((((CF == 24)) && ((_local1.line == 1)))){
addingPlane = false;
addPlane_timer = Math.round(((Math.random() * 800) + 200));
_local1.x = -70;
_local1.y = 400;
} else {
if ((((CF == 26)) && ((_local1.line == 0)))){
addingPlane = false;
addPlane_timer = Math.round(((Math.random() * 1300) + 200));
_local1.x = 60;
_local1.y = -100;
} else {
if ((((CF == 26)) && ((_local1.line == 1)))){
addingPlane = false;
addPlane_timer = Math.round(((Math.random() * 1300) + 200));
_local1.x = 540;
_local1.y = -100;
} else {
if ((((CF == 28)) && ((_local1.line == 0)))){
addingPlane = false;
addPlane_timer = Math.round(((Math.random() * 1300) + 200));
_local1.x = 30;
_local1.y = -100;
} else {
if ((((CF == 28)) && ((_local1.line == 1)))){
addingPlane = false;
addPlane_timer = Math.round(((Math.random() * 800) + 200));
_local1.x = 100;
_local1.y = -100;
} else {
if ((((CF == 28)) && ((_local1.line == 2)))){
addingPlane = false;
addPlane_timer = Math.round(((Math.random() * 200) + 200));
_local1.x = 750;
_local1.y = 430;
};
};
};
};
};
};
};
};
};
};
planes_A.push(_local1);
addChild(_local1);
};
};
}
public function continue_func(_arg1:MouseEvent){
play_snd(2);
game_menu2.main_menu.gotoAndPlay(105);
}
public function win_play_func(_arg1:MouseEvent){
win.play();
}
function frame2(){
stop();
}
function frame4(){
gotoAndStop(10);
}
function frame1(){
stop();
gameName = "nameofthegame";
gameDura = 3000;
FOGlock = false;
debug = false;
urlToGame = (("http://www.freeonlinegames.com/?utm_source=" + gameName) + "&utm_medium=game");
stagewidth = stage.stageWidth;
stageheight = stage.stageHeight;
btnFoggy.width = stagewidth;
btnFoggy.height = stageheight;
pre1.percent = 0;
pre1.dura = gameDura;
btnFoggy.addEventListener(MouseEvent.CLICK, buttonClicked);
ctxMenu = new ContextMenu();
ctxMenu.hideBuiltInItems();
ctxCopyright = new ContextMenuItem("Copyright @ Free Online Games");
ctxCopyright.enabled = false;
ctxCopyright.separatorBefore = true;
ctxNotice = new ContextMenuItem("Play More Games!");
ctxNotice.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, function (_arg1:ContextMenuEvent):void{
navigateToURL(new URLRequest(urlToGame));
});
ctxMenu.customItems.push(ctxNotice, ctxCopyright);
contextMenu = ctxMenu;
stage.addEventListener(Event.ENTER_FRAME, showProgress);
}
function frame3(){
if (!okToPlay){
gotoAndStop(2);
btnFoggy.removeEventListener(MouseEvent.CLICK, buttonClicked);
};
}
public function play_more_func2(_arg1:MouseEvent){
trace("pressed");
var _local2:URLRequest = new URLRequest("http://www.freeonlinegames.com/?simairstraffic");
navigateToURL(_local2, "_blank");
}
public function level1func(_arg1:MouseEvent){
play_snd(2);
game_menu2.main_menu.levels.levels.level1.removeEventListener(MouseEvent.MOUSE_DOWN, level1func);
loop_snd(10);
loop_snd(8);
gotoAndPlay(20);
}
public function level3func(_arg1:MouseEvent){
play_snd(2);
if (game_menu2.main_menu.levels.levels.level3.currentFrame == 2){
gotoAndPlay(24);
loop_snd(10);
loop_snd(8);
game_menu2.main_menu.levels.levels.level3.removeEventListener(MouseEvent.MOUSE_DOWN, level3func);
};
}
function frame22(){
fail_timer = 150;
lastPos = 11;
flyAway_Pos = 7;
taxi_Pos = 3;
landingPos = 5;
take_off = 0;
arrivals = 0;
cash = 28000;
increaseTakeOffSps_Pos = 4;
addPlane_timer = 100;
random_Y = 0;
planes_A = new Array();
stop();
ff = false;
Paused = false;
selected_one = false;
Fail = false;
fail_timer_start = false;
bg_btn_press = false;
sound_ON = true;
next_lvl = false;
fail_listener_added = false;
win_listener_added = false;
game_menu.tutor.gotoAndStop((game_menu.tutor.currentFrame + 1));
request_txt.visible = false;
port.radar.rotation = (Math.random() * 360);
stage.addEventListener(MouseEvent.MOUSE_DOWN, close_choice);
game_menu.ff_btn.addEventListener(MouseEvent.MOUSE_DOWN, ff_function);
game_menu.p_btn.addEventListener(MouseEvent.MOUSE_DOWN, p_function);
game_menu.s_btn.addEventListener(MouseEvent.MOUSE_DOWN, s_func);
game_menu.choice.choice2.do_btns.goRound_btn.addEventListener(MouseEvent.MOUSE_DOWN, goRound);
game_menu.choice.choice2.do_btns.slowDown_btn.addEventListener(MouseEvent.MOUSE_DOWN, slowDown_func);
game_menu.choice.choice2.do_btns.speedUp_btn.addEventListener(MouseEvent.MOUSE_DOWN, speedUp_func);
game_menu.choice.choice2.do_btns.getReady_btn.addEventListener(MouseEvent.MOUSE_DOWN, getReady_func);
game_menu.choice.choice2.do_btns.taxi_btn.addEventListener(MouseEvent.MOUSE_DOWN, taxi_func);
game_menu.choice.choice2.addEventListener(MouseEvent.MOUSE_DOWN, useless_func);
game_menu.minilogo.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func2);
MP = (Math.PI / 180);
addEventListener(Event.ENTER_FRAME, on_enter_frame);
mySharedObject = SharedObject.getLocal("republicofcode");
if (mySharedObject.data.currentLevel < "2"){
mySharedObject.data.currentLevel = "2";
};
}
public function level5func(_arg1:MouseEvent){
play_snd(2);
if (game_menu2.main_menu.levels.levels.level5.currentFrame == 2){
gotoAndPlay(28);
loop_snd(10);
loop_snd(8);
game_menu2.main_menu.levels.levels.level5.removeEventListener(MouseEvent.MOUSE_DOWN, level5func);
};
}
public function ff_function(_arg1:MouseEvent){
if (!Paused){
if (!ff){
ff = true;
play_snd(3);
} else {
ff = false;
play_snd(4);
};
};
}
function frame10(){
snds_A = new Array(plane_land, plane_ready, plane_click, plane_ff, plane_ff2, plane_pause, plane_land2, plane_explode, airport, takeOff, airport_music, alarm);
stage.quality = "high";
gotoAndStop(15);
s = new SoundTransform();
s.volume = 1;
SoundMixer.soundTransform = s;
mySharedObject = SharedObject.getLocal("republicofcode");
if (!(mySharedObject.data.currentLevel) == "1"){
mySharedObject.data.currentLevel = "1";
};
trace(mySharedObject.data.currentLevel);
gotoAndStop(15);
}
public function go_round_loop(_arg1){
_arg1.plane_shadow.random_planes.selected_p.rotation = -(_arg1.rotation);
if ((((_arg1.selected_t == true)) && (_arg1.goRound))){
game_menu.choice.choice2.do_btns.gotoAndStop("planeGoingRound");
};
if ((((_arg1.selected_t == true)) && (!(_arg1.taxiing)))){
if (((!(_arg1.goRound)) && (!(_arg1.cantGoRound)))){
game_menu.choice.choice2.do_btns.gotoAndStop(2);
} else {
if ((((((_arg1.selected_t == true)) && (!(_arg1.goRound)))) && (_arg1.cantGoRound))){
game_menu.choice.choice2.do_btns.gotoAndStop("landing");
};
};
};
if ((((_arg1.selected_t == true)) && (_arg1.taxiing))){
game_menu.choice.choice2.do_btns.gotoAndStop("onlytakeoff");
} else {
if ((((_arg1.selected_t == true)) && (_arg1.refueling))){
game_menu.choice.choice2.do_btns.gotoAndStop("refueling");
} else {
if ((((_arg1.selected_t == true)) && (_arg1.canflyAway))){
game_menu.choice.choice2.do_btns.gotoAndStop("takingoff");
};
};
};
if ((((((_arg1.selected_t == true)) && (_arg1.needCross))) && ((_arg1.canCross == false)))){
game_menu.choice.choice2.do_btns.gotoAndStop("cross_frame");
};
if ((((_arg1.currentPos >= (_arg1.pos_A_1.length - 2))) && (_arg1.goRound))){
if (CF == 20){
_arg1.pos_A_1 = new Array([50, 370], [100, 300], [90, 180], [150, 100], [200, 110], [252, 170], [315, 0xFF], [370, 360], [310, 395], [250, 385], [220, 310], [0, 0], [10, 10]);
} else {
if (CF == 22){
_arg1.pos_A_1 = new Array([560, 220], [500, 300], [450, 375], [430, 430], [340, 450], [310, 350], [370, 300], [440, 210], [400, 200], [340, 200], [280, 265], [0, 0], [10, 10]);
} else {
if ((((CF == 24)) && ((_arg1.line == 0)))){
_arg1.pos_A_1 = new Array([310, 90], [310, 90], [310, 90], [310, 90], [310, 90], [320, 125], [345, 330], [385, 360], [450, 340], [425, 220], [410, 200], [0, 0], [10, 10]);
} else {
if ((((CF == 24)) && ((_arg1.line == 1)))){
_arg1.pos_A_1 = new Array([35, 380], [35, 380], [35, 380], [35, 380], [35, 380], [130, 360], [235, 342], [325, 330], [330, 360], [340, 420], [265, 415], [0, 0], [10, 10]);
} else {
if ((((CF == 26)) && ((_arg1.line == 0)))){
_arg1.pos_A_1 = new Array([35, 310], [80, 370], [135, 420], [200, 400], [0xFF, 365], [280, 300], [290, 200], [320, 175], [350, 150], [400, 205], [355, 235], [320, 315], [360, 345], [0, 0], [10, 10]);
} else {
if ((((CF == 26)) && ((_arg1.line == 1)))){
_arg1.pos_A_1 = new Array([570, 100], [570, 160], [540, 235], [460, 260], [425, 265], [345, 250], [345, 250], [240, 230], [160, 285], [210, 320], [250, 305], [350, 310], [360, 330], [0, 0], [10, 10]);
} else {
if ((((CF == 28)) && ((_arg1.line == 0)))){
_arg1.pos_A_1 = new Array([35, 45], [35, 100], [55, 150], [70, 190], [100, 220], [145, 240], [205, 250], [290, 265], [360, 280], [390, 265], [385, 245], [365, 225], [330, 225], [0, 0], [10, 10]);
} else {
if ((((CF == 28)) && ((_arg1.line == 1)))){
_arg1.pos_A_1 = new Array([240, 40], [240, 40], [260, 70], [275, 100], [280, 140], [280, 180], [0xFF, 225], [210, 300], [185, 355], [210, 370], [270, 360], [350, 347], [350, 350], [0, 0], [10, 10]);
} else {
if ((((CF == 28)) && ((_arg1.line == 2)))){
_arg1.pos_A_1 = new Array([570, 380], [570, 380], [570, 380], [570, 380], [570, 380], [500, 355], [430, 350], [395, 360], [260, 380], [230, 370], [270, 370], [350, 347], [350, 340], [0, 0], [10, 10]);
};
};
};
};
};
};
};
};
};
if ((((CF == 20)) || ((CF == 24)))){
_arg1.currentPos = 5;
} else {
if (CF == 22){
_arg1.currentPos = 3;
} else {
if (CF == 26){
_arg1.currentPos = 0;
} else {
_arg1.currentPos = 0;
};
};
};
_arg1.goRound = false;
};
}
function frame23(){
if (next_lvl == true){
play();
} else {
gotoAndStop((currentFrame - 1));
};
removeEventListener(Event.ENTER_FRAME, on_enter_frame);
}
function frame24(){
fail_timer = 150;
lastPos = 11;
flyAway_Pos = 7;
taxi_Pos = 3;
landingPos = 6;
take_off = 0;
arrivals = 0;
cash = 35000;
increaseTakeOffSps_Pos = 4;
addPlane_timer = 100;
random_Y = 0;
planes_A = new Array();
game_menu.choice.x = 185;
stop();
ff = false;
Paused = false;
selected_one = false;
Fail = false;
fail_timer_start = false;
bg_btn_press = false;
sound_ON = true;
next_lvl = false;
fail_listener_added = false;
win_listener_added = false;
game_menu.tutor.gotoAndStop((game_menu.tutor.currentFrame + 1));
request_txt.visible = false;
request_txt_2.visible = false;
port.radar.rotation = (Math.random() * 360);
stage.addEventListener(MouseEvent.MOUSE_DOWN, close_choice);
game_menu.ff_btn.addEventListener(MouseEvent.MOUSE_DOWN, ff_function);
game_menu.p_btn.addEventListener(MouseEvent.MOUSE_DOWN, p_function);
game_menu.s_btn.addEventListener(MouseEvent.MOUSE_DOWN, s_func);
game_menu.choice.choice2.do_btns.goRound_btn.addEventListener(MouseEvent.MOUSE_DOWN, goRound);
game_menu.choice.choice2.do_btns.slowDown_btn.addEventListener(MouseEvent.MOUSE_DOWN, slowDown_func);
game_menu.choice.choice2.do_btns.speedUp_btn.addEventListener(MouseEvent.MOUSE_DOWN, speedUp_func);
game_menu.choice.choice2.do_btns.getReady_btn.addEventListener(MouseEvent.MOUSE_DOWN, getReady_func);
game_menu.choice.choice2.do_btns.taxi_btn.addEventListener(MouseEvent.MOUSE_DOWN, taxi_func);
game_menu.choice.choice2.addEventListener(MouseEvent.MOUSE_DOWN, useless_func);
game_menu.minilogo.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func2);
MP = (Math.PI / 180);
addEventListener(Event.ENTER_FRAME, on_enter_frame);
mySharedObject = SharedObject.getLocal("republicofcode");
if (mySharedObject.data.currentLevel < "3"){
mySharedObject.data.currentLevel = "3";
};
}
function frame25(){
if (next_lvl == true){
play();
} else {
if (next_lvl == false){
gotoAndStop((currentFrame - 1));
};
};
removeEventListener(Event.ENTER_FRAME, on_enter_frame);
}
function frame20(){
fail_timer = 150;
lastPos = 11;
flyAway_Pos = 7;
taxi_Pos = 3;
landingPos = 6;
take_off = 0;
arrivals = 0;
cash = 20000;
increaseTakeOffSps_Pos = 4;
addPlane_timer = 100;
random_Y = 0;
line = 1;
CF = currentFrame;
addPlane2 = 200;
planes_A = new Array();
stop();
ff = false;
Paused = false;
selected_one = false;
Fail = false;
fail_timer_start = false;
bg_btn_press = false;
sound_ON = true;
addingPlane = false;
addingPlane2 = false;
next_lvl = false;
fail_listener_added = false;
win_listener_added = false;
game_menu.tutor.gotoAndStop((game_menu.tutor.currentFrame + 1));
request_txt.visible = false;
port.radar.rotation = (Math.random() * 360);
stage.addEventListener(MouseEvent.MOUSE_DOWN, close_choice);
game_menu.ff_btn.addEventListener(MouseEvent.MOUSE_DOWN, ff_function);
game_menu.p_btn.addEventListener(MouseEvent.MOUSE_DOWN, p_function);
game_menu.s_btn.addEventListener(MouseEvent.MOUSE_DOWN, s_func);
game_menu.choice.choice2.do_btns.goRound_btn.addEventListener(MouseEvent.MOUSE_DOWN, goRound);
game_menu.choice.choice2.do_btns.slowDown_btn.addEventListener(MouseEvent.MOUSE_DOWN, slowDown_func);
game_menu.choice.choice2.do_btns.speedUp_btn.addEventListener(MouseEvent.MOUSE_DOWN, speedUp_func);
game_menu.choice.choice2.do_btns.getReady_btn.addEventListener(MouseEvent.MOUSE_DOWN, getReady_func);
game_menu.choice.choice2.do_btns.taxi_btn.addEventListener(MouseEvent.MOUSE_DOWN, taxi_func);
game_menu.choice.choice2.addEventListener(MouseEvent.MOUSE_DOWN, useless_func);
game_menu.minilogo.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func2);
MP = (Math.PI / 180);
addEventListener(Event.ENTER_FRAME, on_enter_frame);
}
public function goRound(_arg1:MouseEvent){
var _local2:*;
i = 0;
while (i < planes_A.length) {
_local2 = planes_A[i];
if (_local2.selected_t == true){
_local2.decent = 1;
if (CF == 20){
_local2.pos_A_1 = new Array([400, 200], [480, 250], [550, 230], [560, 150], [520, 60], [430, 50], [320, 50], [280, 100], [0, 0]);
} else {
if (CF == 22){
_local2.pos_A_1 = new Array([240, 390], [220, 460], [280, 550], [420, 600], [600, 550], [650, 470], [550, 430], [430, 430], [0, 0]);
} else {
if (CF == 24){
_local2.pos_A_1 = new Array([230, 160], [230, 160], [200, 250], [70, 230], [30, 150], [50, 80], [140, 70], [200, 90], [0, 0]);
} else {
if ((((CF == 26)) && ((_local2.line == 0)))){
_local2.pos_A_1 = new Array([20, 350], [-60, 380], [-120, 230], [-120, 50], [-60, -60], [10, -80], [35, -20], [0, 0]);
} else {
if ((((CF == 26)) && ((_local2.line == 1)))){
_local2.pos_A_1 = new Array([570, 260], [570, 260], [650, 350], [650, 250], [700, 150], [700, -40], [570, -40], [0, 0]);
} else {
if ((((CF == 28)) && ((_local2.line == 0)))){
_local2.pos_A_1 = new Array([60, 290], [20, 380], [-70, 340], [-100, 250], [-100, 50], [-40, -40], [30, -50], [30, -50], [0, 0]);
} else {
if ((((CF == 28)) && ((_local2.line == 1)))){
_local2.pos_A_1 = new Array([390, 130], [470, 160], [560, 145], [650, 70], [650, -50], [300, -60], [300, -60], [300, -60], [0, 0]);
} else {
if ((((CF == 28)) && ((_local2.line == 2)))){
_local2.pos_A_1 = new Array([380, 420], [270, 520], [330, 580], [630, 580], [700, 470], [700, 470], [700, 470], [700, 470], [0, 0]);
};
};
};
};
};
};
};
};
_local2.currentPos = 0;
_local2.goRound = true;
};
i++;
};
}
function frame26(){
fail_timer = 150;
lastPos = 13;
flyAway_Pos = 7;
taxi_Pos = 3;
landingPos = 4;
take_off = 0;
arrivals = 0;
cash = 48000;
increaseTakeOffSps_Pos = 4;
addPlane_timer = 100;
random_Y = 0;
planes_A = new Array();
stop();
ff = false;
Paused = false;
selected_one = false;
Fail = false;
fail_timer_start = false;
bg_btn_press = false;
sound_ON = true;
next_lvl = false;
fail_listener_added = false;
win_listener_added = false;
game_menu.tutor.gotoAndStop((game_menu.tutor.currentFrame + 1));
request_txt.visible = false;
request_txt_2.visible = false;
port.radar.rotation = (Math.random() * 360);
stage.addEventListener(MouseEvent.MOUSE_DOWN, close_choice);
game_menu.ff_btn.addEventListener(MouseEvent.MOUSE_DOWN, ff_function);
game_menu.p_btn.addEventListener(MouseEvent.MOUSE_DOWN, p_function);
game_menu.s_btn.addEventListener(MouseEvent.MOUSE_DOWN, s_func);
game_menu.choice.choice2.do_btns.goRound_btn.addEventListener(MouseEvent.MOUSE_DOWN, goRound);
game_menu.choice.choice2.do_btns.slowDown_btn.addEventListener(MouseEvent.MOUSE_DOWN, slowDown_func);
game_menu.choice.choice2.do_btns.speedUp_btn.addEventListener(MouseEvent.MOUSE_DOWN, speedUp_func);
game_menu.choice.choice2.do_btns.getReady_btn.addEventListener(MouseEvent.MOUSE_DOWN, getReady_func);
game_menu.choice.choice2.do_btns.cross_btn.addEventListener(MouseEvent.MOUSE_DOWN, cross_func);
game_menu.choice.choice2.do_btns.taxi_btn.addEventListener(MouseEvent.MOUSE_DOWN, taxi_func);
game_menu.choice.choice2.addEventListener(MouseEvent.MOUSE_DOWN, useless_func);
game_menu.minilogo.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func2);
MP = (Math.PI / 180);
addEventListener(Event.ENTER_FRAME, on_enter_frame);
mySharedObject = SharedObject.getLocal("republicofcode");
if (mySharedObject.data.currentLevel < "4"){
mySharedObject.data.currentLevel = "4";
};
}
function frame30(){
Paused = true;
stop();
}
function frame27(){
if (next_lvl == true){
play();
} else {
if (next_lvl == false){
gotoAndStop((currentFrame - 1));
};
};
removeEventListener(Event.ENTER_FRAME, on_enter_frame);
}
public function buttonClicked(_arg1:MouseEvent):void{
navigateToURL(new URLRequest(urlToGame), "_blank");
}
function frame19(){
loop_snd(10);
loop_snd(8);
}
public function speedUp_func(_arg1:MouseEvent){
var _local2:*;
trace("spd");
i = 0;
while (i < planes_A.length) {
_local2 = planes_A[i];
if (_local2.selected_t == true){
_local2.spd = 0.9;
};
i++;
};
}
public function cross_func(_arg1:MouseEvent){
var _local2:*;
trace("CROSS FUNCTION!!!!!!!!!!!!!!!!!!!!!!!!!!");
i = 0;
while (i < planes_A.length) {
_local2 = planes_A[i];
if (_local2.selected_t == true){
_local2.canCross = true;
_local2.spd = 0.2;
};
i++;
};
}
public function more_games_func(_arg1:MouseEvent){
play_snd(2);
var _local2:URLRequest = new URLRequest("http://www.freegamesforyourwebsite.com/?simairstraffic");
navigateToURL(_local2, "_blank");
}
function frame29(){
if (next_lvl == true){
play();
} else {
if (next_lvl == false){
gotoAndStop((currentFrame - 1));
};
};
}
function frame21(){
if (next_lvl == true){
play();
} else {
if (next_lvl == false){
gotoAndStop((currentFrame - 1));
};
};
removeEventListener(Event.ENTER_FRAME, on_enter_frame);
}
public function FXS(){
if (game_menu.game_level.currentFrame == 150){
deleteAll();
next_lvl = true;
play();
};
if (game_menu.game_level.currentFrame == 205){
deleteAll();
next_lvl = false;
play();
};
if ((((((game_menu.game_level.currentFrame == 178)) && (!((game_menu.game_level.retry_btn === null))))) && (!(fail_listener_added)))){
trace("added");
game_menu.game_level.retry_btn.addEventListener(MouseEvent.MOUSE_DOWN, level_refresh);
game_menu.game_level.play_more_btn.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func2);
game_menu.game_level.more_games_btn.addEventListener(MouseEvent.MOUSE_DOWN, more_games_func2);
fail_listener_added = true;
};
if ((((((game_menu.game_level.currentFrame == 110)) && (!((game_menu.game_level.cont_btn === null))))) && ((!(win_listener_added) == true)))){
trace("added cont");
game_menu.game_level.cont_btn.addEventListener(MouseEvent.MOUSE_DOWN, level_refresh);
game_menu.game_level.play_more_btn.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func2);
game_menu.game_level.more_games_btn.addEventListener(MouseEvent.MOUSE_DOWN, more_games_func2);
win_listener_added = true;
};
if (CF == 20){
if (game_menu.tutor.currentFrame == 1){
game_menu.tutor.gotoAndStop((game_menu.tutor.currentFrame + 1));
};
} else {
game_menu.tutor.gotoAndStop(1);
};
if (game_menu.tutor.alpha < 1){
game_menu.tutor.alpha = (game_menu.tutor.alpha + 0.01);
};
if (getChildIndex(port) !== 1){
setChildIndex(port, 1);
};
if (getChildIndex(bg) !== 0){
setChildIndex(bg, 0);
};
if (!Paused){
game_menu.to_num.text = String(take_off);
game_menu.arrivals.text = String(arrivals);
if (CF == 20){
game_menu.cash_txt.text = (String(cash) + "/28000");
if ((((cash >= 28000)) && ((game_menu.game_level.currentFrame < 85)))){
game_menu.game_level.gotoAndPlay(85);
Paused = true;
};
} else {
if (CF == 22){
game_menu.cash_txt.text = (String(cash) + "/35000");
if ((((cash >= 35000)) && ((game_menu.game_level.currentFrame < 85)))){
game_menu.game_level.gotoAndPlay(85);
Paused = true;
};
} else {
if (CF == 24){
game_menu.cash_txt.text = (String(cash) + "/48000");
if ((((cash >= 48000)) && ((game_menu.game_level.currentFrame < 85)))){
game_menu.game_level.gotoAndPlay(85);
Paused = true;
};
} else {
if (CF == 26){
game_menu.cash_txt.text = (String(cash) + "/60000");
if ((((cash >= 60000)) && ((game_menu.game_level.currentFrame < 85)))){
game_menu.game_level.gotoAndPlay(85);
Paused = true;
};
} else {
if (CF == 28){
game_menu.cash_txt.text = (String(cash) + "/80000");
if ((((cash >= 80000)) && ((game_menu.game_level.currentFrame < 85)))){
game_menu.game_level.gotoAndPlay(85);
Paused = true;
};
};
};
};
};
};
if (getChildIndex(game_menu) !== (numChildren - 1)){
setChildIndex(game_menu, (numChildren - 1));
};
if (!ff){
port.radar.rotation = (port.radar.rotation + 2.5);
bg.clouds.x = (bg.clouds.x - 0.3);
} else {
port.radar.rotation = (port.radar.rotation + 12.5);
bg.clouds.x = (bg.clouds.x - 1.5);
};
if (bg.clouds.x <= -300){
bg.clouds.x = 300;
};
};
}
public function p_function(_arg1:MouseEvent){
if (!Fail){
if (((!(Paused)) && ((game_menu.pause_scrn.currentFrame == 1)))){
play_snd(5);
game_menu.pause_scrn.gotoAndPlay(2);
Paused = true;
} else {
if (((Paused) && ((game_menu.pause_scrn.currentFrame == 25)))){
play_snd(5);
game_menu.pause_scrn.gotoAndPlay(25);
Paused = false;
};
};
};
}
public function close_choice(_arg1:MouseEvent){
var _local2:*;
var _local3:Number;
var _local4:Number;
var _local5:Number;
if (!Paused){
if (CF == 20){
game_menu.tutor.gotoAndStop((game_menu.tutor.currentFrame + 1));
};
if (((!((game_menu.choice.currentFrame === 1))) && (!(bg_btn_press)))){
game_menu.choice.play();
bg_btn_press = false;
};
selected_one = false;
i = 0;
while (i < planes_A.length) {
_local2 = planes_A[i];
_local3 = (_local2.x - mouseX);
_local4 = (_local2.y - mouseY);
_local5 = Math.sqrt(((_local3 * _local3) + (_local4 * _local4)));
if ((((_local5 <= 25)) && (!(selected_one)))){
play_snd(2);
_local2.selected_t = true;
selected_one = true;
game_menu.choice.gotoAndPlay(2);
if (getChildIndex(_local2) !== (numChildren - 1)){
setChildIndex(_local2, (numChildren - 1));
};
} else {
if (!bg_btn_press){
_local2.selected_t = false;
};
};
i++;
};
bg_btn_press = false;
};
}
public function play_snd(_arg1){
var _local2:Sound = new (snds_A[_arg1]);
_local2.play();
}
public function play_func(_arg1:MouseEvent){
play_snd(2);
game_menu2.main_menu.gotoAndPlay(51);
}
public function level2func(_arg1:MouseEvent){
play_snd(2);
if (game_menu2.main_menu.levels.levels.level2.currentFrame == 2){
gotoAndPlay(22);
loop_snd(10);
loop_snd(8);
game_menu2.main_menu.levels.levels.level2.removeEventListener(MouseEvent.MOUSE_DOWN, level2func);
};
}
public function getReady_func(_arg1:MouseEvent){
var _local2:*;
i = 0;
while (i < planes_A.length) {
_local2 = planes_A[i];
if (_local2.selected_t == true){
_local2.taxiing = false;
_local2.taxiing_park = false;
_local2.refueling = false;
if (_local2.currentPos > taxi_Pos){
_local2.currentPos = 0;
};
};
i++;
};
}
public function level4func(_arg1:MouseEvent){
play_snd(2);
if (game_menu2.main_menu.levels.levels.level4.currentFrame == 2){
gotoAndPlay(26);
loop_snd(10);
loop_snd(8);
game_menu2.main_menu.levels.levels.level4.removeEventListener(MouseEvent.MOUSE_DOWN, level4func);
};
}
public function FOGFly(_arg1:Event):void{
var _local2:* = _arg1.currentTarget;
_local2.x = (_local2.x + (((_local2.targetX - _local2.x) / _local2.speed) * 0.5));
_local2.y = (_local2.y + (((_local2.targetY - _local2.y) / _local2.speed) * 0.5));
_local2.speed = (_local2.speed * 0.99);
_local2.scaleX = (_local2.scaleY = (_local2.scaleY + (_local2.grow * 2)));
if ((((_local2.alpha < 1)) && (!(_local2.fade)))){
_local2.alpha = (_local2.alpha + 0.02);
};
if ((((((((((_local2.x < -50)) || ((_local2.y < -50)))) || ((_local2.x > (stagewidth + 50))))) || ((_local2.y > (stageheight + 50))))) || ((_local2.scaleX > 2)))){
_local2.fade = true;
};
if (_local2.fade){
_local2.alpha = (_local2.alpha - 0.05);
if (_local2.alpha <= 0){
_local2.removeEventListener(Event.ENTER_FRAME, FOGFly);
_local2.parent.removeChild(_local2);
};
};
}
public function on_enter_frame(_arg1:Event){
var _local2:*;
var _local3:*;
var _local4:Number;
var _local5:Number;
if (game_menu.pause_scrn.currentFrame == 25){
game_menu.pause_scrn.resume_btn.addEventListener(MouseEvent.MOUSE_DOWN, pause_play);
game_menu.pause_scrn.play_more_btn.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func2);
game_menu.pause_scrn.more_games_btn.addEventListener(MouseEvent.MOUSE_DOWN, more_games_func2);
};
if (currentFrame == 30){
if (win.currentFrame == 25){
win.play_again_btn.addEventListener(MouseEvent.MOUSE_DOWN, win_play_func);
win.play_more_btn.addEventListener(MouseEvent.MOUSE_DOWN, play_more_func2);
win.more_games_btn.addEventListener(MouseEvent.MOUSE_DOWN, more_games_func2);
};
};
CF = currentFrame;
FXS();
ADDPLANE();
ADDPLANE2();
i = 0;
while (i < planes_A.length) {
_local2 = planes_A[i];
if (_local2.goingRound){
_local2.dist20 = 80;
} else {
_local2.dist20 = 20;
};
if ((((Paused == true)) && (!(Fail)))){
game_menu.tutor.visible = false;
if (_local2.alpha <= 0){
_local2.alpha = 0;
} else {
_local2.alpha = (_local2.alpha - 0.04);
};
} else {
game_menu.tutor.visible = true;
if (_local2.alpha >= 1){
_local2.alpha = 1;
} else {
_local2.alpha = (_local2.alpha + 0.04);
};
};
if (!Paused){
go_round_loop(_local2);
take_off_loop(_local2);
if (_local2.selected_t){
_local2.plane_shadow.random_planes.selected_p.visible = true;
} else {
_local2.plane_shadow.random_planes.selected_p.visible = false;
};
if (((((((_local2.HIT.hitTestObject(port)) && (!(_local2.goRound)))) && (!(_local2.ready_showed)))) && ((_local2.currentPos >= landingPos)))){
if (!ff){
_local2.decent = (_local2.decent + 1);
} else {
_local2.decent = (_local2.decent + 5);
};
if (_local2.decent <= 50){
_local2.cantGoRound = true;
if (!_local2.snd_o){
play_snd(0);
_local2.snd_o = true;
};
};
_local2.plane_shadow.gotoAndStop(_local2.decent);
};
if ((((_local2.currentPos == landingPos)) && (!(_local2.ready_showed)))){
if (!ff){
if (_local2.spd <= 0.5){
_local2.spd = 0.5;
} else {
_local2.spd = (_local2.spd - 0.008);
};
} else {
if (_local2.spd <= 0.5){
_local2.spd = 0.5;
} else {
_local2.spd = (_local2.spd - 0.04);
};
};
};
if ((((_local2.plane_shadow.currentFrame == 250)) && (!(_local2.refueling)))){
if (!_local2.snd_6){
arrivals = (arrivals + 1);
cash = (cash - 200);
play_snd(6);
_local2.snd_6 = true;
};
if (!ff){
if (_local2.spd <= 0.2){
_local2.spd = 0.2;
} else {
_local2.spd = (_local2.spd - 0.001);
};
} else {
if (_local2.spd <= 0.2){
_local2.spd = 0.2;
} else {
_local2.spd = (_local2.spd - 0.005);
};
};
};
if (((!(_local2.hitTestObject(bg))) && (_local2.goRound))){
_local2.spd = 0.9;
};
j = 0;
while (j < planes_A.length) {
_local3 = planes_A[j];
if (j !== i){
if (((((_local2.hitTestObject(_local3)) && ((_local2.decent == 1)))) && ((_local3.decent == 1)))){
alarm_snd_timer--;
if (alarm_snd_timer <= 0){
play_snd(11);
alarm_snd_timer = 35;
};
if (ff){
ff = false;
};
_local2.alarmC.play();
_local3.alarmC.play();
};
if (((((((_local2.HIT.hitTestObject(_local3.HIT2)) && ((_local2.decent >= 20)))) && ((_local3.decent >= 20)))) && ((_local2.currentFrame == 1)))){
_local2.planeInfront = true;
if (_local2.spd <= 0.2){
_local2.spd = 0;
} else {
if (((((_local2.HIT2.hitTestObject(_local3.HIT2)) && ((_local2.decent > 100)))) && ((_local3.decent > 100)))){
if (getChildIndex(explode) !== (numChildren - 1)){
setChildIndex(explode, (numChildren - 1));
};
explode.x = _local2.x;
explode.y = _local2.y;
if (getChildIndex(o_emo) !== (numChildren - 1)){
setChildIndex(o_emo, (numChildren - 1));
};
o_emo.x = _local2.x;
o_emo.y = _local2.y;
o_emo.gotoAndPlay(2);
explode.play();
play_snd(7);
_local2.spd = 0;
_local2.gotoAndStop(2);
_local3.gotoAndStop(2);
fail_timer_start = true;
};
};
};
if (((((((((_local2.HIT2.hitTestObject(_local3.HIT2)) && ((_local2.currentFrame == 1)))) && ((_local3.currentFrame == 1)))) && ((_local2.decent <= 230)))) && ((_local3.decent <= 230)))){
_local2.spd = 0;
_local3.spd = 0;
if (getChildIndex(explode) !== (numChildren - 1)){
setChildIndex(explode, (numChildren - 1));
};
explode.x = _local2.x;
explode.y = _local2.y;
if (getChildIndex(o_emo) !== (numChildren - 1)){
setChildIndex(o_emo, (numChildren - 1));
};
o_emo.x = _local2.x;
o_emo.y = _local2.y;
o_emo.gotoAndPlay(2);
explode.play();
play_snd(7);
_local2.spd = 0;
_local2.gotoAndStop(3);
if (getChildIndex(_local2) !== 1){
setChildIndex(_local2, 1);
};
if (getChildIndex(_local3) !== 1){
setChildIndex(_local3, 1);
};
_local3.gotoAndStop(3);
fail_timer_start = true;
_local2.decent = 248;
_local3.decent = 249;
};
};
j++;
};
if ((((((CF == 26)) && ((_local2.currentPos == 11)))) && (!(_local2.canCross)))){
_local2.spd = 0;
_local2.needCross = true;
} else {
if ((((((((((CF == 28)) && ((_local2.currentPos == 1)))) && (!(_local2.canCross)))) && (_local2.ready_showed))) && ((_local2.line == 0)))){
_local2.spd = 0;
_local2.needCross = true;
};
};
if (((((((!(_local2.disable)) && (!(_local2.taxiing_park)))) && ((_local2.currentFrame == 1)))) && ((!(addingPlane) == false)))){
if (!ff){
_local2.x = (_local2.x + (_local2.spd * Math.cos((_local2.rotation * MP))));
_local2.y = (_local2.y + (_local2.spd * Math.sin((_local2.rotation * MP))));
} else {
_local2.x = (_local2.x + ((_local2.spd * Math.cos((_local2.rotation * MP))) * 5));
_local2.y = (_local2.y + ((_local2.spd * Math.sin((_local2.rotation * MP))) * 5));
};
if ((((((((_local2.x <= (_local2.pos_A_1[_local2.currentPos][0] + _local2.dist20))) && ((_local2.x >= (_local2.pos_A_1[_local2.currentPos][0] - _local2.dist20))))) && ((_local2.y <= (_local2.pos_A_1[_local2.currentPos][1] + _local2.dist20))))) && ((_local2.y >= (_local2.pos_A_1[_local2.currentPos][1] - _local2.dist20))))){
if (_local2.currentPos !== _local2.pos_A_1.length){
_local2.currentPos++;
};
if (_local2.currentPos == (_local2.pos_A_1.length - 1)){
_local2.disable = true;
};
};
_local4 = f_rotation((_local2.pos_A_1[_local2.currentPos][0] - _local2.x), (_local2.pos_A_1[_local2.currentPos][1] - _local2.y));
_local5 = Math.abs((_local4 - _local2.rotation));
if (_local5 > 180){
if (_local4 > _local2.rotation){
_local4 = (_local4 - 360);
} else {
_local4 = (_local4 + 360);
};
};
if (!ff){
if (_local2.rotation < (_local4 - 1)){
_local2.rotation = (_local2.rotation + 1);
} else {
if (_local2.rotation > (_local4 + 1)){
_local2.rotation = (_local2.rotation - 1);
};
};
} else {
if (_local2.rotation < (_local4 - 5)){
_local2.rotation = (_local2.rotation + 5);
} else {
if (_local2.rotation > (_local4 + 5)){
_local2.rotation = (_local2.rotation - 5);
};
};
};
};
};
i++;
};
if (fail_timer_start){
fail_timer = (fail_timer - 1);
if (fail_timer <= 0){
Fail = true;
Paused = true;
if (game_menu.choice.currentFrame == 10){
game_menu.choice.play();
};
if (game_menu.game_level.currentFrame == 80){
game_menu.game_level.gotoAndPlay(155);
};
};
};
}
public function pause_play(_arg1:MouseEvent){
game_menu.pause_scrn.play();
Paused = false;
}
}
}//package SIMAirTraffic_fla
Section 22
//mcLogo_animation_7 (SIMAirTraffic_fla.mcLogo_animation_7)
package SIMAirTraffic_fla {
import flash.media.*;
import flash.display.*;
public dynamic class mcLogo_animation_7 extends MovieClip {
public var fogsound:fogaudio;
public var channel:SoundChannel;
public function mcLogo_animation_7(){
addFrameScript(59, frame60);
}
function frame60(){
stop();
fogsound = new fogaudio();
channel = fogsound.play();
}
}
}//package SIMAirTraffic_fla
Section 23
//mcLogo2_8 (SIMAirTraffic_fla.mcLogo2_8)
package SIMAirTraffic_fla {
import flash.events.*;
import flash.media.*;
import flash.display.*;
import flash.ui.*;
import flash.net.*;
import flash.text.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.filters.*;
import flash.geom.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.system.*;
import flash.utils.*;
import flash.xml.*;
public dynamic class mcLogo2_8 extends MovieClip {
public var me;
public var mcNotice:MovieClip;
public function mcLogo2_8(){
addFrameScript(0, frame1, 119, frame120);
}
function frame120(){
stop();
me = parent.parent;
if ((((me.Furl.indexOf("freeonlinegames.com") == -1)) && (me.FOGlock))){
if (me.debug){
me.okToPlay = true;
me.play();
stop();
} else {
mcNotice.visible = true;
};
} else {
me.okToPlay = true;
me.play();
stop();
};
}
function frame1(){
mcNotice.visible = false;
}
}
}//package SIMAirTraffic_fla
Section 24
//mcSounds_11 (SIMAirTraffic_fla.mcSounds_11)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class mcSounds_11 extends MovieClip {
public function mcSounds_11(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package SIMAirTraffic_fla
Section 25
//O_emo_51 (SIMAirTraffic_fla.O_emo_51)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class O_emo_51 extends MovieClip {
public function O_emo_51(){
addFrameScript(0, frame1, 128, frame129);
}
function frame129(){
stop();
}
function frame1(){
}
}
}//package SIMAirTraffic_fla
Section 26
//pause_62 (SIMAirTraffic_fla.pause_62)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class pause_62 extends MovieClip {
public var resume_btn:SimpleButton;
public var more_games_btn:SimpleButton;
public var play_more_btn:SimpleButton;
public function pause_62(){
addFrameScript(0, frame1, 24, frame25, 50, frame51);
}
function frame25(){
stop();
}
function frame1(){
stop();
}
function frame51(){
gotoAndStop(1);
}
}
}//package SIMAirTraffic_fla
Section 27
//plane_do_btns_68 (SIMAirTraffic_fla.plane_do_btns_68)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class plane_do_btns_68 extends MovieClip {
public var slowDown_btn:SimpleButton;
public var goRound_btn:SimpleButton;
public var getReady_btn:SimpleButton;
public var taxi_btn:SimpleButton;
public var cross_btn:SimpleButton;
public var speedUp_btn:SimpleButton;
public function plane_do_btns_68(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package SIMAirTraffic_fla
Section 28
//plane_shadow_13 (SIMAirTraffic_fla.plane_shadow_13)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class plane_shadow_13 extends MovieClip {
public var random_planes:MovieClip;
public function plane_shadow_13(){
addFrameScript(0, frame1, 249, frame250);
}
function frame250(){
stop();
}
function frame1(){
stop();
}
}
}//package SIMAirTraffic_fla
Section 29
//prelMCxcopy_ovidiu2_2 (SIMAirTraffic_fla.prelMCxcopy_ovidiu2_2)
package SIMAirTraffic_fla {
import flash.display.*;
import flash.text.*;
public dynamic class prelMCxcopy_ovidiu2_2 extends MovieClip {
public var procent:TextField;
public var preRedBar:SimpleButton;
public function prelMCxcopy_ovidiu2_2(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package SIMAirTraffic_fla
Section 30
//requesting_taxi_2_91 (SIMAirTraffic_fla.requesting_taxi_2_91)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class requesting_taxi_2_91 extends MovieClip {
public function requesting_taxi_2_91(){
addFrameScript(68, frame69);
}
function frame69(){
stop();
}
}
}//package SIMAirTraffic_fla
Section 31
//requesting_taxi_53 (SIMAirTraffic_fla.requesting_taxi_53)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class requesting_taxi_53 extends MovieClip {
public function requesting_taxi_53(){
addFrameScript(68, frame69);
}
function frame69(){
stop();
}
}
}//package SIMAirTraffic_fla
Section 32
//tutor_56 (SIMAirTraffic_fla.tutor_56)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class tutor_56 extends MovieClip {
public function tutor_56(){
addFrameScript(0, frame1, 1, frame2, 2, frame3, 3, frame4, 4, frame5, 5, frame6, 6, frame7, 7, frame8, 8, frame9, 9, frame10);
}
function frame10(){
stop();
}
function frame1(){
stop();
}
function frame2(){
this.alpha = 0;
}
function frame3(){
this.alpha = 0;
}
function frame4(){
this.alpha = 0;
}
function frame5(){
this.alpha = 0;
}
function frame6(){
this.alpha = 0;
}
function frame7(){
this.alpha = 0;
}
function frame8(){
this.alpha = 0;
}
function frame9(){
this.alpha = 0;
}
}
}//package SIMAirTraffic_fla
Section 33
//win_menu_101 (SIMAirTraffic_fla.win_menu_101)
package SIMAirTraffic_fla {
import flash.display.*;
public dynamic class win_menu_101 extends MovieClip {
public var play_again_btn:SimpleButton;
public var more_games_btn:SimpleButton;
public var play_more_btn:SimpleButton;
public function win_menu_101(){
addFrameScript(24, frame25, 50, frame51);
}
function frame25(){
stop();
}
function frame51(){
stop();
MovieClip(root).gotoAndStop(15);
}
}
}//package SIMAirTraffic_fla
Section 34
//airport (airport)
package {
import flash.media.*;
public dynamic class airport extends Sound {
}
}//package
Section 35
//airport_music (airport_music)
package {
import flash.media.*;
public dynamic class airport_music extends Sound {
}
}//package
Section 36
//alarm (alarm)
package {
import flash.media.*;
public dynamic class alarm extends Sound {
}
}//package
Section 37
//fog_1 (fog_1)
package {
import flash.display.*;
public dynamic class fog_1 extends MovieClip {
public function fog_1(){
addFrameScript(0, frame1);
}
function frame1(){
stop();
}
}
}//package
Section 38
//fogaudio (fogaudio)
package {
import flash.media.*;
public dynamic class fogaudio extends Sound {
}
}//package
Section 39
//Plane (Plane)
package {
import flash.events.*;
import flash.media.*;
import flash.display.*;
import flash.ui.*;
import flash.net.*;
import flash.text.*;
import adobe.utils.*;
import flash.accessibility.*;
import flash.errors.*;
import flash.external.*;
import flash.filters.*;
import flash.geom.*;
import flash.printing.*;
import flash.profiler.*;
import flash.sampler.*;
import flash.system.*;
import flash.utils.*;
import flash.xml.*;
public dynamic class Plane extends MovieClip {
public var goRound:Boolean;
public var taxiing:Boolean;
public var alarmC:MovieClip;
public var currentPos:Number;
public var HIT2:MovieClip;
public var spd:Number;
public var decent:Number;
public var canflyAway:Boolean;
public var taxiing_park:Boolean;
public var pos_A_1:Array;
public var cantGoRound:Boolean;
public var needCross:Boolean;
public var canCross:Boolean;
public var refueling:Boolean;
public var explode:MovieClip;
public var plane_shadow:MovieClip;
public var dist20:Number;
public var started_refuel:Boolean;
public var disable:Boolean;
public var can_get_ready_for_take_off:Boolean;
public var HIT:MovieClip;
public var line;
public var refuel_timer:Number;
public var ready_showed:Boolean;
public var randomizer:Number;
public function Plane(){
addFrameScript(0, frame1, 1, frame2, 2, frame3);
}
function frame2(){
plane_shadow.visible = false;
}
function frame1(){
stop();
alarmC.gotoAndStop(10);
if (MovieClip(root).currentFrame == 20){
pos_A_1 = new Array([50, 370], [100, 300], [90, 180], [150, 100], [200, 110], [252, 170], [315, 0xFF], [370, 360], [310, 395], [250, 385], [220, 310], [0, 0], [10, 10]);
} else {
if ((((MovieClip(root).currentFrame == 22)) && ((MovieClip(root).line == 0)))){
pos_A_1 = new Array([560, 220], [500, 300], [450, 375], [430, 430], [340, 450], [310, 350], [370, 300], [440, 210], [400, 200], [340, 200], [280, 265], [0, 0], [10, 10]);
} else {
if ((((MovieClip(root).currentFrame == 22)) && ((MovieClip(root).line == 1)))){
pos_A_1 = new Array([120, 90], [120, 150], [70, 210], [25, 320], [35, 350], [110, 360], [170, 315], [275, 190], [310, 210], [340, 200], [330, 240], [0, 0], [10, 10], [0, 0]);
} else {
if ((((MovieClip(root).currentFrame == 24)) && ((MovieClip(root).line == 0)))){
pos_A_1 = new Array([310, 90], [310, 90], [310, 90], [310, 90], [310, 90], [320, 125], [345, 330], [385, 360], [450, 340], [425, 220], [410, 200], [0, 0], [10, 10]);
} else {
if ((((MovieClip(root).currentFrame == 24)) && ((MovieClip(root).line == 1)))){
pos_A_1 = new Array([35, 380], [35, 380], [35, 380], [35, 380], [35, 380], [130, 360], [235, 342], [325, 330], [330, 360], [340, 420], [265, 415], [0, 0], [10, 10]);
} else {
if ((((MovieClip(root).currentFrame == 26)) && ((MovieClip(root).line == 0)))){
pos_A_1 = new Array([35, 305], [80, 370], [135, 420], [200, 400], [0xFF, 365], [280, 300], [290, 200], [320, 175], [350, 150], [400, 205], [355, 235], [320, 315], [360, 345], [0, 0], [10, 10]);
} else {
if ((((MovieClip(root).currentFrame == 26)) && ((MovieClip(root).line == 1)))){
pos_A_1 = new Array([570, 100], [570, 160], [540, 235], [460, 260], [425, 265], [345, 250], [345, 250], [240, 230], [165, 285], [220, 330], [250, 305], [350, 310], [360, 330], [0, 0], [10, 10]);
} else {
if ((((MovieClip(root).currentFrame == 28)) && ((MovieClip(root).line == 0)))){
pos_A_1 = new Array([35, 45], [35, 100], [55, 150], [70, 190], [100, 220], [145, 240], [205, 250], [290, 265], [360, 280], [390, 265], [385, 245], [365, 225], [330, 225], [0, 0], [10, 10]);
} else {
if ((((MovieClip(root).currentFrame == 28)) && ((MovieClip(root).line == 1)))){
pos_A_1 = new Array([240, 40], [240, 40], [260, 70], [275, 100], [280, 140], [280, 180], [0xFF, 225], [210, 300], [185, 355], [210, 370], [270, 360], [350, 347], [350, 350], [0, 0], [10, 10]);
} else {
if ((((MovieClip(root).currentFrame == 28)) && ((MovieClip(root).line == 2)))){
pos_A_1 = new Array([570, 380], [570, 380], [570, 380], [570, 380], [570, 380], [500, 390], [430, 350], [395, 360], [260, 380], [230, 370], [270, 370], [350, 347], [350, 340], [0, 0], [10, 10]);
};
};
};
};
};
};
};
};
};
};
goRound = false;
refueling = false;
disable = false;
ready_showed = false;
started_refuel = false;
cantGoRound = false;
can_get_ready_for_take_off = false;
canflyAway = false;
taxiing = false;
taxiing_park = false;
needCross = false;
canCross = false;
HIT.visible = false;
HIT2.visible = false;
plane_shadow.random_planes.selected_p.visible = false;
decent = 1;
spd = 0.9;
currentPos = 0;
randomizer = Math.round((Math.random() * 3));
plane_shadow.random_planes.gotoAndStop(randomizer);
refuel_timer = 400;
line = MovieClip(root).line;
dist20 = 20;
}
function frame3(){
plane_shadow.visible = false;
}
}
}//package
Section 40
//plane_click (plane_click)
package {
import flash.media.*;
public dynamic class plane_click extends Sound {
}
}//package
Section 41
//plane_explode (plane_explode)
package {
import flash.media.*;
public dynamic class plane_explode extends Sound {
}
}//package
Section 42
//plane_ff (plane_ff)
package {
import flash.media.*;
public dynamic class plane_ff extends Sound {
}
}//package
Section 43
//plane_ff2 (plane_ff2)
package {
import flash.media.*;
public dynamic class plane_ff2 extends Sound {
}
}//package
Section 44
//plane_land (plane_land)
package {
import flash.media.*;
public dynamic class plane_land extends Sound {
}
}//package
Section 45
//plane_land2 (plane_land2)
package {
import flash.media.*;
public dynamic class plane_land2 extends Sound {
}
}//package
Section 46
//plane_pause (plane_pause)
package {
import flash.media.*;
public dynamic class plane_pause extends Sound {
}
}//package
Section 47
//plane_ready (plane_ready)
package {
import flash.media.*;
public dynamic class plane_ready extends Sound {
}
}//package
Section 48
//takeOff (takeOff)
package {
import flash.media.*;
public dynamic class takeOff extends Sound {
}
}//package