//#include <simgear/misc/sgstream.hxx>
#include <simgear/misc/sg_path.hxx>
-//#ifndef FG_OLD_WEATHER
+//#ifndef FG_NEW_ENVIRONMENT
//sorry, that works only with the new weather system
#include <WeatherCM/FGLocalWeatherDatabase.h>
//#else
-//# include <Weather/weather.hxx>
+//# include <Environment/environment.hxx>
//#endif
#include <Main/fg_props.hxx>
string FGATIS::get_transmission() {
//void FGATIS::get_transmission() {
+#if !defined(FG_NEW_ENVIRONMENT)
string transmission = "";
double visibility;
sprintf(buf, "%i", int(stationweather.Temperature - 273.15));
transmission += " Temperature ";
transmission += buf;
- transmission += " degrees Celcius";
+ transmission += " degrees Celsius";
// Get the pressure / altimeter
// pressure is: stationweather.AirPressure in Pascal
double cloudbase = fgGetDouble("/environment/clouds/altitude-ft");
// For some reason the altitude returned doesn't seem to correspond to the actual cloud altitude.
char buf3[10];
- cout << "cloudbase = " << cloudbase << endl;
+ // cout << "cloudbase = " << cloudbase << endl;
sprintf(buf3, "%i", int(cloudbase));
transmission = transmission + " Cloudbase " + buf3 + " feet";
}
transmission += buf2;
}
- string rwy_no = runways.search(ident, hdg);
+ string rwy_no = runways.search(ident, int(hdg));
if(rwy_no != (string)"NN") {
transmission += " Landing and departing runway ";
transmission += rwy_no;
// }
return(transmission);
+#else
+ return "Station unavailable (not supported by FG_NEW_ENVIRONMENT)";
+#endif // FG_NEW_ENVIRONMENT
}