-
Notifications
You must be signed in to change notification settings - Fork 88
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Xbox Controller buttons not registering, but analog axes are? #19
Comments
For the first issue I need you to create a new project and try to replicate the issue there. If you can replicate it there send the project to me so I can debug it. For the second issue make sure the InputManager script is first in the script execution order(Edit/Project Settings/Script Execution Order). |
Okay so I've created a new project and have set up a super basic test of receiving different kinds of input from the controller. As for the second issue, Script Execution Order fixed it - thanks, didn't think of that! :) Appreciate the prompt reply! |
Jump, Cancel, LeftBumper and RightBumper are buttons but you call InputManager.GetAxis which will always return zero. Use InputManager.GetButton instead. |
I can't believe I didn't see that. How very... embarrassing. :') Thanks for your time. |
Hey there, I've been using InputManager for quite a while now and have never had much of a problem with it, I recently updated the plugin in my Unity project and have attempted to set up controller support for our game.
It's mostly going okay, I've got the analog sticks and triggers working fine, but none of the buttons or bumpers are working. No errors, just the Axes do not return a value.
I'm not really sure what I could be doing wrong, as I suspect that it's me rather than an issue with the code. I've tried numerous input configurations (almost everything I could think of), all based off the default files.
Any ideas? I can give you a copy of the project if you wish.
Also, while I'm here - I've got a small issue with the InputAdapter where it breaks on initialisation if the gameobject is enabled straight away - a workaround is to enable it a second after the scene has loaded but this seems a bit hacky. It throws the following:
NullReferenceException: Object reference not set to an instance of an object TeamUtility.IO.InputMgr.SetInputConfiguration (System.String name, PlayerID playerID) (at Assets/Scripts/Utils/InputManager/Source/Runtime/InputManager.cs:639) TeamUtility.IO.InputAdapter.SetInputDevice (InputDevice inpuDevice) (at Assets/Scripts/Utils/InputManager/Addons/InputAdapter/Runtime/InputAdapter.cs:597) TeamUtility.IO.InputAdapter.Awake () (at Assets/Scripts/Utils/InputManager/Addons/InputAdapter/Runtime/InputAdapter.cs:445)
The text was updated successfully, but these errors were encountered: