diff options
| author | GlodBlock <60341015+GlodBlock@users.noreply.github.com> | 2021-09-27 15:39:31 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-09-27 15:39:31 +0800 |
| commit | 097438be70486735a8940dd5ce4e9484b6d951af (patch) | |
| tree | 90f26b34d5059eb9858d9c82aabbd5373638acfa /src/main/java/gregtech/common/covers/GT_Cover_LiquidMeter.java | |
| parent | a0a77f0b9868a4ca8a3df8ae8d50b4dcfb4030db (diff) | |
| parent | 92433a5b85bb2fcca541ac25ca4033fac24f841e (diff) | |
| download | GT5-Unofficial-097438be70486735a8940dd5ce4e9484b6d951af.tar.gz GT5-Unofficial-097438be70486735a8940dd5ce4e9484b6d951af.tar.bz2 GT5-Unofficial-097438be70486735a8940dd5ce4e9484b6d951af.zip | |
Merge pull request #1 from GlodBlock/fix-crack-recipe-check
Fix crack recipe check
Diffstat (limited to 'src/main/java/gregtech/common/covers/GT_Cover_LiquidMeter.java')
| -rw-r--r-- | src/main/java/gregtech/common/covers/GT_Cover_LiquidMeter.java | 29 |
1 files changed, 22 insertions, 7 deletions
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_LiquidMeter.java b/src/main/java/gregtech/common/covers/GT_Cover_LiquidMeter.java index 9ca2f77d62..ed75bca967 100644 --- a/src/main/java/gregtech/common/covers/GT_Cover_LiquidMeter.java +++ b/src/main/java/gregtech/common/covers/GT_Cover_LiquidMeter.java @@ -16,8 +16,13 @@ import net.minecraftforge.fluids.FluidStack; import net.minecraftforge.fluids.FluidTankInfo; import net.minecraftforge.fluids.IFluidHandler; -public class GT_Cover_LiquidMeter - extends GT_CoverBehavior { +public class GT_Cover_LiquidMeter extends GT_CoverBehavior { + @Override + public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) { + return false; + } + + @Override public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) { if ((aTileEntity instanceof IFluidHandler)) { FluidTankInfo[] tTanks = ((IFluidHandler) aTileEntity).getTankInfo(ForgeDirection.UNKNOWN); @@ -46,6 +51,7 @@ public class GT_Cover_LiquidMeter return aCoverVariable; } + @Override public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) { if (aCoverVariable == 0) { GT_Utility.sendChatToPlayer(aPlayer, trans("055", "Normal")); @@ -55,34 +61,42 @@ public class GT_Cover_LiquidMeter return aCoverVariable == 0 ? 1 : 0; } + @Override public boolean letsEnergyIn(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) { return true; } + @Override public boolean letsEnergyOut(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) { return true; } + @Override public boolean letsFluidIn(byte aSide, int aCoverID, int aCoverVariable, Fluid aFluid, ICoverable aTileEntity) { return true; } + @Override public boolean letsFluidOut(byte aSide, int aCoverID, int aCoverVariable, Fluid aFluid, ICoverable aTileEntity) { return true; } + @Override public boolean letsItemsIn(byte aSide, int aCoverID, int aCoverVariable, int aSlot, ICoverable aTileEntity) { return true; } + @Override public boolean letsItemsOut(byte aSide, int aCoverID, int aCoverVariable, int aSlot, ICoverable aTileEntity) { return true; } + @Override public boolean manipulatesSidedRedstoneOutput(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) { return true; } + @Override public int getTickRate(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) { return 5; } @@ -105,10 +119,10 @@ public class GT_Cover_LiquidMeter private final int coverID; private int coverVariable; - private final static int startX = 10; - private final static int startY = 25; - private final static int spaceX = 18; - private final static int spaceY = 18; + private static final int startX = 10; + private static final int startY = 25; + private static final int spaceX = 18; + private static final int spaceY = 18; public GUI(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) { super(aTileEntity, 176, 107, GT_Utility.intToStack(aCoverID)); @@ -135,6 +149,7 @@ public class GT_Cover_LiquidMeter updateButtons(); } + @Override public void buttonClicked(GuiButton btn){ boolean state = false; if (btn.id == 0) @@ -164,4 +179,4 @@ public class GT_Cover_LiquidMeter return coverVariable; } } -}
\ No newline at end of file +} |
