diff --git a/Input/Joysticks/ThrustMaster/Warthog/Throttle/helicopter.xml b/Input/Joysticks/ThrustMaster/Warthog/Throttle/helicopter.xml
new file mode 100644
index 000000000..51cf49390
--- /dev/null
+++ b/Input/Joysticks/ThrustMaster/Warthog/Throttle/helicopter.xml
@@ -0,0 +1,13 @@
+
+
+
+
+ Hat Switch Horizontal
+ adjust engine balance
+
+
+
+ Hat Switch Vertical
+ adjust engine power
+
+
diff --git a/Input/Joysticks/ThrustMaster/Warthog-Stick.xml b/Input/Joysticks/ThrustMaster/Warthog/Warthog-Stick.xml
similarity index 85%
rename from Input/Joysticks/ThrustMaster/Warthog-Stick.xml
rename to Input/Joysticks/ThrustMaster/Warthog/Warthog-Stick.xml
index 4b47100ff..614cb4d44 100644
--- a/Input/Joysticks/ThrustMaster/Warthog-Stick.xml
+++ b/Input/Joysticks/ThrustMaster/Warthog/Warthog-Stick.xml
@@ -1,7 +1,12 @@
@@ -13,10 +18,12 @@
var this = cmdarg().getParent();
var popup = func gui.popupTip(call(sprintf, arg));
var is_helicopter = (var _ = props.globals.getNode("rotors", 0)) != nil and _.getAttribute("children");
+ var aircraft_type = getprop("/sim/type");
+ var overlay = getprop("/input/joysticks/overlay");
var load_overlay = func(name) {
foreach (var dir; [getprop("/sim/fg-home"), getprop("/sim/fg-root")]) {
- var file = dir ~ "/Input/Joysticks/ThrustMaster/Warthog/Joystick/" ~ name;
+ var file = dir ~ "/Input/Joysticks/ThrustMaster/Warthog/Joystick/" ~ name ~ ".xml";
if (io.stat(file) != nil) {
printlog("info", "WARTHOG: loading overlay " ~ file);
cmdarg().getNode("script").setValue("");
@@ -48,10 +55,14 @@
viewdir[i] = t != nil and t.getValue() == "lookat" ? 1 : -1;
}
- load_overlay("generic.xml");
+ load_overlay("generic");
if (is_helicopter)
- load_overlay("helicopter.xml");
- load_overlay(getprop("/sim/aircraft") ~ ".xml");
+ load_overlay("helicopter");
+ if (aircraft_type)
+ load_overlay(aircraft_type);
+ if (overlay)
+ load_overlay(overlay);
+ load_overlay(getprop("/sim/aircraft"));
@@ -77,7 +88,7 @@
- Trim Coolie Left/Right
+ Trim Hat Switch Left/Right
adjust aileron trim, +mod: reset aileron trim
true
@@ -106,7 +117,7 @@
- Trim Coolie Down/Up
+ Trim Hat Switch Down/Up
adjust elevator trim, +mod: reset elevator trim
true
@@ -136,17 +147,7 @@
- Coolie Switch Horizontal
+ Hat Switch Horizontal
adjust mixture: left = leaner, right = fatter
5
@@ -122,7 +129,7 @@
- Coolie Switch Vertical
+ Hat Switch Vertical
adjust propeller pitch: forward = increase, backward = decrease
6