diff --git a/src/FDM/JSBSim/models/propulsion/FGEngine.cpp b/src/FDM/JSBSim/models/propulsion/FGEngine.cpp index fd7290029..99c8df174 100644 --- a/src/FDM/JSBSim/models/propulsion/FGEngine.cpp +++ b/src/FDM/JSBSim/models/propulsion/FGEngine.cpp @@ -182,12 +182,13 @@ void FGEngine::ConsumeFuel(void) Starved = false; FuelToBurn = CalcFuelNeed(); + if (FuelToBurn == 0.0) return; while (FuelToBurn > 0.0) { // Count how many fuel tanks with the current priority level have fuel. // If none, then try next lower priority. Build the feed list. - while ((TanksWithFuel == 0.0) && (CurrentPriority <= Propulsion->GetNumTanks())) { + while ((TanksWithFuel == 0) && (CurrentPriority <= Propulsion->GetNumTanks())) { for (i=0; iGetNumTanks(); i++) { if (SourceTanks[i] != 0) { Tank = Propulsion->GetTank(i); @@ -217,13 +218,6 @@ void FGEngine::ConsumeFuel(void) Tank->Drain(FuelNeeded); FuelToBurn -= FuelNeeded; } - - // check if we were not able to burn all the fuel we needed to at this priority level - if (FuelToBurn > 0.0) { - CurrentPriority++; - TanksWithFuel = 0; - FeedList.clear(); - } } // while }