1
0
Fork 0

Modified Files:

ThrustMaster/HOTAS-Cougar.xml: Updates from Matthias Boerner
This commit is contained in:
frohlich 2007-01-21 18:34:48 +00:00
parent 722f35903d
commit ebbc3ba003

View file

@ -7,9 +7,43 @@ Bindings for THRUSTMASTER HOTAS Cougar stick/throttle combination.
-->
<PropertyList>
<name type="string">Thrustmaster Thrustmaster HOTAS Cougar</name>
<name type="string">Thrustmaster HOTAS Cougar</name>
<name type="string">Thrustmaster Thrustmaster HOTAS Cougar</name>
<name type="string">Thrustmaster HOTAS Cougar</name>
<!-- begin definition of modifier button, on HOTAS: Pinky Switch -->
<button n="2">
<desc>modifier button 0</desc>
<repeatable type="bool">false</repeatable>
<binding>
<command>nasal</command>
<script>
name = "/input/joysticks/js/button[2]";
mod = getprop(name);
if (mod == nil) {
setprop(name, 1);
} elsif (mod == 0) {
setprop(name, mod + 1);
}
</script>
</binding>
<mod-up>
<binding>
<command>nasal</command>
<script>
name = "/input/joysticks/js[0]/button[2]";
mod = getprop(name);
if (mod == nil) {
setprop(name, 0);
} elsif (mod == 1) {
setprop(name, mod - 1);
}
</script>
</binding>
</mod-up>
</button>
<!-- end definition of modifier button -->
<!-- begin main axis configuration -->
<axis>
<desc>Aileron</desc>
<number>
@ -39,209 +73,404 @@ Bindings for THRUSTMASTER HOTAS Cougar stick/throttle combination.
<desc>Throttle</desc>
<number>
<unix>2</unix>
<windows>3</windows>
<windows>2</windows>
</number>
<binding>
<command>nasal</command>
<script>controls.throttleAxis()</script>
<command>nasal</command>
<script>controls.throttleAxis()</script>
</binding>
</axis>
<!-- end main axis configuration -->
<!-- begin trim configuration -->
<!-- button on HOTAS: NWS, A/R DISC, MSL STEP, A-G TOGGLE -->
<button n="4">
<desc>reset trim</desc>
<binding>
<!-- button on HOTAS: Trim and Pinky Switch -->
<axis n="6">
<desc>elevation trim/reset elevation trim</desc>
<low>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
controls.elevatorTrim(1)
} elsif (mod == 1) {
setprop("/controls/flight/elevator-trim", 0);
}
</script>
</binding>
</low>
<high>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
controls.elevatorTrim(-1)
} elsif (mod == 1) {
setprop("/controls/flight/elevator-trim", 0);
}
</script>
</binding>
</high>
</axis>
<axis n="5">
<desc>aileron trim/reset aileron trim</desc>
<low>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
controls.aileronTrim(-1)
} elsif (mod == 1) {
setprop("/controls/flight/aileron-trim", 0);
}
</script>
</binding>
</low>
<high>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
controls.aileronTrim(1)
} elsif (mod == 1) {
setprop("/controls/flight/aileron-trim", 0);
}
</script>
</binding>
</high>
</axis>
<!-- button on HOTAS: Countermeasures Management and Pinky Switch -->
<button n="17">
<desc>rudder trim left/reset rudder trim</desc>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>
setprop("/controls/flight/elevator-trim", 0);
setprop("/controls/flight/aileron-trim", 0);
setprop("/controls/flight/rudder-trim", 0);
</script>
</binding>
</button>
<!-- button on HOTAS: Trim -->
<axis n="5">
<desc>aileron left and right trim</desc>
<low>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>controls.aileronTrim(-1)</script>
</binding>
</low>
<high>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>controls.aileronTrim(1)</script>
</binding>
</high>
</axis>
<axis n="6">
<desc>elevation up and down trim</desc>
<low>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>controls.elevatorTrim(1)</script>
</binding>
</low>
<high>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>controls.elevatorTrim(-1)</script>
</binding>
</high>
</axis>
<!-- end trim configuration -->
<!-- begin view configuration -->
<!-- button on HOTAS: RDR CURSOR/ENABLE -->
<button n="18">
<desc>reset view</desc>
<binding>
<command>nasal</command>
<script>view.resetView()</script>
</binding>
</button>
<!-- button on HOTAS: Display Management -->
<button n="10">
<desc>view up</desc>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>view.panViewPitch(1)</script>
</binding>
</button>
<button n="11">
<desc>view right</desc>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>view.panViewDir(-1)</script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
controls.rudderTrim(-1)
} elsif (mod == 1) {
setprop("/controls/flight/rudder-trim", 0);
}
</script>
</binding>
</button>
<button n="12">
<desc>view down</desc>
<button n="15">
<desc>rudder trim right/reset rudder trim</desc>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>view.panViewPitch(-1)</script>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
controls.rudderTrim(1)
} elsif (mod == 1) {
setprop("/controls/flight/rudder-trim", 0);
}
</script>
</binding>
</button>
<!-- end trim configuration -->
<!-- begin view configuration -->
<!-- button on HOTAS: Display Management and Pinky Switch -->
<button n="10">
<desc>view up/view reset</desc>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
view.panViewPitch(1)
} elsif (mod == 1) {
view.resetView()
}
</script>
</binding>
</button>
<button n="12">
<desc>view down/view reset</desc>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
view.panViewPitch(-1)
} elsif (mod == 1) {
view.resetView()
}
</script>
</binding>
</button>
<button n="11">
<desc>view right/view reset</desc>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
view.panViewDir(-1)
} elsif (mod == 1) {
view.resetView()
}
</script>
</binding>
</button>
<button n="13">
<desc>view left</desc>
<desc>view left/view reset</desc>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>view.panViewDir(1)</script>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
view.panViewDir(1)
} elsif (mod == 1) {
view.resetView()
}
</script>
</binding>
</button>
<!-- end view configuration -->
<!-- begin switch view configuration -->
<!-- button on HOTAS: Pinky Switch -->
<button n="3">
<desc>switch view</desc>
<binding>
<command>nasal</command>
<script>view.stepView(1)</script>
</binding>
</button>
<!-- button on HOTAS: Target Management right and Pinky Switch -->
<button n="7">
<desc>switch view - forward/reset view to cockpit view</desc>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
view.stepView(1)
} elsif (mod == 1) {
setprop("/sim/current-view/view-number", 0);
}
</script>
</binding>
</button>
<!-- button on HOTAS: Target Management left and Pinky Switch -->
<button n="9">
<desc>switch view - backward/reset view to cockpit view</desc>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
view.stepView(-1)
} elsif (mod == 1) {
setprop("/sim/current-view/view-number", 0);
}
</script>
</binding>
</button>
<!-- end switch view configuration -->
<!-- begin zoom configuration (FOV)-->
<!-- button on HOTAS: Communications Switch -->
<button n="21">
<desc>zoom in</desc>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>view.decrease(1)</script>
</binding>
</button>
<!-- button on HOTAS: Communications Switch and Pinky Switch -->
<button n="6">
<desc>zoom in/reset zoom</desc>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
view.decrease(1);
} elsif (mod == 1) {
setprop("/sim/current-view/field-of-view", 55);
}
</script>
</binding>
</button>
<button n="22">
<desc>zoom out</desc>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>view.increase(1)</script>
</binding>
</button>
<button n="19">
<desc>reset zoom</desc>
<binding>
<command>nasal</command>
<script>view.resetFOV()</script>
</binding>
</button>
<button n="8">
<desc>zoom out/reset zoom</desc>
<repeatable>true</repeatable>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
view.increase(1);
} elsif (mod == 1) {
setprop("/sim/current-view/field-of-view", 55);
}
</script>
</binding>
</button>
<!-- end zoom configuration (FOV)-->
<button n="27">
<desc>speedbrake</desc>
<binding>
<command>nasal</command>
<script>setprop("/controls/flight/speedbrake", 1)</script>
</binding>
<mod-up>
<binding>
<command>nasal</command>
<script>setprop("/controls/flight/speedbrake", 0)</script>
</binding>
</mod-up>
</button>
<!-- begin speedbrake configuration -->
<!-- button on HOTAS: SpeedBrake -->
<button n="27">
<desc>speedbrake</desc>
<binding>
<command>nasal</command>
<script>setprop("/controls/flight/speedbrake", 1)</script>
</binding>
<mod-up>
<binding>
<command>nasal</command>
<script>setprop("/controls/flight/speedbrake", 0)</script>
</binding>
</mod-up>
</button>
<!-- end speedbrake configuration -->
<!-- begin gear configuration -->
<!-- button on HOTAS: Manual Range/Uncage Switch -->
<button n="23">
<desc>gear up or down</desc>
<binding>
<command>nasal</command>
<script>controls.gearToggle()</script>
</binding>
</button>
<!-- button on HOTAS: Manual Range/Uncage Switch and Pinky Switch -->
<button n="23">
<desc>gear up or down/tail wheel lock</desc>
<repeatable type="bool">false</repeatable>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
gearToggle = getprop("/controls/gear/gear-down");
if (gearToggle == 1) {
controls.gearDown(-1);
gui.popupTip("Gear up!");
} else {
controls.gearDown(1);
gui.popupTip("Gear down!");
}
} elsif (mod == 1) {
tailwheelLock = getprop("/controls/gear/tailwheel-lock");
if (tailwheelLock == 1) {
setprop("/controls/gear/tailwheel-lock", 0);
gui.popupTip("Tailwheel unlocked!");
} else {
setprop("/controls/gear/tailwheel-lock", 1);
gui.popupTip("Tailwheel locked!");
}
}
</script>
</binding>
</button>
<!-- begin nose wheel configuration -->
<button n="4">
<desc>nose wheel on/off</desc>
<repeatable type="bool">false</repeatable>
<binding>
<command>nasal></command>
<script>
nosewheel = getprop("/controls/gear/nose-wheel-steering");
if (nosewheel == 1) {
setprop("/controls/gear/nose-wheel-steering", 0);
gui.popupTip("Nose wheel steering on!");
} else {
setprop("/controls/gear/nose-wheel-steering", 1);
gui.popupTip("Nose wheel steering off!");
}
</script>
</binding>
</button>
<!-- end nose wheel steering configuration -->
<!-- end gear configuration -->
<!-- begin flaps configuration -->
<!-- botton on HOTAS: Target Management -->
<button n="6">
<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>
<!-- botton on HOTAS: Countermeasures Management up/down and Pinky Switch -->
<button n="14">
<desc>flaps up</desc>
<repeatable type="bool">false</repeatable>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
controls.flapsDown(-1)
} elsif (mod == 1) {
setprop("/controls/flight/flaps", 0);
}
</script>
</binding>
</button>
<button n="8">
<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="16">
<desc>flaps down</desc>
<repeatable type="bool">false</repeatable>
<binding>
<command>nasal</command>
<script>
mod = getprop("/input/joysticks/js[0]/button[2]");
if (mod == nil or mod == 0) {
controls.flapsDown(1)
} elsif (mod == 1) {
setprop("/controls/flight/flaps", 0);
}
</script>
</binding>
</button>
<!-- end flaps configuration -->
</PropertyList>
<!-- begin thrust reverse configuration -->
<!-- button on HOTAS: Dogfight left-->
<button n="24">
<desc>thrust reverse</desc>
<repeatable type="bool">false</repeatable>
<binding>
<command>nasal</command>
<script>
props.setAll("/controls/engines/engine", "reverser", 1);
gui.popupTip("Thrust reverse on!");
</script>
</binding>
<mod-up>
<binding>
<command>nasal</command>
<script>
props.setAll("/controls/engines/engine", "reverser", 0);
gui.popupTip("Thrust reverse off!");
</script>
</binding>
</mod-up>
</button>
<!-- end thrust reverse configuration -->
<!-- begin tailhook configuration -->
<!-- button on HOTAS: Dogfight right-->
<button n="25">
<desc>thrust reverse</desc>
<repeatable type="bool">false</repeatable>
<binding>
<command>nasal</command>
<script>
setprop("/controls/gear/tailhook", 1);
gui.popupTip("Tailhook down!");
</script>
</binding>
<mod-up>
<binding>
<command>nasal</command>
<script>
setprop("/controls/gear/tailhook", 0);
gui.popupTip("Tailhook up!");
</script>
</binding>
</mod-up>
</button>
<!-- end tailhook configuration -->
</PropertyList>