Merge branch 'master' into ECAM2

This commit is contained in:
Joshua Davidson 2019-02-25 16:48:55 -05:00
commit b3a00a2241

View file

@ -235,25 +235,29 @@ var APPanel = {
} }
}, },
APDisc: func() { APDisc: func() {
if (ap1.getBoolValue() or ap2.getBoolValue()) { if (dcEss.getValue() >= 25) {
libraries.apOff("soft", 0); if (ap1.getBoolValue() or ap2.getBoolValue()) {
} else { libraries.apOff("soft", 0);
if (getprop("/it-autoflight/sound/apoffsound") == 1 or getprop("/it-autoflight/sound/apoffsound2") == 1) { } else {
setprop("/it-autoflight/sound/apoffsound", 0); if (getprop("/it-autoflight/sound/apoffsound") == 1 or getprop("/it-autoflight/sound/apoffsound2") == 1) {
setprop("/it-autoflight/sound/apoffsound2", 0); setprop("/it-autoflight/sound/apoffsound", 0);
setprop("/it-autoflight/sound/apoffsound2", 0);
}
setprop("/it-autoflight/output/ap-warning", 0);
setprop("/ECAM/warnings/master-warning-light", 0);
} }
setprop("/it-autoflight/output/ap-warning", 0);
setprop("/ECAM/warnings/master-warning-light", 0);
} }
}, },
ATDisc: func() { ATDisc: func() {
if (athr.getBoolValue()) { if (dcEss.getValue() >= 25) {
libraries.athrOff("soft"); if (athr.getBoolValue()) {
setprop("/ECAM/warnings/master-caution-light", 1); libraries.athrOff("soft");
} else { setprop("/ECAM/warnings/master-caution-light", 1);
if (getprop("/it-autoflight/output/athr-warning") == 1) { } else {
setprop("/it-autoflight/output/athr-warning", 0); if (getprop("/it-autoflight/output/athr-warning") == 1) {
setprop("/ECAM/warnings/master-caution-light", 0); setprop("/it-autoflight/output/athr-warning", 0);
setprop("/ECAM/warnings/master-caution-light", 0);
}
} }
} }
}, },
@ -343,18 +347,22 @@ var APPanel = {
} }
}, },
HDGPush: func() { HDGPush: func() {
if (fd1.getBoolValue() or fd2.getBoolValue() or ap1.getBoolValue() or ap2.getBoolValue()) { if (dcEss.getValue() >= 25) {
setprop("/it-autoflight/input/lat", 1); if (fd1.getBoolValue() or fd2.getBoolValue() or ap1.getBoolValue() or ap2.getBoolValue()) {
setprop("/it-autoflight/input/lat", 1);
}
} }
}, },
HDGPull: func() { HDGPull: func() {
if (fd1.getBoolValue() or fd2.getBoolValue() or ap1.getBoolValue() or ap2.getBoolValue()) { if (dcEss.getValue() >= 25) {
if (latMode.getValue() == 0 or !showHDG.getBoolValue()) { if (fd1.getBoolValue() or fd2.getBoolValue() or ap1.getBoolValue() or ap2.getBoolValue()) {
setprop("/it-autoflight/input/lat", 3); if (latMode.getValue() == 0 or !showHDG.getBoolValue()) {
showHDG.setBoolValue(1); setprop("/it-autoflight/input/lat", 3);
} else { showHDG.setBoolValue(1);
setprop("/it-autoflight/input/lat", 0); } else {
showHDG.setBoolValue(1); setprop("/it-autoflight/input/lat", 0);
showHDG.setBoolValue(1);
}
} }
} }
}, },