]> git.mxchange.org Git - flightgear.git/blobdiff - src/ATCDCL/transmissionlist.cxx
Merge branch 'jt/runway' into next
[flightgear.git] / src / ATCDCL / transmissionlist.cxx
index cb24e50ca7aee8fba8e5d1b75e2933e81c577749..f9e4fe373b09b4c80ca8df8f68689285c91c2085 100644 (file)
@@ -70,20 +70,6 @@ bool FGTransmissionList::init( const SGPath& path ) {
     // in >> skipeol;
     // in >> skipcomment;
 
-#ifdef __MWERKS__
-
-    char c = 0;
-    while ( in.get(c) && c != '\0' ) {
-        in.putback(c);
-        in >> a;
-       if ( a.get_type() != '[' ) {
-           transmissionlist_code[a.get_station()].push_back(a);
-       }
-        in >> skipcomment;
-    }
-
-#else
-
     double min = 100000;
     double max = 0;
 
@@ -107,8 +93,6 @@ bool FGTransmissionList::init( const SGPath& path ) {
         */
     }
  
-#endif
-
     // init ATC menu
     fgSetBool("/sim/atc/menu",false);
 
@@ -130,13 +114,13 @@ bool FGTransmissionList::query_station( const atc_type &station, FGTransmission
       num_trans += 1;
     }
     else {
-      cout << "Transmissionlist error: Too many transmissions" << endl
+      SG_LOG(SG_GENERAL, SG_WARN, "Transmissionlist error: Too many transmissions")
     }
   }
 
   if ( num_trans != 0 ) return true;
   else {
-    cout << "No transmission with station " << station << "found." << endl;
+    SG_LOG(SG_GENERAL, SG_WARN, "No transmission with station " << station << "found.");
     string empty;
     return false;
   }
@@ -240,7 +224,7 @@ string FGTransmissionList::gen_text(const atc_type &station, const TransCode cod
                                else if ( strcmp ( tag, "@RW" ) == 0 )
                                        strcat( &dum[0], tpars.runway.c_str() );
                                else {
-                                       cout << "Tag " << tag << " not found" << endl;
+                                       SG_LOG(SG_GENERAL, SG_WARN, "Tag " << tag << " not found");
                                        break;
                                }
                                strcat( &dum[0], &mes[len+3] );
@@ -248,7 +232,7 @@ string FGTransmissionList::gen_text(const atc_type &station, const TransCode cod
                                
                                ++check;
                                if(check > 10) {
-                                       SG_LOG(SG_ATC, SG_WARN, "WARNING: Possibly endless loop terminated in FGTransmissionlist::gen_text(...)"); 
+                                       SG_LOG(SG_GENERAL, SG_WARN, "WARNING: Possibly endless loop terminated in FGTransmissionlist::gen_text(...)"); 
                                        break;
                                }
                        }