- Home /
How to get raw joystick axis data from script (C#)?
I am struggling to find a way to get the value of a joystick axis from script. I know you can get a joystick buttons state, but how can i get the value of axis without using the inbuilt Unity InputManager?
Why do you not want to use the Unity Input to get the data? Have you looked into any of the numerous asset store packages if you don't like Unity's setup?
I was trying to work with Windows and $$anonymous$$ac with 4 controllers. I thought it would have worked better in script. I just sat down today and setup 104 input axis in unity Input$$anonymous$$anager. The manager is not very user friendly. I still used a script to handle the inputs in a way that was friendly to other scripts (my script has functions like UniversalInput.GetLeftStick(Player)
). I have no idea why you cannot have in script something like Input.GetJoystick("joystick 1 axis 3")
Your answer
![](https://koobas.hobune.stream/wayback/20220612041604im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Problems with joystick / controller axes being 1/-1 "way too often" 1 Answer
Help In Making a SphereCast for 3D Tire! Working RayCast Script included! 0 Answers
Input.GetAxis returning nonsensical values for HID Sensor/GameController 0 Answers
Using Input.GetJoystickNames 1 Answer
Getting input from joystick number X 0 Answers