2011-09-09 14:23:35 +00:00
|
|
|
<?xml version="1.0"?>
|
|
|
|
<!--
|
|
|
|
Copyright (c) 2011 Melchior FRANZ mfranz # aon : at
|
2011-09-12 16:58:44 +00:00
|
|
|
|
|
|
|
This driver supports joystick overlay files (see ./Warthog/README).
|
2011-09-09 14:23:35 +00:00
|
|
|
-->
|
|
|
|
|
|
|
|
<PropertyList>
|
|
|
|
<name>Thrustmaster Throttle - HOTAS Warthog</name>
|
|
|
|
|
|
|
|
<nasal>
|
|
|
|
<script>
|
|
|
|
var this = cmdarg().getParent();
|
2011-09-22 16:10:51 +00:00
|
|
|
var init = !contains(caller(0)[0], "init");
|
2011-09-09 14:23:35 +00:00
|
|
|
var popup = func gui.popupTip(call(sprintf, arg));
|
2011-09-22 21:01:01 +00:00
|
|
|
var is_helicopter = (func {(var n = props.globals.getNode("rotors", 0)) != nil and n.getAttribute("children")})();
|
2011-09-12 16:58:44 +00:00
|
|
|
var aircraft_type = getprop("/sim/type");
|
|
|
|
var overlay = getprop("/input/joysticks/overlay");
|
warthog: add js overlay support
This allows to have generic axis/button definitions with aircraft
specific or aircraft class specific modification overlays. These
are also found in $FG_HOME, where they override global files. This
mechanism is desirable, because the Warthog is an A-10 replica, and
it should be possible to have an automatically loaded (1:1 mapped)
A-10 joystick config when flying the A-10, while using generic layouts
otherwise, or a specific helicopter overlay for helicopters etc.
Overlay files look exactly like joystick config files, except they
have no <name> and only specify actually differing elements. Axes
with <number> *need* a property index (e.g. <axis n="2">), which
usually corresponds to the <unix> value (i.e. n'th axis def in file).
Overlay files can contain a <nasal> block which is executed on
load. The files are to be named {$FG_ROOT,$FG_HOME}/Input/Joysticks/\
ThrustMaster/Warthog/{Joystick,Throttle}/{generic,helicopter,<aircraft>}\
.xml.
2011-09-09 22:03:11 +00:00
|
|
|
|
|
|
|
var load_overlay = func(name) {
|
2011-09-10 12:18:37 +00:00
|
|
|
foreach (var dir; [getprop("/sim/fg-home"), getprop("/sim/fg-root")]) {
|
2011-09-12 16:58:44 +00:00
|
|
|
var file = dir ~ "/Input/Joysticks/ThrustMaster/Warthog/Throttle/" ~ name ~ ".xml";
|
2011-09-10 12:18:37 +00:00
|
|
|
if (io.stat(file) != nil) {
|
|
|
|
printlog("info", "WARTHOG: loading overlay " ~ file);
|
2011-09-24 19:26:56 +00:00
|
|
|
cmdarg().setValues({command: "nasal", script: ""});
|
2011-09-10 12:18:37 +00:00
|
|
|
io.read_properties(file, this);
|
|
|
|
props.runBinding(cmdarg());
|
|
|
|
break;
|
|
|
|
}
|
warthog: add js overlay support
This allows to have generic axis/button definitions with aircraft
specific or aircraft class specific modification overlays. These
are also found in $FG_HOME, where they override global files. This
mechanism is desirable, because the Warthog is an A-10 replica, and
it should be possible to have an automatically loaded (1:1 mapped)
A-10 joystick config when flying the A-10, while using generic layouts
otherwise, or a specific helicopter overlay for helicopters etc.
Overlay files look exactly like joystick config files, except they
have no <name> and only specify actually differing elements. Axes
with <number> *need* a property index (e.g. <axis n="2">), which
usually corresponds to the <unix> value (i.e. n'th axis def in file).
Overlay files can contain a <nasal> block which is executed on
load. The files are to be named {$FG_ROOT,$FG_HOME}/Input/Joysticks/\
ThrustMaster/Warthog/{Joystick,Throttle}/{generic,helicopter,<aircraft>}\
.xml.
2011-09-09 22:03:11 +00:00
|
|
|
}
|
2011-09-09 14:23:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
foreach (var b; this.getChildren("button")) {
|
|
|
|
if (b.getAttribute("children") == 1) {
|
|
|
|
var name = b.getNode("name", 1).getValue() or "??";
|
|
|
|
b.setValues({binding: {command: "nasal", script: 'popup("' ~ name ~ '")'}});
|
|
|
|
}
|
|
|
|
}
|
warthog: add js overlay support
This allows to have generic axis/button definitions with aircraft
specific or aircraft class specific modification overlays. These
are also found in $FG_HOME, where they override global files. This
mechanism is desirable, because the Warthog is an A-10 replica, and
it should be possible to have an automatically loaded (1:1 mapped)
A-10 joystick config when flying the A-10, while using generic layouts
otherwise, or a specific helicopter overlay for helicopters etc.
Overlay files look exactly like joystick config files, except they
have no <name> and only specify actually differing elements. Axes
with <number> *need* a property index (e.g. <axis n="2">), which
usually corresponds to the <unix> value (i.e. n'th axis def in file).
Overlay files can contain a <nasal> block which is executed on
load. The files are to be named {$FG_ROOT,$FG_HOME}/Input/Joysticks/\
ThrustMaster/Warthog/{Joystick,Throttle}/{generic,helicopter,<aircraft>}\
.xml.
2011-09-09 22:03:11 +00:00
|
|
|
|
2011-09-10 12:18:37 +00:00
|
|
|
var mod = 0;
|
2011-09-22 16:10:51 +00:00
|
|
|
if (init) {
|
2011-09-24 19:26:56 +00:00
|
|
|
var m = props.globals.initNode("/devices/status/joysticks/warthog/modifier", mod, "INT");
|
|
|
|
setlistener(m, func(n) mod = n.getValue());
|
2011-09-22 16:10:51 +00:00
|
|
|
}
|
2011-09-10 12:18:37 +00:00
|
|
|
|
|
|
|
var left_engines = [0, 2, 4, 6, 8, 10];
|
|
|
|
var right_engines = [1, 3, 5, 7, 9, 11];
|
2011-09-11 06:52:04 +00:00
|
|
|
|
2011-09-12 16:58:44 +00:00
|
|
|
load_overlay("generic");
|
2011-09-11 06:52:04 +00:00
|
|
|
if (is_helicopter)
|
2011-09-12 16:58:44 +00:00
|
|
|
load_overlay("helicopter");
|
|
|
|
if (aircraft_type)
|
|
|
|
load_overlay(aircraft_type);
|
|
|
|
if (overlay)
|
|
|
|
load_overlay(overlay);
|
|
|
|
load_overlay(getprop("/sim/aircraft"));
|
2011-09-09 14:23:35 +00:00
|
|
|
</script>
|
|
|
|
</nasal>
|
|
|
|
|
|
|
|
<axis n="0">
|
|
|
|
<name>Mouse Horizontal</name>
|
|
|
|
</axis>
|
|
|
|
|
|
|
|
<axis n="1">
|
|
|
|
<name>Mouse Vertical</name>
|
|
|
|
</axis>
|
|
|
|
|
|
|
|
<axis n="2">
|
|
|
|
<name>Right Throttle</name>
|
2011-09-11 06:52:04 +00:00
|
|
|
<desc>right throttle</desc>
|
|
|
|
<tolerance>0.00001</tolerance>
|
2011-09-09 14:23:35 +00:00
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
2011-09-10 12:18:37 +00:00
|
|
|
<script>controls.perEngineSelectedAxisHandler(0)(right_engines)</script>
|
2011-09-09 14:23:35 +00:00
|
|
|
</binding>
|
|
|
|
</axis>
|
|
|
|
|
2011-09-10 12:18:37 +00:00
|
|
|
<axis n="3">
|
2011-09-09 14:23:35 +00:00
|
|
|
<name>Left Throttle</name>
|
2011-09-11 06:52:04 +00:00
|
|
|
<desc>left throttle</desc>
|
2011-09-09 14:23:35 +00:00
|
|
|
<number>
|
|
|
|
<unix>3</unix>
|
|
|
|
<mac>3</mac>
|
|
|
|
<windows>5</windows>
|
|
|
|
</number>
|
2011-09-11 06:52:04 +00:00
|
|
|
<tolerance>0.00001</tolerance>
|
2011-09-09 14:23:35 +00:00
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
2011-09-10 12:18:37 +00:00
|
|
|
<script>controls.perEngineSelectedAxisHandler(0)(left_engines)</script>
|
2011-09-09 14:23:35 +00:00
|
|
|
</binding>
|
|
|
|
</axis>
|
|
|
|
|
2011-09-10 12:18:37 +00:00
|
|
|
<axis n="4">
|
2011-09-09 14:23:35 +00:00
|
|
|
<name>Friction Wheel</name>
|
|
|
|
<desc>rudder trim</desc>
|
|
|
|
<number>
|
|
|
|
<unix>4</unix>
|
|
|
|
<mac>4</mac>
|
|
|
|
<windows>6</windows>
|
|
|
|
</number>
|
|
|
|
<binding>
|
|
|
|
<command>property-scale</command>
|
2011-09-10 12:18:37 +00:00
|
|
|
<property>/controls/flight/rudder-trim</property>
|
2011-09-09 14:23:35 +00:00
|
|
|
<factor type="double">-1</factor>
|
2011-09-11 17:26:40 +00:00
|
|
|
<power type="int">2</power>
|
2011-09-09 14:23:35 +00:00
|
|
|
</binding>
|
|
|
|
</axis>
|
|
|
|
|
2011-09-10 12:18:37 +00:00
|
|
|
<axis n="5">
|
2011-09-12 16:58:44 +00:00
|
|
|
<name>Hat Switch Horizontal</name>
|
2011-09-11 17:26:40 +00:00
|
|
|
<desc>adjust mixture: left = leaner, right = fatter</desc>
|
2011-09-09 14:23:35 +00:00
|
|
|
<number>
|
|
|
|
<unix>5</unix>
|
|
|
|
<mac>5</mac>
|
|
|
|
<windows>3</windows>
|
|
|
|
</number>
|
|
|
|
<low>
|
2011-09-11 17:26:40 +00:00
|
|
|
<repeatable>true</repeatable>
|
2011-09-09 14:23:35 +00:00
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
2011-09-11 17:26:40 +00:00
|
|
|
<script>controls.adjMixture(-1)</script>
|
2011-09-09 14:23:35 +00:00
|
|
|
</binding>
|
|
|
|
</low>
|
|
|
|
<high>
|
2011-09-11 17:26:40 +00:00
|
|
|
<repeatable>true</repeatable>
|
2011-09-09 14:23:35 +00:00
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
2011-09-11 17:26:40 +00:00
|
|
|
<script>controls.adjMixture(1)</script>
|
2011-09-09 14:23:35 +00:00
|
|
|
</binding>
|
|
|
|
</high>
|
|
|
|
</axis>
|
|
|
|
|
2011-09-10 12:18:37 +00:00
|
|
|
<axis n="6">
|
2011-09-12 16:58:44 +00:00
|
|
|
<name>Hat Switch Vertical</name>
|
2011-09-11 17:26:40 +00:00
|
|
|
<desc>adjust propeller pitch: forward = increase, backward = decrease</desc>
|
2011-09-09 14:23:35 +00:00
|
|
|
<number>
|
|
|
|
<unix>6</unix>
|
|
|
|
<mac>6</mac>
|
|
|
|
<windows>4</windows>
|
|
|
|
</number>
|
|
|
|
<low>
|
2011-09-11 17:26:40 +00:00
|
|
|
<repeatable>true</repeatable>
|
2011-09-09 14:23:35 +00:00
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
2011-09-11 17:26:40 +00:00
|
|
|
<script>controls.adjPropeller(1)</script>
|
2011-09-09 14:23:35 +00:00
|
|
|
</binding>
|
|
|
|
</low>
|
|
|
|
<high>
|
2011-09-11 17:26:40 +00:00
|
|
|
<repeatable>true</repeatable>
|
2011-09-09 14:23:35 +00:00
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
2011-09-11 17:26:40 +00:00
|
|
|
<script>controls.adjPropeller(-1)</script>
|
2011-09-09 14:23:35 +00:00
|
|
|
</binding>
|
|
|
|
</high>
|
|
|
|
</axis>
|
|
|
|
|
|
|
|
<button n="0">
|
|
|
|
<name>Mouse Button</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="1">
|
|
|
|
<name>MIC Switch Push</name>
|
|
|
|
<desc>Push To Talk (PTT)</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>controls.ptt(1)</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>controls.ptt(0)</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="2">
|
|
|
|
<name>MIC Switch Up</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="3">
|
|
|
|
<name>MIC Switch Forward</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="4">
|
|
|
|
<name>MIC Switch Down</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="5">
|
|
|
|
<name>MIC Switch Aft</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="6">
|
2011-09-24 19:26:56 +00:00
|
|
|
<name>Speedbrake Forward (right throttle, top grey)</name>
|
|
|
|
<desc>apply speed brake</desc>
|
|
|
|
<binding>
|
|
|
|
<command>property-assign</command>
|
|
|
|
<property>/controls/flight/speedbrake</property>
|
|
|
|
<value>1</value>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>property-assign</command>
|
|
|
|
<property>/controls/flight/speedbrake</property>
|
|
|
|
<value>0</value>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
2011-09-09 14:23:35 +00:00
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="7">
|
|
|
|
<name>Speedbrake Aft</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="8">
|
|
|
|
<name>Boat Switch Forward</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="9">
|
|
|
|
<name>Boat Switch Aft</name>
|
2011-09-24 19:26:56 +00:00
|
|
|
<desc>apply thrust reverser</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>props.setAll("/controls/engines/engine", "reverser", 1)</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>props.setAll("/controls/engines/engine", "reverser", 0)</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
2011-09-09 14:23:35 +00:00
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="10">
|
|
|
|
<name>China Hat Forward</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="11">
|
|
|
|
<name>China Hat Aft</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="12">
|
|
|
|
<name>Pinky Switch Forward</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="13">
|
|
|
|
<name>Pinky Switch Aft</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="14">
|
|
|
|
<name>Left Throttle Button</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="15">
|
|
|
|
<name>Engine Fuel Flow Left</name>
|
2011-09-10 12:18:37 +00:00
|
|
|
<desc>engine fuel flow left</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>
|
|
|
|
foreach (var i; left_engines)
|
|
|
|
setprop("/controls/engines/engine[" ~ i ~ "]/fuel-pump", 1);
|
|
|
|
</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>
|
|
|
|
foreach (var i; left_engines)
|
|
|
|
setprop("/controls/engines/engine[" ~ i ~ "]/fuel-pump", 0);
|
|
|
|
</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
2011-09-09 14:23:35 +00:00
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="16">
|
|
|
|
<name>Engine Fuel Flow Right</name>
|
2011-09-10 12:18:37 +00:00
|
|
|
<desc>engine fuel flow right</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>
|
|
|
|
foreach (var i; right_engines)
|
|
|
|
setprop("/controls/engines/engine[" ~ i ~ "]/fuel-pump", 1);
|
|
|
|
</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>
|
|
|
|
foreach (var i; right_engines)
|
|
|
|
setprop("/controls/engines/engine[" ~ i ~ "]/fuel-pump", 0);
|
|
|
|
</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
2011-09-09 14:23:35 +00:00
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="17">
|
|
|
|
<name>Engine Operate Left MOTOR</name>
|
2011-09-10 12:18:37 +00:00
|
|
|
<desc>engine operate left motor (magnetos)</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>
|
|
|
|
foreach (var i; left_engines)
|
|
|
|
setprop("/controls/engines/engine[" ~ i ~ "]/magnetos", 1);
|
|
|
|
</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>
|
|
|
|
foreach (var i; left_engines)
|
|
|
|
setprop("/controls/engines/engine[" ~ i ~ "]/magnetos", 0);
|
|
|
|
</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
2011-09-09 14:23:35 +00:00
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="18">
|
|
|
|
<name>Engine Operate Right MOTOR</name>
|
2011-09-10 12:18:37 +00:00
|
|
|
<desc>engine operate right motor (magnetos)</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>
|
|
|
|
foreach (var i; right_engines)
|
|
|
|
setprop("/controls/engines/engine[" ~ i ~ "]/magnetos", 1);
|
|
|
|
</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>
|
|
|
|
foreach (var i; right_engines)
|
|
|
|
setprop("/controls/engines/engine[" ~ i ~ "]/magnetos", 0);
|
|
|
|
</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
2011-09-09 14:23:35 +00:00
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="19">
|
|
|
|
<name>APU Start</name>
|
2011-09-10 12:18:37 +00:00
|
|
|
<desc>APU (auxiliary power unit) on/off</desc>
|
|
|
|
<binding>
|
|
|
|
<command>property-assign</command>
|
|
|
|
<property>/controls/electric/APU-generator</property>
|
|
|
|
<value>1</value>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>property-assign</command>
|
|
|
|
<property>/controls/electric/APU-generator</property>
|
|
|
|
<value>0</value>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
2011-09-09 14:23:35 +00:00
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="20">
|
2011-09-22 21:01:01 +00:00
|
|
|
<name>Landing Gear Horn Silence</name>
|
|
|
|
<desc>gear up, +mod: gear down</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>controls.gearDown(mod ? 1 : -1)</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>controls.gearDown(0)</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
2011-09-09 14:23:35 +00:00
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="21">
|
|
|
|
<name>Flaps Up</name>
|
|
|
|
<desc>flaps up</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>controls.flapsDown(-1)</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>controls.flapsDown(0)</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="22">
|
|
|
|
<name>Flaps Down</name>
|
|
|
|
<desc>flaps down</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>controls.flapsDown(1)</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>controls.flapsDown(0)</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="23">
|
|
|
|
<name>EAC Switch</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="24">
|
|
|
|
<name>RADAR ALT</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="25">
|
|
|
|
<name>Autopilot (Dis)Engage</name>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="26">
|
|
|
|
<name>Autopilot PATH</name>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>popup("autopilot path")</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>popup("autopilot alt/hdg")</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="27">
|
|
|
|
<name>Autopilot ALT</name>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>popup("autopilot alt")</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>popup("autopilot alt/hdg")</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="28">
|
|
|
|
<name>Right Throttle Idle Switch</name>
|
2011-09-11 17:26:40 +00:00
|
|
|
<desc>right engines cutoff</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>
|
|
|
|
foreach (var i; right_engines)
|
|
|
|
setprop("/controls/engines/engine[" ~ i ~ "]/cutoff", 1);
|
|
|
|
</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>
|
|
|
|
foreach (var i; right_engines)
|
|
|
|
setprop("/controls/engines/engine[" ~ i ~ "]/cutoff", 0);
|
|
|
|
</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
2011-09-09 14:23:35 +00:00
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="29">
|
|
|
|
<name>Left Throttle Idle Switch</name>
|
2011-09-11 17:26:40 +00:00
|
|
|
<desc>left engines cutoff</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>
|
|
|
|
foreach (var i; left_engines)
|
|
|
|
setprop("/controls/engines/engine[" ~ i ~ "]/cutoff", 1);
|
|
|
|
</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>
|
|
|
|
foreach (var i; left_engines)
|
|
|
|
setprop("/controls/engines/engine[" ~ i ~ "]/cutoff", 0);
|
|
|
|
</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
2011-09-09 14:23:35 +00:00
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="30">
|
|
|
|
<name>Engine Operate Left IGN</name>
|
2011-09-10 12:18:37 +00:00
|
|
|
<desc>start left engines</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>call(controls.startEngine, [1] ~ left_engines)</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>call(controls.startEngine, [0] ~ left_engines)</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
2011-09-09 14:23:35 +00:00
|
|
|
</button>
|
|
|
|
|
|
|
|
<button n="31">
|
|
|
|
<name>Engine Operate Right IGN</name>
|
2011-09-10 12:18:37 +00:00
|
|
|
<desc>start right engines</desc>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>call(controls.startEngine, [1] ~ right_engines)</script>
|
|
|
|
</binding>
|
|
|
|
<mod-up>
|
|
|
|
<binding>
|
|
|
|
<command>nasal</command>
|
|
|
|
<script>call(controls.startEngine, [0] ~ right_engines)</script>
|
|
|
|
</binding>
|
|
|
|
</mod-up>
|
2011-09-09 14:23:35 +00:00
|
|
|
</button>
|
|
|
|
</PropertyList>
|