Jump to content
  • Advertisement
Sign in to follow this  
InsaneGenius

How do I get Button Pressure from a gamepad?

This topic is 3710 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I am a vb.net programmer. (But any example in any language would help) I have an original xbox controller hooked up to my PC. The buttons are pressure sensitive. The driver I got for it works for the pressure sensitiveness. The problem I am having is, how am I able to get the values for the button pressure? The range is from 00-FF according to the driver. Driver link http://www.redcl0ud.com/xbcd.html There are lots of tutorials on how to put a usb end on your xbox controller. Is there a joystick dll for this? Thanks.

Share this post


Link to post
Share on other sites
Advertisement
You shouldn't have to download any extra drivers. Just use the Xinput API (successor to DirectInput) to manipulate joysticks and game pads.

Share this post


Link to post
Share on other sites
I don't think it's very easy to control the pressure you put on an Xbox controller. I don't really know because I can't remember one game that used it, but the button feels like it's either up or pressed and I can't feel any middle grounds.

I would advise you to stay away from this design decision to use pressure. Especially since the controller comes equipped with to triggers!

Share this post


Link to post
Share on other sites
Quote:
Original post by Splinter of Chaos
I don't think it's very easy to control the pressure you put on an Xbox controller. I don't really know because I can't remember one game that used it, but the button feels like it's either up or pressed and I can't feel any middle grounds.

I would advise you to stay away from this design decision to use pressure. Especially since the controller comes equipped with to triggers!


To the contrary:

Just about all of the buttons on the 360 controller are analog buttons. That means a variable voltage is produced based on how hard you press them. The same probably goes for the Xbox 1 controller.

For example: Have you played a game like Forza? Partially pulling the triggers produce variable response in the game.

[Edited by - fpsgamer on May 26, 2008 5:54:18 PM]

Share this post


Link to post
Share on other sites
Quote:
Original post by fpsgamer
To the contrary:

Just about all of the buttons on the 360 controller are analog buttons. That means a variable voltage is produced based on how hard you press them. The same probably goes for the Xbox 1 controller.

For example: Have you played a game like Forza? Partially pulling the triggers produce variable response in the game.

While true, Splinter of Chaos' point was that it is difficult for a user to gauge how much pressure to apply on the analog face buttons. The triggers, after all, are not "buttons" but "triggers" (yeah, semantic nitpick). I don't know of any game that employs analog pressure input for the face buttons, X, Y, A, B. (Ditto DualShock 2/3.)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!