diff options
| author | Raven Szewczyk <git@eigenraven.me> | 2023-04-10 17:49:16 +0100 |
|---|---|---|
| committer | Raven Szewczyk <git@eigenraven.me> | 2023-04-10 17:49:16 +0100 |
| commit | 8ac58626bd4caa9e49f58acc6b97ac031f6c2107 (patch) | |
| tree | 0a8c7b737f1f2607fa6875309f4c6a5c2b8b3331 /src/main/java/gregtech/common/tileentities/automation | |
| parent | d795cf740c3b48b602d3bfb708ed9e6c492ad37d (diff) | |
| download | GT5-Unofficial-8ac58626bd4caa9e49f58acc6b97ac031f6c2107.tar.gz GT5-Unofficial-8ac58626bd4caa9e49f58acc6b97ac031f6c2107.tar.bz2 GT5-Unofficial-8ac58626bd4caa9e49f58acc6b97ac031f6c2107.zip | |
Update spotless config to 0.2.2
Diffstat (limited to 'src/main/java/gregtech/common/tileentities/automation')
7 files changed, 282 insertions, 286 deletions
diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ChestBuffer.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ChestBuffer.java index f1641bda0b..1711529de2 100644 --- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ChestBuffer.java +++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ChestBuffer.java @@ -22,53 +22,53 @@ public class GT_MetaTileEntity_ChestBuffer extends GT_MetaTileEntity_Buffer impl public GT_MetaTileEntity_ChestBuffer(int aID, String aName, String aNameRegional, int aTier) { super( - aID, - aName, - aNameRegional, - aTier, - 28, - new String[] { "Buffers up to 27 Item Stacks", "Use Screwdriver to regulate output stack size", - "Does not consume energy to move Item", getTickRateDesc(aTier) }); + aID, + aName, + aNameRegional, + aTier, + 28, + new String[] { "Buffers up to 27 Item Stacks", "Use Screwdriver to regulate output stack size", + "Does not consume energy to move Item", getTickRateDesc(aTier) }); } public GT_MetaTileEntity_ChestBuffer(int aID, String aName, String aNameRegional, int aTier, int aInvSlotCount, - String aDescription) { + String aDescription) { super(aID, aName, aNameRegional, aTier, aInvSlotCount, aDescription); } public GT_MetaTileEntity_ChestBuffer(int aID, String aName, String aNameRegional, int aTier, int aInvSlotCount, - String[] aDescription) { + String[] aDescription) { super(aID, aName, aNameRegional, aTier, aInvSlotCount, aDescription); } public GT_MetaTileEntity_ChestBuffer(String aName, int aTier, int aInvSlotCount, String aDescription, - ITexture[][][] aTextures) { + ITexture[][][] aTextures) { super(aName, aTier, aInvSlotCount, aDescription, aTextures); } public GT_MetaTileEntity_ChestBuffer(String aName, int aTier, int aInvSlotCount, String[] aDescription, - ITexture[][][] aTextures) { + ITexture[][][] aTextures) { super(aName, aTier, aInvSlotCount, aDescription, aTextures); } @Override public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) { return new GT_MetaTileEntity_ChestBuffer( - this.mName, - this.mTier, - this.mInventory.length, - this.mDescriptionArray, - this.mTextures); + this.mName, + this.mTier, + this.mInventory.length, + this.mDescriptionArray, + this.mTextures); } @Override public ITexture getOverlayIcon() { return TextureFactory.of( - TextureFactory.of(AUTOMATION_CHESTBUFFER), - TextureFactory.builder() - .addIcon(AUTOMATION_CHESTBUFFER_GLOW) - .glow() - .build()); + TextureFactory.of(AUTOMATION_CHESTBUFFER), + TextureFactory.builder() + .addIcon(AUTOMATION_CHESTBUFFER_GLOW) + .glow() + .build()); } @Override @@ -125,9 +125,9 @@ public class GT_MetaTileEntity_ChestBuffer extends GT_MetaTileEntity_Buffer impl addInvertRedstoneButton(builder); addStockingModeButton(builder); builder.widget( - new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_22_RED.apply(69, true)) - .setPos(80, 60) - .setSize(69, 22)); + new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_22_RED.apply(69, true)) + .setPos(80, 60) + .setSize(69, 22)); addMainUI(builder); } diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Filter.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Filter.java index 6fc2b45289..c6c73cb02f 100644 --- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Filter.java +++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Filter.java @@ -28,43 +28,43 @@ public class GT_MetaTileEntity_Filter extends GT_MetaTileEntity_Buffer implement public GT_MetaTileEntity_Filter(int aID, String aName, String aNameRegional, int aTier) { super( - aID, - aName, - aNameRegional, - aTier, - 19, - new String[] { "Filters up to 9 different Items", "Use Screwdriver to regulate output stack size", - "Does not consume energy to move Item" }); + aID, + aName, + aNameRegional, + aTier, + 19, + new String[] { "Filters up to 9 different Items", "Use Screwdriver to regulate output stack size", + "Does not consume energy to move Item" }); } public GT_MetaTileEntity_Filter(String aName, int aTier, int aInvSlotCount, String aDescription, - ITexture[][][] aTextures) { + ITexture[][][] aTextures) { super(aName, aTier, aInvSlotCount, aDescription, aTextures); } public GT_MetaTileEntity_Filter(String aName, int aTier, int aInvSlotCount, String[] aDescription, - ITexture[][][] aTextures) { + ITexture[][][] aTextures) { super(aName, aTier, aInvSlotCount, aDescription, aTextures); } @Override public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) { return new GT_MetaTileEntity_Filter( - this.mName, - this.mTier, - this.mInventory.length, - this.mDescriptionArray, - this.mTextures); + this.mName, + this.mTier, + this.mInventory.length, + this.mDescriptionArray, + this.mTextures); } @Override public ITexture getOverlayIcon() { return TextureFactory.of( - TextureFactory.of(AUTOMATION_FILTER), - TextureFactory.builder() - .addIcon(AUTOMATION_FILTER_GLOW) - .glow() - .build()); + TextureFactory.of(AUTOMATION_FILTER), + TextureFactory.builder() + .addIcon(AUTOMATION_FILTER_GLOW) + .glow() + .build()); } @Override @@ -123,69 +123,67 @@ public class GT_MetaTileEntity_Filter extends GT_MetaTileEntity_Buffer implement bInvertFilter = !bInvertFilter; if (bInvertFilter) { GT_Utility.sendChatToPlayer( - widget.getContext() - .getPlayer(), - GT_Utility.trans("124", "Invert Filter")); + widget.getContext() + .getPlayer(), + GT_Utility.trans("124", "Invert Filter")); } else { GT_Utility.sendChatToPlayer( - widget.getContext() - .getPlayer(), - GT_Utility.trans("125", "Don't invert Filter")); + widget.getContext() + .getPlayer(), + GT_Utility.trans("125", "Don't invert Filter")); } }) - .setBackground( - GT_UITextures.BUTTON_STANDARD, - GT_UITextures.OVERLAY_BUTTON_INVERT_FILTER) - .setPos(61, 62) - .setSize(18, 18)) - .widget(new ButtonWidget().setOnClick((clickData, widget) -> { - bIgnoreNBT = !bIgnoreNBT; - if (bIgnoreNBT) { - GT_Utility.sendChatToPlayer( - widget.getContext() - .getPlayer(), - GT_Utility.trans("126", "Ignore NBT")); - } else { - GT_Utility.sendChatToPlayer( - widget.getContext() - .getPlayer(), - GT_Utility.trans("127", "NBT has to match")); - } - }) - .setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_NBT) - .setPos(79, 62) - .setSize(18, 18)) - .widget( - new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_24_WHITE.apply(9, false)) - .setPos(6, 19) - .setSize(9, 24)) - .widget( - new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_24_BLUE.apply(24, true)) - .setPos(71, 19) - .setSize(24, 24)) - .widget( - new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_24_RED.apply(19, true)) - .setPos(152, 19) - .setSize(19, 24)) - .widget( - new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SLOTS_HOLO_3BY3) - .setPos(16, 4) - .setSize(54, 54)) - .widget( - SlotGroup.ofItemHandler(inventoryHandler, 3) - .startFromSlot(9) - .endAtSlot(17) - .phantom(true) - .applyForWidget( - widget -> widget.disableShiftInsert() - .setBackground(GT_UITextures.TRANSPARENT)) - .build() - .setPos(16, 4)) - .widget( - SlotGroup.ofItemHandler(inventoryHandler, 3) - .startFromSlot(0) - .endAtSlot(8) - .build() - .setPos(97, 4)); + .setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_INVERT_FILTER) + .setPos(61, 62) + .setSize(18, 18)) + .widget(new ButtonWidget().setOnClick((clickData, widget) -> { + bIgnoreNBT = !bIgnoreNBT; + if (bIgnoreNBT) { + GT_Utility.sendChatToPlayer( + widget.getContext() + .getPlayer(), + GT_Utility.trans("126", "Ignore NBT")); + } else { + GT_Utility.sendChatToPlayer( + widget.getContext() + .getPlayer(), + GT_Utility.trans("127", "NBT has to match")); + } + }) + .setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_NBT) + .setPos(79, 62) + .setSize(18, 18)) + .widget( + new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_24_WHITE.apply(9, false)) + .setPos(6, 19) + .setSize(9, 24)) + .widget( + new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_24_BLUE.apply(24, true)) + .setPos(71, 19) + .setSize(24, 24)) + .widget( + new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_24_RED.apply(19, true)) + .setPos(152, 19) + .setSize(19, 24)) + .widget( + new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SLOTS_HOLO_3BY3) + .setPos(16, 4) + .setSize(54, 54)) + .widget( + SlotGroup.ofItemHandler(inventoryHandler, 3) + .startFromSlot(9) + .endAtSlot(17) + .phantom(true) + .applyForWidget( + widget -> widget.disableShiftInsert() + .setBackground(GT_UITextures.TRANSPARENT)) + .build() + .setPos(16, 4)) + .widget( + SlotGroup.ofItemHandler(inventoryHandler, 3) + .startFromSlot(0) + .endAtSlot(8) + .build() + .setPos(97, 4)); } } diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ItemDistributor.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ItemDistributor.java index 97bf8190b0..7b2978d701 100644 --- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ItemDistributor.java +++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ItemDistributor.java @@ -29,49 +29,48 @@ public class GT_MetaTileEntity_ItemDistributor extends GT_MetaTileEntity_Buffer public GT_MetaTileEntity_ItemDistributor(int aID, String aName, String aNameRegional, int aTier) { super( - aID, - aName, - aNameRegional, - aTier, - 28, - new String[] { "Distributes Items between different Machine Sides", "Default Items per Machine Side: 0", - "Use Screwdriver to increase/decrease Items per Side", - "Does not consume energy to move Item" }); + aID, + aName, + aNameRegional, + aTier, + 28, + new String[] { "Distributes Items between different Machine Sides", "Default Items per Machine Side: 0", + "Use Screwdriver to increase/decrease Items per Side", "Does not consume energy to move Item" }); } public GT_MetaTileEntity_ItemDistributor(int aID, String aName, String aNameRegional, int aTier, int aInvSlotCount, - String aDescription) { + String aDescription) { super(aID, aName, aNameRegional, aTier, aInvSlotCount, aDescription); } public GT_MetaTileEntity_ItemDistributor(String aName, int aTier, int aInvSlotCount, String aDescription, - ITexture[][][] aTextures) { + ITexture[][][] aTextures) { super(aName, aTier, aInvSlotCount, aDescription, aTextures); } public GT_MetaTileEntity_ItemDistributor(String aName, int aTier, int aInvSlotCount, String[] aDescription, - ITexture[][][] aTextures) { + ITexture[][][] aTextures) { super(aName, aTier, aInvSlotCount, aDescription, aTextures); } @Override public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) { return new GT_MetaTileEntity_ItemDistributor( - this.mName, - this.mTier, - this.mInventory.length, - this.mDescriptionArray, - this.mTextures); + this.mName, + this.mTier, + this.mInventory.length, + this.mDescriptionArray, + this.mTextures); } @Override public ITexture getOverlayIcon() { return TextureFactory.of( - TextureFactory.of(AUTOMATION_ITEMDISTRIBUTOR), - TextureFactory.builder() - .addIcon(AUTOMATION_ITEMDISTRIBUTOR_GLOW) - .glow() - .build()); + TextureFactory.of(AUTOMATION_ITEMDISTRIBUTOR), + TextureFactory.builder() + .addIcon(AUTOMATION_ITEMDISTRIBUTOR_GLOW) + .glow() + .build()); } @Override @@ -81,7 +80,7 @@ public class GT_MetaTileEntity_ItemDistributor extends GT_MetaTileEntity_Buffer @Override public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex, - boolean aActive, boolean aRedstone) { + boolean aActive, boolean aRedstone) { if (aSide == aFacing) { return mTextures[0][aColorIndex + 1]; } else { @@ -142,16 +141,16 @@ public class GT_MetaTileEntity_ItemDistributor extends GT_MetaTileEntity_Buffer } } movedItems = GT_Utility.moveOneItemStack( - aBaseMetaTileEntity, - adjacentTileEntity, - currentSide, - GT_Utility.getOppositeSide(currentSide), - null, - false, - (byte) 64, - (byte) 1, - (byte) (itemsPerSide[currentSide] - currentSideItemCount), - (byte) 1); + aBaseMetaTileEntity, + adjacentTileEntity, + currentSide, + GT_Utility.getOppositeSide(currentSide), + null, + false, + (byte) 64, + (byte) 1, + (byte) (itemsPerSide[currentSide] - currentSideItemCount), + (byte) 1); currentSideItemCount += movedItems; if (currentSideItemCount >= itemsPerSide[currentSide]) { currentSide = (byte) ((currentSide + 1) % 6); @@ -191,9 +190,9 @@ public class GT_MetaTileEntity_ItemDistributor extends GT_MetaTileEntity_Buffer addEmitRedstoneButton(builder); addInvertRedstoneButton(builder); builder.widget( - new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_22_RED.apply(87, true)) - .setPos(62, 60) - .setSize(87, 22)); + new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_22_RED.apply(87, true)) + .setPos(62, 60) + .setSize(87, 22)); addInventorySlots(builder); } } diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_RecipeFilter.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_RecipeFilter.java index 60500310e0..f8e54f9edf 100644 --- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_RecipeFilter.java +++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_RecipeFilter.java @@ -26,21 +26,21 @@ public class GT_MetaTileEntity_RecipeFilter extends GT_MetaTileEntity_SpecialFil public GT_MetaTileEntity_RecipeFilter(int aID, String aName, String aNameRegional, int aTier) { super( - aID, - aName, - aNameRegional, - aTier, - new String[] { "Filters 1 Recipe Type", "Use Screwdriver to regulate output stack size", - "Does not consume energy to move Item" }); + aID, + aName, + aNameRegional, + aTier, + new String[] { "Filters 1 Recipe Type", "Use Screwdriver to regulate output stack size", + "Does not consume energy to move Item" }); } public GT_MetaTileEntity_RecipeFilter(String aName, int aTier, int aInvSlotCount, String aDescription, - ITexture[][][] aTextures) { + ITexture[][][] aTextures) { super(aName, aTier, aInvSlotCount, aDescription, aTextures); } public GT_MetaTileEntity_RecipeFilter(String aName, int aTier, int aInvSlotCount, String[] aDescription, - ITexture[][][] aTextures) { + ITexture[][][] aTextures) { super(aName, aTier, aInvSlotCount, aDescription, aTextures); } @@ -64,21 +64,21 @@ public class GT_MetaTileEntity_RecipeFilter extends GT_MetaTileEntity_SpecialFil @Override public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) { return new GT_MetaTileEntity_RecipeFilter( - this.mName, - this.mTier, - this.mInventory.length, - this.mDescriptionArray, - this.mTextures); + this.mName, + this.mTier, + this.mInventory.length, + this.mDescriptionArray, + this.mTextures); } @Override public ITexture getOverlayIcon() { return TextureFactory.of( - TextureFactory.of(AUTOMATION_RECIPEFILTER), - TextureFactory.builder() - .addIcon(AUTOMATION_RECIPEFILTER_GLOW) - .glow() - .build()); + TextureFactory.of(AUTOMATION_RECIPEFILTER), + TextureFactory.builder() + .addIcon(AUTOMATION_RECIPEFILTER_GLOW) + .glow() + .build()); } @Override diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Regulator.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Regulator.java index e743dd47e4..9b0824aed1 100644 --- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Regulator.java +++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Regulator.java @@ -33,43 +33,43 @@ public class GT_MetaTileEntity_Regulator extends GT_MetaTileEntity_Buffer implem public GT_MetaTileEntity_Regulator(int aID, String aName, String aNameRegional, int aTier) { super( - aID, - aName, - aNameRegional, - aTier, - 20, - new String[] { "Filters up to 9 different Items", "Allows Item-specific output stack size", - "Allows Item-specific output slot", "Does not consume energy to move Item" }); + aID, + aName, + aNameRegional, + aTier, + 20, + new String[] { "Filters up to 9 different Items", "Allows Item-specific output stack size", + "Allows Item-specific output slot", "Does not consume energy to move Item" }); } public GT_MetaTileEntity_Regulator(String aName, int aTier, int aInvSlotCount, String aDescription, - ITexture[][][] aTextures) { + ITexture[][][] aTextures) { super(aName, aTier, aInvSlotCount, aDescription, aTextures); } public GT_MetaTileEntity_Regulator(String aName, int aTier, int aInvSlotCount, String[] aDescription, - ITexture[][][] aTextures) { + ITexture[][][] aTextures) { super(aName, aTier, aInvSlotCount, aDescription, aTextures); } @Override public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) { return new GT_MetaTileEntity_Regulator( - this.mName, - this.mTier, - this.mInventory.length, - this.mDescriptionArray, - this.mTextures); + this.mName, + this.mTier, + this.mInventory.length, + this.mDescriptionArray, + this.mTextures); } @Override public ITexture getOverlayIcon() { return TextureFactory.of( - TextureFactory.of(AUTOMATION_REGULATOR), - TextureFactory.builder() - .addIcon(AUTOMATION_REGULATOR_GLOW) - .glow() - .build()); + TextureFactory.of(AUTOMATION_REGULATOR), + TextureFactory.builder() + .addIcon(AUTOMATION_REGULATOR_GLOW) + .glow() + .build()); } @Override @@ -115,16 +115,16 @@ public class GT_MetaTileEntity_Regulator extends GT_MetaTileEntity_Buffer implem for (int i = 0, tCosts; i < 9; i++) { if (this.mInventory[(i + 9)] != null) { tCosts = GT_Utility.moveOneItemStackIntoSlot( - getBaseMetaTileEntity(), - getBaseMetaTileEntity().getTileEntityAtSide(getBaseMetaTileEntity().getBackFacing()), - getBaseMetaTileEntity().getBackFacing(), - this.mTargetSlots[i], - Collections.singletonList(this.mInventory[(i + 9)]), - false, - (byte) this.mInventory[(i + 9)].stackSize, - (byte) this.mInventory[(i + 9)].stackSize, - (byte) 64, - (byte) 1) * 3; + getBaseMetaTileEntity(), + getBaseMetaTileEntity().getTileEntityAtSide(getBaseMetaTileEntity().getBackFacing()), + getBaseMetaTileEntity().getBackFacing(), + this.mTargetSlots[i], + Collections.singletonList(this.mInventory[(i + 9)]), + false, + (byte) this.mInventory[(i + 9)].stackSize, + (byte) this.mInventory[(i + 9)].stackSize, + (byte) 64, + (byte) 1) * 3; if (tCosts > 0) { this.mSuccess = 50; break; @@ -136,8 +136,8 @@ public class GT_MetaTileEntity_Regulator extends GT_MetaTileEntity_Buffer implem @Override public boolean allowPutStack(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) { return super.allowPutStack(aBaseMetaTileEntity, aIndex, aSide, aStack) && aIndex >= 0 - && aIndex <= 8 - && GT_Utility.areStacksEqual(aStack, this.mInventory[(aIndex + 9)]); + && aIndex <= 8 + && GT_Utility.areStacksEqual(aStack, this.mInventory[(aIndex + 9)]); } @Override @@ -174,33 +174,33 @@ public class GT_MetaTileEntity_Regulator extends GT_MetaTileEntity_Buffer implem addEmitEnergyButton(builder); builder.widget(createChargerSlot(43, 62)); builder.widget( - new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_22_RED.apply(84, true)) - .setPos(65, 60) - .setSize(84, 22)) - .widget( - SlotGroup.ofItemHandler(inventoryHandler, 3) - .startFromSlot(0) - .endAtSlot(8) - .build() - .setPos(7, 5)) - .widget( - new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SLOTS_HOLO_3BY3) - .setPos(62, 5) - .setSize(54, 54)) - .widget( - SlotGroup.ofItemHandler(inventoryHandler, 3) - .phantom(true) - .startFromSlot(9) - .endAtSlot(17) - .applyForWidget( - widget -> widget.setControlsAmount(true) - .setBackground(GT_UITextures.TRANSPARENT)) - .build() - .setPos(62, 5)) - .widget( - new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SLOTS_HOLO_3BY3) - .setPos(117, 5) - .setSize(54, 54)); + new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_22_RED.apply(84, true)) + .setPos(65, 60) + .setSize(84, 22)) + .widget( + SlotGroup.ofItemHandler(inventoryHandler, 3) + .startFromSlot(0) + .endAtSlot(8) + .build() + .setPos(7, 5)) + .widget( + new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SLOTS_HOLO_3BY3) + .setPos(62, 5) + .setSize(54, 54)) + .widget( + SlotGroup.ofItemHandler(inventoryHandler, 3) + .phantom(true) + .startFromSlot(9) + .endAtSlot(17) + .applyForWidget( + widget -> widget.setControlsAmount(true) + .setBackground(GT_UITextures.TRANSPARENT)) + .build() + .setPos(62, 5)) + .widget( + new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SLOTS_HOLO_3BY3) + .setPos(117, 5) + .setSize(54, 54)); int xBase = 117, yBase = 5; for (int i = 0; i < mTargetSlots.length; i++) { @@ -211,18 +211,17 @@ public class GT_MetaTileEntity_Regulator extends GT_MetaTileEntity_Buffer implem @Override protected void phantomClick(ClickData clickData, ItemStack cursorStack) { mTargetSlots[index] = Math.min( - 99, - Math.max( - 0, - mTargetSlots[index] - + (clickData.mouseButton == 0 ? -1 : 1) * (clickData.shift ? 16 : 1))); + 99, + Math.max( + 0, + mTargetSlots[index] + (clickData.mouseButton == 0 ? -1 : 1) * (clickData.shift ? 16 : 1))); } }.setBackground(GT_UITextures.TRANSPARENT) - .setPos(xPos, yPos)) - .widget( - TextWidget.dynamicString(() -> String.valueOf(mTargetSlots[index])) - .setDefaultColor(COLOR_TEXT_WHITE.get()) - .setPos(xPos + 2 + (i % 3 == 0 ? 1 : 0), yPos + 3 + (i / 3 == 0 ? 1 : 0))); + .setPos(xPos, yPos)) + .widget( + TextWidget.dynamicString(() -> String.valueOf(mTargetSlots[index])) + .setDefaultColor(COLOR_TEXT_WHITE.get()) + .setPos(xPos + 2 + (i % 3 == 0 ? 1 : 0), yPos + 3 + (i / 3 == 0 ? 1 : 0))); } } } diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_SuperBuffer.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_SuperBuffer.java index 1b913af896..4687b62fa1 100644 --- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_SuperBuffer.java +++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_SuperBuffer.java @@ -24,43 +24,43 @@ public class GT_MetaTileEntity_SuperBuffer extends GT_MetaTileEntity_ChestBuffer public GT_MetaTileEntity_SuperBuffer(int aID, String aName, String aNameRegional, int aTier) { super( - aID, - aName, - aNameRegional, - aTier, - 257, - new String[] { "Buffers up to 256 Item Stacks", "Use Screwdriver to regulate output stack size", - "Does not consume energy to move Item", getTickRateDesc(aTier) }); + aID, + aName, + aNameRegional, + aTier, + 257, + new String[] { "Buffers up to 256 Item Stacks", "Use Screwdriver to regulate output stack size", + "Does not consume energy to move Item", getTickRateDesc(aTier) }); } public GT_MetaTileEntity_SuperBuffer(String aName, int aTier, int aInvSlotCount, String aDescription, - ITexture[][][] aTextures) { + ITexture[][][] aTextures) { super(aName, aTier, aInvSlotCount, aDescription, aTextures); } public GT_MetaTileEntity_SuperBuffer(String aName, int aTier, int aInvSlotCount, String[] aDescription, - ITexture[][][] aTextures) { + ITexture[][][] aTextures) { super(aName, aTier, aInvSlotCount, aDescription, aTextures); } @Override public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) { return new GT_MetaTileEntity_SuperBuffer( - this.mName, - this.mTier, - this.mInventory.length, - this.mDescriptionArray, - this.mTextures); + this.mName, + this.mTier, + this.mInventory.length, + this.mDescriptionArray, + this.mTextures); } @Override public ITexture getOverlayIcon() { return TextureFactory.of( - TextureFactory.of(AUTOMATION_SUPERBUFFER), - TextureFactory.builder() - .addIcon(AUTOMATION_SUPERBUFFER_GLOW) - .glow() - .build()); + TextureFactory.of(AUTOMATION_SUPERBUFFER), + TextureFactory.builder() + .addIcon(AUTOMATION_SUPERBUFFER_GLOW) + .glow() + .build()); } @Override @@ -86,7 +86,7 @@ public class GT_MetaTileEntity_SuperBuffer extends GT_MetaTileEntity_ChestBuffer do { int slot = validSlots.get(i); mInventory[slot] = stacks.get(entry.getKey()) - .copy(); + .copy(); int toSet = Math.min(entry.getValue(), mInventory[slot].getMaxStackSize()); mInventory[slot].stackSize = toSet; entry.setValue(entry.getValue() - toSet); @@ -98,8 +98,8 @@ public class GT_MetaTileEntity_SuperBuffer extends GT_MetaTileEntity_ChestBuffer @Override protected void addMainUI(ModularWindow.Builder builder) { builder.widget( - new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SUPER_BUFFER) - .setPos(61, 4) - .setSize(54, 54)); + new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SUPER_BUFFER) + .setPos(61, 4) + .setSize(54, 54)); } } diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_TypeFilter.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileE |
