1
0
Fork 0

Correct minimum/hundred-above callout

This commit is contained in:
Matthew Maring 2020-04-20 15:01:55 -04:00 committed by Jonathan Redpath
parent 1a88d8f590
commit 8cf48657c7
5 changed files with 13 additions and 13 deletions

View file

@ -2613,7 +2613,7 @@ var canvas_MCDU_base = {
} }
me["Simple_R2S"].setText("BARO"); me["Simple_R2S"].setText("BARO");
if (getprop("FMGC/internal/baro") != -1) { if (getprop("FMGC/internal/baro") != 99999) {
me["Simple_R2"].setText(sprintf("%.0f", getprop("FMGC/internal/baro"))); me["Simple_R2"].setText(sprintf("%.0f", getprop("FMGC/internal/baro")));
me.fontRight(0, default, 0, 0, 0, 0); me.fontRight(0, default, 0, 0, 0, 0);
me.fontSizeRight(0, normal, 0, 0, 0, 0); me.fontSizeRight(0, normal, 0, 0, 0, 0);
@ -2624,7 +2624,7 @@ var canvas_MCDU_base = {
} }
me["Simple_R3S"].setText("RADIO"); me["Simple_R3S"].setText("RADIO");
if (getprop("FMGC/internal/radio") != -1) { if (getprop("FMGC/internal/radio") != 99999) {
me["Simple_R3"].setText(sprintf("%.0f", getprop("FMGC/internal/radio"))); me["Simple_R3"].setText(sprintf("%.0f", getprop("FMGC/internal/radio")));
me.fontRight(0, 0, default, 0, 0, 0); me.fontRight(0, 0, default, 0, 0, 0);
me.fontSizeRight(0, 0, normal, 0, 0, 0); me.fontSizeRight(0, 0, normal, 0, 0, 0);

View file

@ -172,8 +172,8 @@ var altFlash2 = props.globals.initNode("/instrumentation/pfd/flash-indicators/al
var amberFlash1 = props.globals.initNode("/instrumentation/pfd/flash-indicators/amber-flash-1", 0, "BOOL"); var amberFlash1 = props.globals.initNode("/instrumentation/pfd/flash-indicators/amber-flash-1", 0, "BOOL");
var amberFlash2 = props.globals.initNode("/instrumentation/pfd/flash-indicators/amber-flash-2", 0, "BOOL"); var amberFlash2 = props.globals.initNode("/instrumentation/pfd/flash-indicators/amber-flash-2", 0, "BOOL");
var dhFlash = props.globals.initNode("/instrumentation/pfd/flash-indicators/dh-flash", 0, "BOOL"); var dhFlash = props.globals.initNode("/instrumentation/pfd/flash-indicators/dh-flash", 0, "BOOL");
var hundredAbove = props.globals.initNode("/instrumentation/pfd/hundred-above", 100, "BOOL"); var hundredAbove = props.globals.initNode("/instrumentation/pfd/hundred-above", 99999, "INT");
var minimum = props.globals.initNode("/instrumentation/pfd/minimum", 0, "BOOL"); var minimum = props.globals.initNode("/instrumentation/pfd/minimum", 99999, "INT");
var canvas_PFD_base = { var canvas_PFD_base = {
init: func(canvas_group, file) { init: func(canvas_group, file) {

View file

@ -465,8 +465,8 @@ var arrivalPage = {
me.makeTmpy(); me.makeTmpy();
fmgc.flightPlanController.flightplans[me.computer].destination_runway = me.arrAirport[0].runways[me.selectedApproach.runways[0]]; fmgc.flightPlanController.flightplans[me.computer].destination_runway = me.arrAirport[0].runways[me.selectedApproach.runways[0]];
fmgc.flightPlanController.flightplans[me.computer].approach = me.selectedApproach; fmgc.flightPlanController.flightplans[me.computer].approach = me.selectedApproach;
setprop("FMGC/internal/baro", -1); setprop("FMGC/internal/baro", 99999);
setprop("FMGC/internal/radio", -1); setprop("FMGC/internal/radio", 99999);
setprop("FMGC/internal/radio-no", 0); setprop("FMGC/internal/radio-no", 0);
me.updateActiveApproach(); me.updateActiveApproach();
me.updateApproaches(); me.updateApproaches();

View file

@ -160,8 +160,8 @@ var MCDU_reset = func(i) {
setprop("FMGC/internal/dest-wind", -1); setprop("FMGC/internal/dest-wind", -1);
setprop("FMGC/internal/vapp-speed-set", 0); setprop("FMGC/internal/vapp-speed-set", 0);
setprop("FMGC/internal/final", ""); setprop("FMGC/internal/final", "");
setprop("FMGC/internal/baro", -1); setprop("FMGC/internal/baro", 99999);
setprop("FMGC/internal/radio", -1); setprop("FMGC/internal/radio", 99999);
setprop("FMGC/internal/radio-no", 0); setprop("FMGC/internal/radio-no", 0);
setprop("FMGC/internal/ldg-elev", 0); setprop("FMGC/internal/ldg-elev", 0);
setprop("FMGC/internal/ldg-config-3-set", 0); setprop("FMGC/internal/ldg-config-3-set", 0);

View file

@ -84,12 +84,12 @@ var perfAPPRInput = func(key, i) {
setprop("MCDU[" ~ i ~ "]/page", "PERFDES"); setprop("MCDU[" ~ i ~ "]/page", "PERFDES");
} else if (key == "R2") { } else if (key == "R2") {
if (scratchpad == "CLR") { if (scratchpad == "CLR") {
setprop("FMGC/internal/baro", -1); setprop("FMGC/internal/baro", 99999);
setprop("MCDU[" ~ i ~ "]/scratchpad-msg", 0); setprop("MCDU[" ~ i ~ "]/scratchpad-msg", 0);
setprop("MCDU[" ~ i ~ "]/scratchpad", ""); setprop("MCDU[" ~ i ~ "]/scratchpad", "");
} else if (int(scratchpad) != nil and scratchpad >= getprop("FMGC/internal/ldg-elev") and scratchpad <= 5000 + getprop("FMGC/internal/ldg-elev")) { } else if (int(scratchpad) != nil and scratchpad >= getprop("FMGC/internal/ldg-elev") and scratchpad <= 5000 + getprop("FMGC/internal/ldg-elev")) {
if (getprop("FMGC/internal/radio-no") == 0) { if (getprop("FMGC/internal/radio-no") == 0) {
setprop("FMGC/internal/radio", -1); setprop("FMGC/internal/radio", 99999);
} }
setprop("FMGC/internal/baro", scratchpad); setprop("FMGC/internal/baro", scratchpad);
setprop("MCDU[" ~ i ~ "]/scratchpad", ""); setprop("MCDU[" ~ i ~ "]/scratchpad", "");
@ -98,16 +98,16 @@ var perfAPPRInput = func(key, i) {
} }
} else if (key == "R3") { } else if (key == "R3") {
if (scratchpad == "CLR") { if (scratchpad == "CLR") {
setprop("FMGC/internal/radio", -1); setprop("FMGC/internal/radio", 99999);
setprop("FMGC/internal/radio-no", 0); setprop("FMGC/internal/radio-no", 0);
setprop("MCDU[" ~ i ~ "]/scratchpad-msg", 0); setprop("MCDU[" ~ i ~ "]/scratchpad-msg", 0);
setprop("MCDU[" ~ i ~ "]/scratchpad", ""); setprop("MCDU[" ~ i ~ "]/scratchpad", "");
} else if (scratchpad == "NO") { } else if (scratchpad == "NO") {
setprop("FMGC/internal/radio", -1); setprop("FMGC/internal/radio", 99999);
setprop("FMGC/internal/radio-no", 1); setprop("FMGC/internal/radio-no", 1);
setprop("MCDU[" ~ i ~ "]/scratchpad", ""); setprop("MCDU[" ~ i ~ "]/scratchpad", "");
} else if (int(scratchpad) != nil and scratchpad >= 0 and scratchpad <= 700) { } else if (int(scratchpad) != nil and scratchpad >= 0 and scratchpad <= 700) {
setprop("FMGC/internal/baro", -1); setprop("FMGC/internal/baro", 99999);
setprop("FMGC/internal/radio-no", 0); setprop("FMGC/internal/radio-no", 0);
setprop("FMGC/internal/radio", scratchpad); setprop("FMGC/internal/radio", scratchpad);
setprop("MCDU[" ~ i ~ "]/scratchpad", ""); setprop("MCDU[" ~ i ~ "]/scratchpad", "");