Update GT_Cover_FluidRegulator.java

Improve the screwdriver-rightclick behavior.
This commit is contained in:
Antifluxfield 2017-08-17 14:51:45 +08:00 committed by GitHub
parent 9fc5d17eb5
commit 6691f1e86c

View file

@ -61,9 +61,9 @@ public class GT_Cover_FluidRegulator extends GT_CoverBehavior {
public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
EntityPlayer aPlayer, float aX, float aY, float aZ) { EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (GT_Utility.getClickedFacingCoords(aSide, aX, aY, aZ)[0] >= 0.5F) { if (GT_Utility.getClickedFacingCoords(aSide, aX, aY, aZ)[0] >= 0.5F) {
aCoverVariable += 16; aCoverVariable += aPlayer.isSneaking() ? 256 : 16;
} else { } else {
aCoverVariable -= 16; aCoverVariable -= aPlayer.isSneaking() ? 256 : 16;
} }
if (aCoverVariable > mTransferRate) { if (aCoverVariable > mTransferRate) {
aCoverVariable = mTransferRate; aCoverVariable = mTransferRate;