Jump to content
  • Advertisement
Sign in to follow this  
sorin_g

[MDX] Steerwheel pedals

This topic is 3733 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

Hello everyone. I'm using MDX and I try to control a car using a steerwheel. The wheel has 2 pedals (acceleration + brake). Everything is set up, but I can't get to read the data from the pedals. I'm using the JoystickState class like this: JoystickState state = steerwheel.CurrentJoystickState; I manage to get input from buttons, from wheel, but I don't know how to get input from the two pedals. Can you help me please? Thank you.

Share this post


Link to post
Share on other sites
Advertisement
Well, that was quite simple :)
I forgot to check the Y-axis, there it was!
The X-axis is used for steering.
The Y-axis is used for throttle (positive values) and brake (negative values).
Anyway, is this a known standard?
Because I want to make sure it will work with different types of wheels.
Thanks!

Share this post


Link to post
Share on other sites
I doubt it's a standard per se, because those sorts of things don't tend to get nailed down. It's probably reasonable to expect that nearly everyone does it the same way...but if there's one thing I've learned, there's almost certainly somebody out there who's doing it backwards just to piss you off. Best to give your players the option to invert the axes in case the wheel they're using is the odd one out.

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!