model_iterator = model_iterator->NextModel;
}
- frame = Frame++;
+ Frame++;
if (!Holding()) State->IncrTime();
return (success);
}
void Debug(int from) {};
- static unsigned int frame;
static unsigned int messageId;
static const double radtodeg;
T_dev_sl = T_dev = delta_T = 0.0;
StandardTempOnly = false;
+ first_pass = true;
bind();
Debug(0);
if (debug_lvl & 16) { // Sanity checking
}
if (debug_lvl & 128) { // Turbulence
- if (frame == 0 && from == 2) {
+ if (first_pass && from == 2) {
+ first_pass = false;
cout << "vTurbulence(X), vTurbulence(Y), vTurbulence(Z), "
<< "vTurbulenceGrad(X), vTurbulenceGrad(Y), vTurbulenceGrad(Z), "
<< "vDirection(X), vDirection(Y), vDirection(Z), "
<< "Magnitude, "
<< "vTurbPQR(P), vTurbPQR(Q), vTurbPQR(R), " << endl;
- } else if (from == 2) {
+ }
+ if (from == 2) {
cout << vTurbulence << ", " << vTurbulenceGrad << ", " << vDirection << ", " << Magnitude << ", " << vTurbPQR << endl;
}
}
double T_dev_sl, T_dev, delta_T, density_altitude;
atmType atmosphere;
bool StandardTempOnly;
+ bool first_pass;
double MagnitudedAccelDt, MagnitudeAccel, Magnitude;
double TurbGain;
FCS = Exec->GetFCS();
MassBalance = Exec->GetMassBalance();
- WOW = lastWOW = true; // should the value be initialized to true?
+ WOW = lastWOW = false;
ReportEnable = true;
FirstContact = false;
StartedGroundRun = false;
if (debug_lvl & 16) { // Sanity checking
}
if (debug_lvl & 32) { // Turbulence
- if (frame == 0 && from == 2) {
+ if (first_pass && from == 2) {
cout << "vTurbulence(X), vTurbulence(Y), vTurbulence(Z), "
<< "vTurbulenceGrad(X), vTurbulenceGrad(Y), vTurbulenceGrad(Z), "
<< "vDirection(X), vDirection(Y), vDirection(Z), "
<< "Magnitude, "
<< "vTurbPQR(P), vTurbPQR(Q), vTurbPQR(R), " << endl;
- } else if (from == 2) {
+ }
+ if (from == 2) {
cout << vTurbulence << ", " << vTurbulenceGrad << ", " << vDirection << ", " << Magnitude << ", " << vTurbPQR << endl;
}
}
if (debug_lvl & 16) { // Sanity checking
}
if (debug_lvl & 32) { // Turbulence
- if (frame == 0 && from == 2) {
+ if (first_pass && from == 2) {
cout << "vTurbulence(X), vTurbulence(Y), vTurbulence(Z), "
<< "vTurbulenceGrad(X), vTurbulenceGrad(Y), vTurbulenceGrad(Z), "
<< "vDirection(X), vDirection(Y), vDirection(Z), "