• Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
Question by 88bueno · May 19, 2010 at 06:12 PM · gamepad

Setting up game pad

I have a Saitek Cyborg Rumble controller that's modeled after a ps3 controller and I was wondering how you would set up Unity to receive player inputs from the controller instead of the keyboard. I've messed with the input editor a little bit, but I'm thoroughly lost on it. I've never really messed with a game engine before I just have done modeling until now. Any help would be greatly appreciated. Thank you in advance.

Comment
Gamerkax

People who like this

1 Show 0
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

2 Replies

· Add your reply
  • Sort: 
avatar image
Best Answer

Answer by Eric5h5 · May 19, 2010 at 06:59 PM

For gamepad buttons, set up new buttons in the input manager by using "joystick button x" for the positive or negative buttons, where x = the number of the button you want (starting with 0). The Type should be "Key or Mouse Button". To use this in scripting, use Input.GetButton("XX"), where "XX" is the Name of the entry from the input manager.

For gamepad analog sticks, set up new axes in the input manager by using "Joystick Axis" for the Type. The left stick would need two entries in the input manager, one horizontal (using the X axis), and one vertical (using the Y axis). The right stick would need another two, using the 3rd and 4th axes. To use these in scripting, using Input.GetAxis("XX"), where "XX" is again the Name of the entry from the input manager.

Comment
qJake
rbisso
RavenOfCode
ceren

People who like this

4 Show 2 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image 88bueno · Jun 09, 2010 at 06:06 PM 0
Share

everything's set up in a new axis configuration and the scripting is right and it still doesn't get movement. I have no idea what I'm doing wrong. There ARE two sets of horizontal and vertical because my input size is set to 17. Could that throw things off?

avatar image 88bueno · Jun 09, 2010 at 06:19 PM 0
Share

it won't even program jump to a button when I change the input to a button. my computer's device listings show which buttons are which, and I tried the jump as a test. Jump will not function with any of the joystick buttons.

avatar image

Answer by morymac · Jun 26, 2012 at 05:18 PM

Hi, just do it like Eric5h5 said! I just made a video on this topic. If you want to, you can take a look at it:

http://youtu.be/xR3l6rOkjLA

Comment

People who like this

0 Show 0 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Welcome to Unity Answers

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Follow this Question

Answers Answers and Comments

1 Person is following this question.

avatar image

Related Questions

XBox 360 controller for the GUI 1 Answer

Mouse and Game controller at the same time 0 Answers

Emulating Xbox 360 controller stick 0 Answers

Using a bluetooth gamepad controller with iOS/Android 1 Answer

Is There Any Way To Configure A D-Pad To Be Buttons Instead Of An Axis? 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges