MidnightControls 1.1.0 - 1.19, Inventory Improvements

- Update to 1.19
- Make buttons for Item/Stack Grabbing and Quick Moving configurable
- Add Keybinds for moving between Fabric Creative Inventory Pages
This commit is contained in:
Motschen
2022-06-09 21:59:26 +02:00
parent bca73c93cc
commit 6e64c7c97d
32 changed files with 624 additions and 274 deletions

View File

@@ -106,7 +106,7 @@ public class MidnightControlsHud extends Hud {
this.drawButton(matrices, currentX, y, ButtonBinding.INVENTORY, true);
this.drawButton(matrices, currentX += (MidnightControlsConfig.hudSide == HudSide.LEFT ? offset : -offset), y, ButtonBinding.SWAP_HANDS, true);
offset = 2 + this.swapHandsWidth + this.dropItemButtonWidth + 4;
if (this.client.options.showSubtitles && MidnightControlsConfig.hudSide == HudSide.RIGHT) {
if (this.client.options.getShowSubtitles().getValue() && MidnightControlsConfig.hudSide == HudSide.RIGHT) {
currentX += -offset;
} else {
currentX = MidnightControlsConfig.hudSide == HudSide.LEFT ? x : x - this.dropItemButtonWidth;
@@ -123,7 +123,7 @@ public class MidnightControlsHud extends Hud {
currentX -= this.useButtonWidth;
this.drawButton(matrices, currentX, y, ButtonBinding.USE, true);
offset = 2 + this.useWidth + 4;
if (this.client.options.showSubtitles && MidnightControlsConfig.hudSide == HudSide.LEFT) {
if (this.client.options.getShowSubtitles().getValue() && MidnightControlsConfig.hudSide == HudSide.LEFT) {
currentX -= offset;
} else {
currentX = x;
@@ -143,7 +143,7 @@ public class MidnightControlsHud extends Hud {
currentX += MidnightControlsConfig.hudSide == HudSide.LEFT ? this.inventoryWidth + 4 + this.swapHandsButtonWidth + 2
: -this.swapHandsWidth - 2 - this.swapHandsButtonWidth - 4;
this.drawTip(matrices, currentX, y, ButtonBinding.SWAP_HANDS, true);
if (this.client.options.showSubtitles && MidnightControlsConfig.hudSide == HudSide.RIGHT) {
if (this.client.options.getShowSubtitles().getValue() && MidnightControlsConfig.hudSide == HudSide.RIGHT) {
currentX += -this.dropItemWidth - 2 - this.dropItemButtonWidth - 4;
} else {
y -= 24;
@@ -160,7 +160,7 @@ public class MidnightControlsHud extends Hud {
this.drawTip(matrices, currentX, y, this.placeAction, true);
if (this.client.options.showSubtitles && MidnightControlsConfig.hudSide == HudSide.LEFT) {
if (this.client.options.getShowSubtitles().getValue() && MidnightControlsConfig.hudSide == HudSide.LEFT) {
currentX -= 4;
} else {
currentX = x;