Search Feedback

52
votes
Started

Increase joystick button limit

Input

-

-

Currently only 20 joystick buttons are supported and it prevents joysticks like Logitech G27 Racing Wheel from working properly. Hitting some of its buttons (those numbered beyond the limit) crashes a Unity application.

Comments (5)

  1. 6ff7593d6649ff2d0df642b2dc11de64?d=mm

    aitchest of dees

    Oct 12, 2015 22:02

    This is also an issue for older legacy USB devices on Android, where on Android it seems to add 14 to the button IDs. This means button 1 reports as button 15, and by the time you get to button 5, you can't use any more buttons on Android because you hit the 20 button limit.

  2. 01440adc53f3a513dc22fc313448229f?d=mm

    NCarter

    Sep 06, 2012 19:11

    I have a 9 axis, 39 button joystick here (Saitek X52 Pro). It's easy to end up with lots of buttons when you have several hats that count as four buttons each. I can't access any of the buttons past the 20th, and most of the interesting ones fall into that range.

    It clearly isn't a good idea to have a joystick button enum of unlimited size, so I think we need a different API for this kind of thing:

    bool Input.GetButton(int joystickNumber, int buttonNumber)

    That could work for axes, too:

    float Input.GetAxis(int joystickNumber, int axisNumber)

  3. 66e892914ae97b3ded30416139e913cc?d=mm

    Anonymous

    Jun 06, 2012 21:33

    Yep, this is definitely an issue for simulator folks....we have universal serial controlers that go up to 32 buttons...makes them useless...this is a BIG problem!!!!!

  4. 116ef7ee137d772862a0a52ff1ff97b4?d=mm

    Carlos

    Apr 12, 2012 16:36

    Please, we really need it for the G27.

  5. D676b7c9a41ba1cb810b15864a727427?d=mm

    Chris

    Oct 07, 2010 02:16

    I didn't realize that joysticks of that size existed... I haven't played a game with a joystick for many years. That being said, this does sound like something that should be addressed, if it's an easy fix.

Your opinion counts

Help us make things better. Share your great idea for improving Unity or vote for other people’s.

Log in to post a new idea

Categories

All

(9031)

2D

(221)

Ads

(40)

AI & Navigation

(67)

Analytics

(92)

Animation

(304)

Asset Store

(222)

Assets

(489)

Audio

(157)

Cloud Build

(94)

Collaborate

(31)

Docs & Tutorials

(197)

Editor

(2084)

Everyplay

(13)

Game Performance Reporting

(12)

General

(810)

Graphics

(761)

GUI

(363)

Input

(145)

Licensing

(73)

Networking

(158)

Physics

(341)

Platforms

(402)

Profiling & Optimization

(69)

Runtime

(161)

Scripting

(1014)

Terrain

(152)

WebGL

(131)