Prevent excess garbage collection in FGMC.nas; correction for bug in PTS
This commit is contained in:
parent
8d55eda2d4
commit
98378f45ea
2 changed files with 8 additions and 4 deletions
|
@ -62,6 +62,7 @@ var altsel = 0;
|
|||
var crzFl = 0;
|
||||
var windHdg = 0;
|
||||
var windSpeed = 0;
|
||||
var windsDidChange = 0;
|
||||
setprop("position/gear-agl-ft", 0);
|
||||
setprop("/it-autoflight/settings/accel-agl-ft", 1500); #eventually set to 1500 above runway
|
||||
setprop("/it-autoflight/internal/vert-speed-fpm", 0);
|
||||
|
@ -683,7 +684,7 @@ var masterFMGC = maketimer(0.2, func {
|
|||
windHdg = pts.Environment.windFromHdg.getValue();
|
||||
windSpeed = pts.Environment.windSpeedKt.getValue();
|
||||
if (FMGCInternal.phase == 3 or FMGCInternal.phase == 4 or FMGCInternal.phase == 6) {
|
||||
var windsDidChange = 0;
|
||||
windsDidChange = 0;
|
||||
if (FMGCInternal.crzFt > 5000 and alt > 4980 and alt < 5020) {
|
||||
if (sprintf("%03d", windHdg) != fmgc.windController.fl50_wind[0] or sprintf("%03d", windSpeed) != fmgc.windController.fl50_wind[1]) {
|
||||
fmgc.windController.fl50_wind[0] = sprintf("%03d", windHdg);
|
||||
|
@ -1020,9 +1021,7 @@ var ManagedSPD = maketimer(0.25, func {
|
|||
|
||||
if (mach > mng_alt_mach and (FMGCInternal.phase == 2 or FMGCInternal.phase == 3)) {
|
||||
FMGCInternal.machSwitchover = 1;
|
||||
}
|
||||
|
||||
if (ias > mng_alt_spd and (FMGCInternal.phase == 4 or FMGCInternal.phase == 5)) {
|
||||
} elsif (ias > mng_alt_spd and (FMGCInternal.phase == 4 or FMGCInternal.phase == 5)) {
|
||||
FMGCInternal.machSwitchover = 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -248,6 +248,11 @@ var Sim = {
|
|||
},
|
||||
},
|
||||
Version: props.globals.getNode("/sim/version/flightgear"),
|
||||
View: {
|
||||
Config: {
|
||||
defaultFieldOfViewDeg: props.globals.getNode("/sim/view/config/default-field-of-view-deg", 1),
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
var Systems = {
|
||||
|
|
Loading…
Reference in a new issue