diff --git a/src/AIModel/AIAircraft.cxx b/src/AIModel/AIAircraft.cxx index 853cd90b3..d5e5f68ed 100644 --- a/src/AIModel/AIAircraft.cxx +++ b/src/AIModel/AIAircraft.cxx @@ -105,7 +105,7 @@ void FGAIAircraft::readFromScenario(SGPropertyNode* scFileNode) { bool FGAIAircraft::init() { - refuel_node = fgGetNode("systems/refuel/contact", true); + //refuel_node = fgGetNode("systems/refuel/contact", true); return FGAIBase::init(); } @@ -412,7 +412,7 @@ void FGAIAircraft::Run(double dt) { } // match pitch angle to vertical speed - if (vs > 0){ + if (vs > 0) { pitch = vs * 0.005; } else { pitch = vs * 0.002; @@ -433,7 +433,7 @@ void FGAIAircraft::Run(double dt) { refuel_node->setBoolValue(true); contact = true; } else { - refuel_node->setBoolValue(false); + //refuel_node->setBoolValue(false); contact = false; } } else { @@ -777,7 +777,7 @@ void FGAIAircraft::ProcessFlightPlan( double dt, time_t now ) { << "pos : " << pos.lat() << ", " << pos.lon() << "waypoint " << curr->latitude << ", " << curr->longitude << endl; cerr << "waypoint name " << curr->name; - exit(1); // FIXME + exit(1); // FIXME } double speed_diff = speed - prevSpeed; diff --git a/src/AIModel/AIMultiplayer.cxx b/src/AIModel/AIMultiplayer.cxx index 9502561bf..89d90b593 100755 --- a/src/AIModel/AIMultiplayer.cxx +++ b/src/AIModel/AIMultiplayer.cxx @@ -44,7 +44,7 @@ FGAIMultiplayer::~FGAIMultiplayer() { } bool FGAIMultiplayer::init() { - refuel_node = fgGetNode("systems/refuel/contact", true); + //refuel_node = fgGetNode("systems/refuel/contact", true); isTanker = false; // do this until this property is // passed over the net @@ -52,7 +52,7 @@ bool FGAIMultiplayer::init() { string str2 = "MOBIL"; unsigned int loc1= str1.find( str2, 0 ); - if ( (loc1 != string::npos && str2 != "") /*|| mCallSign == "mpdummy" */) { + if ( (loc1 != string::npos && str2 != "") ){ // cout << " string found " << str2 << " in " << str1 << endl; isTanker = true; // cout << "isTanker " << isTanker << " " << mCallSign < 0.0) && (elevation > 0.0)*/ ) { - refuel_node->setBoolValue(true); + if ( (range_ft2 < 250.0 * 250.0) && + (y_shift > 0.0) && + (elevation > 0.0) ){ + // refuel_node->setBoolValue(true); contact = true; } else { - refuel_node->setBoolValue(false); + // refuel_node->setBoolValue(false); contact = false; } } else {