help me whitelist your weird gamepad

writing modern controller support for pc games is a hell !

a ramble, do not read

on windows, once upon a time directinput (or rarely, but where necessary rawinput) was fairly straightforward solution here – you have n axes, buttons, hats, poll them each, provide a default layout and a gamepad configurator, and call it done

then xinput broke the standard (on windows) for unjustifiable reasons and required a second library to support certain inputs on those devices specifically, hence all those joyful xbla-era titles that just throw out everything else. wow ! it’s terrible. xb360ce works fine, but the idea of the thing, and that it is a necessity at all is terrible.

amusingly xbox one pads behave perfectly fine under directinput, which cements that xinput exclusivity was just a terrible time for all involved !

so now we have xinput and directinput, and also steam input, which is theoretically cool; opting all devices into that system would be a nice catch-all if not for that it’s closed-source, officially supports only 6 device types, requires things run under steam, and also is prone to misbehaving itself. while it can’t entirely be relied upon to abstract gamepad implementation (according to the library’s documentation you should just… support all of the above), it shouldn’t be discounted entirely, because people are going to use it regardless !

so now i have to support… directinput, xinput, steam input, with no idea what a directinput pad actually looks like, scuttling any hope of useful button prompts !

apparently the modern solution to this (via SDL) is just mapping everything to xinput-standard and calling it a day. this doesn’t cut it in tyool 2019 because we want console-style button prompts that match the device in-hand, so ps Square and xbox X and nintendo Y are all left-face-button but i need to identify any given pad to label it correctly. first any given controller is reconfigured into something that looks like an xinput device, and then labels for which xbox input corresponds to which button on your actual device needs be identified. a lot of chicken and egg. a lot of torn out hair.

retroarch sort of has this figured out, but their database outside linux is extremely small, and their format is weird.

combing through the sdl community db and praying things are more-or-less usably mapped for my projects has been a project for a couple months now

as a final bonus round, amazon and ebay are flooded with knockoff devices that in many cases aren’t properly identifiable in software at all !

all that to say, if you sympathize with this

and would aid my quest to make my rpg work with like, configurations as ludicrous as your qanba arcade stick on android via otg cable (forgive me @HEAVYVIPER) i would appreciate it. note that this is gamepad support, so flightsticks, rock band controllers, etc need not apply. adapters and receivers for console pads welcome.

i have a separate tool that might be a necessary second-step on windows, also built for android.

my code preliminarily supports weird shit that doesn’t properly report as a controller (like iCade, X-Arcade), so if you have one of these i could probably use your help too

for fun, a selected list of other developers that have taken to similarly panhandling their audience for these device ids: doublefine, yacht club, zero labs …

whitelisting sucks ! this whole endeavor sucks. a guy drove to my girlfriend’s house earlier today with a huge box full of knock-off ps3 controllers, that’s the state of my life right now.

8 Likes

Every time I drop by my parents’, I’ll grab a handful of oddball pads!

1 Like

:pray: :pray: :pray:

1 Like

this is not a fun problem and why I eventually resolved to only support major controllers + remappable past that.You get the Steam list covered and the only complaints you’ll hear are from the same people asking for a Linux port

2 Likes

You’re doing the Peripheral God’s work pal. :geoglyph:

4 Likes

I wonder if there’s a thread like this but for Rewired. RW is supposed to let you custom map weirdo controllers, but I’ve never had an easy time w it

Rewired pretty much just abstracts the SDL2 stuff: Rewired Documentation | Supported Controllers

This effectively articulates why whitelisting fails for obscure hardware:
http://guavaman.com/projects/rewired/docs/FAQ.html#addding-controller-definitions

I too am

but I want to provide a robust number of button prompts (this is the ‘fun’ part) and offer sensible defaults where devices can be reliably detected, which is a probably-eternal rabbit hole i’m just going to have to call done at some point. currently i’ve something like 700 ids between all devices & platforms.

the workload of even ‘major controllers’ becomes inflated because of the number of connectivity methods and hardware revisions all of these have :')

2 Likes

I’ve read through the lists and they’re surprisingly short and missing some things I thought for sure would be listed! I can provide both PC and Linux info. Hopefully I can pad things out a bit…

1 Like

:persevere:

6 Likes

I hope that’s machine-generated

1 Like

linted spreadsheet output, yeah. i’ve touched nearly every field by hand at some point or other tho :disappointed_relieved:

:servbotsalute:

3 Likes

pushed some 60+ device maps back upstream to the community repo that skullgirls and kof amoungst others have used, feels good

i don’t do much oss work and it’s kind of frustrating to see over ten different repos with adjacent if not parallel goals collecting near-identical data with no apparent cross-talk between them whatsoever, i guess this is common amoung a lot of organizational structures hunh :-/

4 Likes

Got any use for a weird, cheap, off-brand USB N64 controller.
I haven’t actually gotten much use of the thing since Project64 doesn’t seem to recognize the damn thing.

probably not but thanks 4 asking !! what do you get for vendor/product if you plug it in and look here: https://html5gamepad.com/

1 Like

Fuck I’m the worst

don’t fret i’ve become tremendously powerful in the meantime and am almost perfectly certain you could not produce a device i have not already fussed over the particulars of

1 Like

I get:

Generic USB Joystick (Vendor: 0079 Product: 0006)

which does not inspire my confidence in the product. Then again, I can’t say I wasn’t warned by several people on Twitter that this thing would be an abomination.

i have indeed got one of those already and alas as you say it is unworthy of the cause, but thanks for asking!