1
0
forked from Clones/Controlify

refactor button guide, bindings and controller identification

This commit is contained in:
isXander
2023-02-19 21:56:14 +00:00
parent 23c048f401
commit 0f719c0f45
21 changed files with 334 additions and 220 deletions

View File

@ -39,8 +39,7 @@ public class JoystickAxisBind implements IBind<JoystickState> {
}
@Override
public void draw(PoseStack matrices, int x, int centerY, Controller<JoystickState, ?> controller) {
if (controller != joystick) return;
public void draw(PoseStack matrices, int x, int centerY) {
JoystickMapping mapping = joystick.mapping();
String type = joystick.type().identifier();
@ -77,6 +76,11 @@ public class JoystickAxisBind implements IBind<JoystickState> {
return object;
}
@Override
public Controller<JoystickState, ?> controller() {
return joystick;
}
@Override
public boolean equals(Object o) {
if (this == o) return true;