From f74d49513c46a5a4990446411018da9f34fb577f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mathias=20Dj=C3=A4rv?= Date: Fri, 10 Nov 2017 23:22:57 +0100 Subject: [PATCH] tm throttle base switches now move --- .../HOTAS Warthog/TMWarthogThrottle.cs | 76 +++++++++++++++++- .../Assets/JoystickVisualizer.unity | Bin 74216 -> 86928 bytes JoystickVisualizer/Assets/StickOrganizer.cs | 3 + 3 files changed, 75 insertions(+), 4 deletions(-) diff --git a/JoystickVisualizer/Assets/Devices/HOTAS Warthog/TMWarthogThrottle.cs b/JoystickVisualizer/Assets/Devices/HOTAS Warthog/TMWarthogThrottle.cs index c9299fc..00a3ffd 100644 --- a/JoystickVisualizer/Assets/Devices/HOTAS Warthog/TMWarthogThrottle.cs +++ b/JoystickVisualizer/Assets/Devices/HOTAS Warthog/TMWarthogThrottle.cs @@ -13,7 +13,18 @@ public class TMWarthogThrottle : MonoBehaviour { public GameObject GimbalFriction; - public GameObject GimbalAPU; + public GameObject FlowL; + public GameObject FlowR; + public GameObject IgnL; + public GameObject IgnR; + public GameObject Flaps; + public GameObject APU; + public GameObject LG; + public GameObject EAC; + public GameObject RDR; + public GameObject AutopilotEngage; + public GameObject AutopilotLaste; + // Use this for initialization void Start() @@ -43,28 +54,85 @@ void StickEvent(JoystickState state) // Rotate Z between -30 and 30 GimbalLeft.transform.eulerAngles = new Vector3(ConvertRange(entry.Value, 0, 65535, 40, -25), GimbalLeft.transform.eulerAngles.y, GimbalLeft.transform.eulerAngles.z); break; + case "Z": // Right Throttle // Rotate X between -30 and 30 GimbalRight.transform.eulerAngles = new Vector3(ConvertRange(entry.Value, 0, 65535, 40, -25), GimbalRight.transform.eulerAngles.y, GimbalRight.transform.eulerAngles.z); break; - case "Buttons19": // Right Throttle Idle/Off - GimbalAPU.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : 30.0f); - break; + case "Buttons28": // Right Throttle Idle/Off if (entry.Value == 0) GimbalRight.transform.eulerAngles = new Vector3(-25, GimbalRight.transform.eulerAngles.y, GimbalRight.transform.eulerAngles.z); else GimbalRight.transform.eulerAngles = new Vector3(-35, GimbalRight.transform.eulerAngles.y, GimbalRight.transform.eulerAngles.z); break; + case "Buttons29": // Left Throttle Idle/Off if (entry.Value == 0) GimbalLeft.transform.eulerAngles = new Vector3(-25, GimbalLeft.transform.eulerAngles.y, GimbalLeft.transform.eulerAngles.z); else GimbalLeft.transform.eulerAngles = new Vector3(-35, GimbalLeft.transform.eulerAngles.y, GimbalLeft.transform.eulerAngles.z); break; + case "Sliders0": // Friction GimbalFriction.transform.eulerAngles = new Vector3(ConvertRange(entry.Value, 0, 65535, 40, -40), GimbalFriction.transform.eulerAngles.y, GimbalFriction.transform.eulerAngles.z); break; + + case "Buttons15": + FlowL.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : 40.0f); + break; + + case "Buttons16": + FlowR.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : 40.0f); + break; + + case "Buttons17": + IgnL.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : -20.0f); + break; + case "Buttons30": + IgnL.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : 20.0f); + break; + + case "Buttons18": + IgnR.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : -20.0f); + break; + case "Buttons31": + IgnR.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : 20.0f); + break; + + case "Buttons19": + APU.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : 40.0f); + break; + + case "Buttons20": + LG.transform.localPosition = Vector3.down * ((entry.Value == 0) ? 0.0f : 0.0035f); + break; + + case "Buttons25": + AutopilotEngage.transform.localPosition = Vector3.down * ((entry.Value == 0) ? 0.0f : 0.0035f); + break; + + case "Buttons23": + EAC.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : 40.0f); + break; + + case "Buttons24": + RDR.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : 40.0f); + break; + + case "Buttons26": + AutopilotLaste.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : 20.0f); + break; + case "Buttons27": + AutopilotLaste.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : -20.0f); + break; + + case "Buttons21": + Flaps.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : 20.0f); + break; + case "Buttons22": + Flaps.transform.eulerAngles = Vector3.right * ((entry.Value == 0) ? 0.0f : -20.0f); + break; } } } diff --git a/JoystickVisualizer/Assets/JoystickVisualizer.unity b/JoystickVisualizer/Assets/JoystickVisualizer.unity index 7f0aebb6b3c0c731d89dda62a5fa94fa04ed8cb9..a25b886e955d8d09b2e223102cef9cecd2d48343 100644 GIT binary patch delta 19671 zcmaK!3qVxW_W#dO)KS1dP(}qE(tMN%Br25%zR^HO(6VkCBThmN3<4V5^3M3E)H2bn zjj7mZrIwE{OvzW+!|+vDru0y;Tldn#8y5s-#veW}{Hm^f*HUwjXFG9q zG#Fh)8?YIgQ`vc39S25N!|0-4*=ekOWQ0DNog5IMr?R1uhGc}F%4WjCO$C%Zh2+CMuwEb6?bxm}Q;x}&+In@f}3&#`GyhTT2* zRWGgzkEF5}q9R<%?mK)}b?s}E-GpFMj^vOjPR zn_b$S%`PZKclo$bv=8T`sGpBFQKXT}{0&ul`un)ha}wvICzf-U(T}QSalQi5PdF#< z#{0NX^aajI(cM1Y)Sv;)xH2d~@(g=+@g!5BEx+h7XJH<@*sCu)7v*r|JvuBuJI7g= zo|~`vj%_8rWBUxNvnaPX*GZQ%bN_B1X?GOcaBR(;>nzp^xpwW%Q$xB;I$l2}cjiFn z{+#Xi%-!&y^JH??fBSAaaeTx4-d{Wbv4>hzE{_@4LQiD2p(9)%?h&9gc)D^WhHLJ} zIk_MbyY3eZ>5@~J`tu2rcWcHcO5WYaba%w3B35CDlt+iC}Z*Wcq@#uHsnoDcb z#8L`>J%tLHnpjHV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etqOcxewVB6^sL=IIhS^BGA~`7%i2qnOL5uG&30KW11?i;7F;HG zFJ0ETd0)Cx{3qpR=NER3%3-zmh_H8_C1j74Dui9GGbzkgCFatVdynO9CQuNvt7NYP z%#wyq*5YR3e)QTo{IczawL#nAxSwA49-L!!X)fZ-$*bGo_Zj%HNvq0REX&zKINDRV zn%*WwTCpvJJ%;C7)1!sk+Sx+b9W=>0O~-w4n|PIl8-t{Ubo(gl+P+h1(URR{4_5SD0K@cI#{6QB8TWJRuy9)=kUD@`fND6skAOu79|#Lm>zU9X@9+#NqHz+-W>p zj=LVKA`~u!Sf@ecf)Ay&t}tnBc9`hzR!&~426IoXqc8zr(O6&652%4>{YFL#hUA{_&J>q3Acm4U5}*OC^)k*MwVpkjj&4oox)7}DxwAbamY;l-W4<}J6jmm z#I_=$v-%d2BBK7DM?cHISTCL{B4X5^A&IK*I_PKhmmK<;z9T~%JK@san_y#G%iCT= zwQqcg#F8+))C1*Y8RVlf$evytgP3CJwZ|Vzr z>X0YxmTl3Hh?`_jET8$Nb!afMvoMxBY@RiI2xSk?QaY{(^qf9+i-Aj1_uDPj2lJlF zZiBt8#X*%0U$(ckIF#wj|DiGIjmPOB^2v_AU$CF1V!p(DipMF0z$ zFUJ`O?hp~zDjGU=HBDbbtzSFDjyUde=@LcK%K^9W{wyCJtm0eP0C~4(d4@JIpm3-( zVCPWLzieot@X&zDND`lk)>hx)Y!p1hS4ESCOQR}=%ZVR*>lKqj-V<4Mx60j&p3!04 zrCU+QR46pxqpbYfUNfVB!jUvlWyK6Zv*3}?sve7I U(6=GaTd8Bwh-Z&C-Z6yzKeSBQH~;_u diff --git a/JoystickVisualizer/Assets/StickOrganizer.cs b/JoystickVisualizer/Assets/StickOrganizer.cs index 96e8663..0aeaf61 100644 --- a/JoystickVisualizer/Assets/StickOrganizer.cs +++ b/JoystickVisualizer/Assets/StickOrganizer.cs @@ -6,6 +6,7 @@ public class StickOrganizer : MonoBehaviour { private const float OFFSET = 20.0f; + public GameObject NoDevicesText; public GameObject[] ControllerModels; private List activeControllers = new List(); @@ -33,6 +34,8 @@ void Update () { if (oldLength != activeControllers.Count) { + NoDevicesText.SetActive(activeControllers.Count == 0); + Debug.Log("Active controller count changed from "+ oldLength + " to " + activeControllers.Count + ", reorganizing models"); float center = ((activeControllers.Count-1) * OFFSET) / 2;