forked from Clones/Controlify
✏️ Remove vanilla override from show player list
This commit is contained in:
@ -18,6 +18,7 @@ public class InGameInputHandler {
|
||||
private final Minecraft minecraft;
|
||||
|
||||
private double lookInputX, lookInputY;
|
||||
private boolean shouldShowPlayerList;
|
||||
|
||||
public InGameInputHandler(Controller<?, ?> controller) {
|
||||
this.controller = controller;
|
||||
@ -38,6 +39,8 @@ public class InGameInputHandler {
|
||||
}
|
||||
|
||||
protected void handleKeybinds() {
|
||||
shouldShowPlayerList = false;
|
||||
|
||||
if (Minecraft.getInstance().screen != null)
|
||||
return;
|
||||
|
||||
@ -63,6 +66,8 @@ public class InGameInputHandler {
|
||||
if (controller.bindings().TOGGLE_HUD_VISIBILITY.justPressed()) {
|
||||
minecraft.options.hideGui = !minecraft.options.hideGui;
|
||||
}
|
||||
|
||||
shouldShowPlayerList = controller.bindings().SHOW_PLAYER_LIST.held();
|
||||
}
|
||||
|
||||
protected void handlePlayerLookInput() {
|
||||
@ -131,6 +136,10 @@ public class InGameInputHandler {
|
||||
}
|
||||
}
|
||||
|
||||
public boolean shouldShowPlayerList() {
|
||||
return this.shouldShowPlayerList;
|
||||
}
|
||||
|
||||
public record FunctionalLookInputModifier(BiFunction<Float, Controller<?, ?>, Float> x, BiFunction<Float, Controller<?, ?>, Float> y) implements LookInputModifier {
|
||||
@Override
|
||||
public float modifyX(float x, Controller<?, ?> controller) {
|
||||
|
Reference in New Issue
Block a user