Getting input from controllers

I’m wanting to program a custom rc car in kotlin and I’m wondering how I can get input from some kind of game controller?

I do not think this question has any specific answer unless you specify what controller do you mean, how it is connected with PC or other hardware, which protocol does it use, etc.

In general, there should be some kind of driver for your controller, or OS specific API. You can search for Java library that works with it or wrap native API with JNI, JNA or new jectract tool.

that’s the thing, I’m choosing what controller I’m going to use based off its support. though I’d assume a wired xbox controller might be easiest

Then check java libraries first. It seems that there are Java APIs for that.