1
0
Fork 0

Allow control of whether 'b' key also cancels parking brake.

Uses new property /sim/controls/brake-cancels-parking-brake.

Default is true; it is expected that some aircraft (e.g. p51d) will set this to
false so they can implement their own brake/parking-brake interaction.

Should address bug 2589.
This commit is contained in:
Julian Smith 2021-05-26 10:18:40 +01:00
parent 9a9ece5054
commit 4b4410becf
2 changed files with 6 additions and 1 deletions

View file

@ -489,7 +489,9 @@ var fullBrakeTime = 0.5;
var applyBrakes = func(v, which = 0) {
if (which <= 0) { interpolate("/controls/gear/brake-left", v, fullBrakeTime); }
if (which >= 0) { interpolate("/controls/gear/brake-right", v, fullBrakeTime); }
setprop("/controls/gear/brake-parking", 0);
if (v and props.globals.getNode("/sim/controls/brake-cancels-parking-brake", 1).getBoolValue()) {
setprop("/controls/gear/brake-parking", 0);
}
}
var applyPickle = func(v) {
setprop("/controls/armament/pickle", v);

View file

@ -35,6 +35,9 @@ Started September 2000 by David Megginson, david@megginson.com
<presets preserve="y">
<trim type="bool">true</trim>
</presets>
<controls>
<brake-cancels-parking-brake>true</brake-cancels-parking-brake>
</controls>
<startup>
<xsize type="int" preserve="y" userarchive="y">1024</xsize>
<ysize type="int" preserve="y" userarchive="y">768</ysize>