forked from Clones/Controlify
✏️ Abstract GUID and controller name into drivers
This commit is contained in:
@ -32,13 +32,13 @@ public class GamepadController extends AbstractController<GamepadState, GamepadC
|
||||
if (!GLFW.glfwJoystickIsGamepad(joystickId))
|
||||
throw new IllegalArgumentException("Joystick " + joystickId + " is not a gamepad!");
|
||||
|
||||
if (!this.name.startsWith(type().friendlyName()))
|
||||
setName(GLFW.glfwGetGamepadName(joystickId));
|
||||
|
||||
this.drivers = GamepadDrivers.forController(joystickId, hidInfo.hidDevice());
|
||||
this.uniqueDrivers = drivers.getUniqueDrivers();
|
||||
this.drivers.printDrivers();
|
||||
|
||||
if (!this.name.startsWith(type().friendlyName()))
|
||||
setName(this.drivers.nameProviderDriver().getName());
|
||||
|
||||
this.rumbleManager = new RumbleManager(this);
|
||||
|
||||
this.defaultConfig = new GamepadConfig();
|
||||
|
Reference in New Issue
Block a user