mirror of
https://github.com/TeamMidnightDust/MidnightControls.git
synced 2025-12-17 08:55:10 +01:00
Another round of improvements
Mostly related to touch screen support - Added selection outlines for Break-at-Finger mode - Breaking blocks/interacting with entities will now just check if the target changed, not the finger position - Added the ability to create custom touch buttons out of ButtonBindings - Redesigned top touch buttons - Added emote touch button when Emotecraft is installed - Updated SpruceUI - Removed old mixins
This commit is contained in:
@@ -33,7 +33,7 @@ public abstract class ControlsOptionsScreenMixin extends GameOptionsScreen {
|
||||
@Inject(method = "init", at = @At(value = "INVOKE", ordinal = 1, shift = At.Shift.AFTER, target = "Lnet/minecraft/client/gui/screen/option/ControlsOptionsScreen;addDrawableChild(Lnet/minecraft/client/gui/Element;)Lnet/minecraft/client/gui/Element;"))
|
||||
private void addControllerButton(CallbackInfo ci) {
|
||||
TextIconButtonWidget iconWidget = TextIconButtonWidget.builder(Text.translatable("midnightcontrols.menu.title.controller"), (button -> this.client.setScreen(new MidnightControlsSettingsScreen(this, false))), true)
|
||||
.dimension(20,20).texture(new Identifier("midnightcontrols", "icon/button"), 20, 20).build();
|
||||
.dimension(20,20).texture(new Identifier("midnightcontrols", "icon/controller"), 20, 20).build();
|
||||
iconWidget.setPosition(this.width / 2 + 158, this.height / 6 - 12);
|
||||
this.addDrawableChild(iconWidget);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user