aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/gregtech/api/util/GT_CoverBehaviorBase.java
diff options
context:
space:
mode:
authorRaven Szewczyk <git@eigenraven.me>2022-08-27 10:19:57 +0100
committerGitHub <noreply@github.com>2022-08-27 11:19:57 +0200
commit6f31720697bcc351421a4d86ba3bf749375dd12c (patch)
tree3adf8f318f22c892d74cd7c9d30b6dd3f11f11bd /src/main/java/gregtech/api/util/GT_CoverBehaviorBase.java
parentc3eac50decd33ee2be8703dfb2ecf9cdc31c2b67 (diff)
downloadGT5-Unofficial-6f31720697bcc351421a4d86ba3bf749375dd12c.tar.gz
GT5-Unofficial-6f31720697bcc351421a4d86ba3bf749375dd12c.tar.bz2
GT5-Unofficial-6f31720697bcc351421a4d86ba3bf749375dd12c.zip
Update buildscript & apply spotless (#1306)
* Update dependencies * Update buildscript, apply spotless
Diffstat (limited to 'src/main/java/gregtech/api/util/GT_CoverBehaviorBase.java')
-rw-r--r--src/main/java/gregtech/api/util/GT_CoverBehaviorBase.java196
1 files changed, 139 insertions, 57 deletions
diff --git a/src/main/java/gregtech/api/util/GT_CoverBehaviorBase.java b/src/main/java/gregtech/api/util/GT_CoverBehaviorBase.java
index 1c72f9c9d9..470a250ee7 100644
--- a/src/main/java/gregtech/api/util/GT_CoverBehaviorBase.java
+++ b/src/main/java/gregtech/api/util/GT_CoverBehaviorBase.java
@@ -1,5 +1,7 @@
package gregtech.api.util;
+import static gregtech.api.enums.GT_Values.E;
+
import gregtech.api.enums.GT_Values;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
@@ -14,8 +16,6 @@ import net.minecraft.nbt.NBTTagInt;
import net.minecraft.world.World;
import net.minecraftforge.fluids.Fluid;
-import static gregtech.api.enums.GT_Values.E;
-
/**
* For Covers with a special behavior.
*
@@ -46,8 +46,7 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
}
public final T cast(ISerializableObject aData) {
- if (typeToken.isInstance(aData))
- return forceCast(aData);
+ if (typeToken.isInstance(aData)) return forceCast(aData);
return null;
}
@@ -66,7 +65,8 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* in case of CTM
* @return null if none, otherwise return facade target block
*/
- public final Block getFacadeBlock(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final Block getFacadeBlock(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return getFacadeBlockImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
@@ -75,7 +75,8 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* in case of CTM
* @return 0 if none, otherwise return facade target meta
*/
- public final int getFacadeMeta(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final int getFacadeMeta(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return getFacadeMetaImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
@@ -83,14 +84,15 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* Get the display stack. Default to {@code int2Stack(aCoverID)}
*/
public final ItemStack getDisplayStack(int aCoverID, ISerializableObject aCoverVariable) {
- return getDisplayStackImpl(aCoverID,forceCast(aCoverVariable));
+ return getDisplayStackImpl(aCoverID, forceCast(aCoverVariable));
}
/**
* Get the special cover texture associated with this cover. Return null if one should use the texture passed to
* {@link gregtech.api.GregTech_API#registerCover(ItemStack, ITexture, GT_CoverBehaviorBase)} or its overloads.
*/
- public final ITexture getSpecialCoverTexture(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final ITexture getSpecialCoverTexture(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return getSpecialCoverTextureImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
@@ -100,14 +102,16 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* Note if you want to sync the data afterwards you will have to manually do it by calling {@link ICoverable#issueCoverUpdate(byte)}
* This option only affects the initial sync.
*/
- public final boolean isDataNeededOnClient(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final boolean isDataNeededOnClient(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return isDataNeededOnClientImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
/**
* Called upon receiving data from network. Use {@link ICoverable#isClientSide()} to determine the side.
*/
- public final void onDataChanged(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final void onDataChanged(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
onDataChangedImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
@@ -118,14 +122,21 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
onDroppedImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
- public final boolean isRedstoneSensitive(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public final boolean isRedstoneSensitive(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity, long aTimer) {
return isRedstoneSensitiveImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity, aTimer);
}
/**
* Called by updateEntity inside the covered TileEntity. aCoverVariable is the Value you returned last time.
*/
- public final T doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public final T doCoverThings(
+ byte aSide,
+ byte aInputRedstone,
+ int aCoverID,
+ ISerializableObject aCoverVariable,
+ ICoverable aTileEntity,
+ long aTimer) {
return doCoverThingsImpl(aSide, aInputRedstone, aCoverID, forceCast(aCoverVariable), aTileEntity, aTimer);
}
@@ -134,7 +145,15 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* <p/>
* return true, if something actually happens.
*/
- public final boolean onCoverRightClick(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
+ public final boolean onCoverRightClick(
+ byte aSide,
+ int aCoverID,
+ ISerializableObject aCoverVariable,
+ ICoverable aTileEntity,
+ EntityPlayer aPlayer,
+ float aX,
+ float aY,
+ float aZ) {
return onCoverRightClickImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity, aPlayer, aX, aY, aZ);
}
@@ -143,18 +162,38 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* <p/>
* return the new Value of the Cover Variable
*/
- public final T onCoverScrewdriverClick(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
- return onCoverScrewdriverClickImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity, aPlayer, aX, aY, aZ);
+ public final T onCoverScrewdriverClick(
+ byte aSide,
+ int aCoverID,
+ ISerializableObject aCoverVariable,
+ ICoverable aTileEntity,
+ EntityPlayer aPlayer,
+ float aX,
+ float aY,
+ float aZ) {
+ return onCoverScrewdriverClickImpl(
+ aSide, aCoverID, forceCast(aCoverVariable), aTileEntity, aPlayer, aX, aY, aZ);
}
/**
* Called when someone shift-rightclicks this Cover with no tool. Doesn't call @onCoverRightclick in this Case.
*/
- public final boolean onCoverShiftRightClick(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer) {
+ public final boolean onCoverShiftRightClick(
+ byte aSide,
+ int aCoverID,
+ ISerializableObject aCoverVariable,
+ ICoverable aTileEntity,
+ EntityPlayer aPlayer) {
return onCoverShiftRightClickImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity, aPlayer);
}
- public final Object getClientGUI(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer, World aWorld) {
+ public final Object getClientGUI(
+ byte aSide,
+ int aCoverID,
+ ISerializableObject aCoverVariable,
+ ICoverable aTileEntity,
+ EntityPlayer aPlayer,
+ World aWorld) {
return getClientGUIImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity, aPlayer, aWorld);
}
@@ -162,21 +201,24 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* Removes the Cover if this returns true, or if aForced is true.
* Doesn't get called when the Machine Block is getting broken, only if you break the Cover away from the Machine.
*/
- public final boolean onCoverRemoval(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity, boolean aForced) {
+ public final boolean onCoverRemoval(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity, boolean aForced) {
return onCoverRemovalImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity, aForced);
}
/**
* Gives a small Text for the status of the Cover.
*/
- public final String getDescription(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final String getDescription(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return getDescriptionImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
/**
* How Blast Proof the Cover is. 30 is normal.
*/
- public final float getBlastProofLevel(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final float getBlastProofLevel(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return getBlastProofLevelImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
@@ -185,14 +227,16 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* <p/>
* This is just Informative so that Machines know if their Redstone Input is blocked or not
*/
- public final boolean letsRedstoneGoIn(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final boolean letsRedstoneGoIn(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return letsRedstoneGoInImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
/**
* If it lets RS-Signals out of the Block
*/
- public final boolean letsRedstoneGoOut(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final boolean letsRedstoneGoOut(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return letsRedstoneGoOutImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
@@ -201,77 +245,88 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* <p/>
* This is just Informative so that Machines know if their Redstone Input is blocked or not
*/
- public final boolean letsFibreGoIn(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final boolean letsFibreGoIn(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return letsFibreGoInImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
/**
* If it lets Fibre-Signals out of the Block
*/
- public final boolean letsFibreGoOut(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final boolean letsFibreGoOut(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return letsFibreGoOutImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
/**
* If it lets Energy into the Block
*/
- public final boolean letsEnergyIn(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final boolean letsEnergyIn(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return letsEnergyInImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
/**
* If it lets Energy out of the Block
*/
- public final boolean letsEnergyOut(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final boolean letsEnergyOut(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return letsEnergyOutImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
/**
* If it lets Liquids into the Block, aFluid can be null meaning if this is generally allowing Fluids or not.
*/
- public final boolean letsFluidIn(byte aSide, int aCoverID, ISerializableObject aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ public final boolean letsFluidIn(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
return letsFluidInImpl(aSide, aCoverID, forceCast(aCoverVariable), aFluid, aTileEntity);
}
/**
* If it lets Liquids out of the Block, aFluid can be null meaning if this is generally allowing Fluids or not.
*/
- public final boolean letsFluidOut(byte aSide, int aCoverID, ISerializableObject aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ public final boolean letsFluidOut(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
return letsFluidOutImpl(aSide, aCoverID, forceCast(aCoverVariable), aFluid, aTileEntity);
}
/**
* If it lets Items into the Block, aSlot = -1 means if it is generally accepting Items (return false for no reaction at all), aSlot = -2 means if it would accept for all Slots Impl(return true to skip the Checks for each Slot).
*/
- public final boolean letsItemsIn(byte aSide, int aCoverID, ISerializableObject aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ public final boolean letsItemsIn(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, int aSlot, ICoverable aTileEntity) {
return letsItemsInImpl(aSide, aCoverID, forceCast(aCoverVariable), aSlot, aTileEntity);
}
/**
* If it lets Items out of the Block, aSlot = -1 means if it is generally accepting Items (return false for no reaction at all), aSlot = -2 means if it would accept for all Slots Impl(return true to skip the Checks for each Slot).
*/
- public final boolean letsItemsOut(byte aSide, int aCoverID, ISerializableObject aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ public final boolean letsItemsOut(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, int aSlot, ICoverable aTileEntity) {
return letsItemsOutImpl(aSide, aCoverID, forceCast(aCoverVariable), aSlot, aTileEntity);
}
/**
* If it lets you rightclick the Machine normally
*/
- public final boolean isGUIClickable(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final boolean isGUIClickable(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return isGUIClickableImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
/**
* Needs to return true for Covers, which have a Redstone Output on their Facing.
*/
- public final boolean manipulatesSidedRedstoneOutput(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final boolean manipulatesSidedRedstoneOutput(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return manipulatesSidedRedstoneOutputImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
/**
* if this Cover should let Pipe Connections look connected even if it is not the case.
*/
- public final boolean alwaysLookConnected(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final boolean alwaysLookConnected(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return alwaysLookConnectedImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
@@ -280,7 +335,8 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* Returns the original Redstone per default.
* The Cover should @letsRedstoneGoIn or the aInputRedstone Parameter is always 0.
*/
- public final byte getRedstoneInput(byte aSide, byte aInputRedstone, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final byte getRedstoneInput(
+ byte aSide, byte aInputRedstone, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return getRedstoneInputImpl(aSide, aInputRedstone, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
@@ -293,18 +349,19 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
return getTickRateImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
-
/**
* The MC Color of this Lens. -1 for no Color (meaning this isn't a Lens then).
*/
- public final byte getLensColor(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final byte getLensColor(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return getLensColorImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
/**
* @return the ItemStack dropped by this Cover
*/
- public final ItemStack getDrop(byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
+ public final ItemStack getDrop(
+ byte aSide, int aCoverID, ISerializableObject aCoverVariable, ICoverable aTileEntity) {
return getDropImpl(aSide, aCoverID, forceCast(aCoverVariable), aTileEntity);
}
// endregion
@@ -331,21 +388,20 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
return false;
}
- protected void onDataChangedImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity) {
- }
-
+ protected void onDataChangedImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity) {}
- protected void onDroppedImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity) {
- }
+ protected void onDroppedImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity) {}
- protected boolean isRedstoneSensitiveImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ protected boolean isRedstoneSensitiveImpl(
+ byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity, long aTimer) {
return true;
}
/**
* Called by updateEntity inside the covered TileEntity. aCoverVariable is the Value you returned last time.
*/
- protected T doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID, T aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ protected T doCoverThingsImpl(
+ byte aSide, byte aInputRedstone, int aCoverID, T aCoverVariable, ICoverable aTileEntity, long aTimer) {
return aCoverVariable;
}
@@ -354,7 +410,15 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* <p/>
* return true, if something actually happens.
*/
- protected boolean onCoverRightClickImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
+ protected boolean onCoverRightClickImpl(
+ byte aSide,
+ int aCoverID,
+ T aCoverVariable,
+ ICoverable aTileEntity,
+ EntityPlayer aPlayer,
+ float aX,
+ float aY,
+ float aZ) {
return false;
}
@@ -363,23 +427,36 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* <p/>
* return the new Value of the Cover Variable
*/
- protected T onCoverScrewdriverClickImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
+ protected T onCoverScrewdriverClickImpl(
+ byte aSide,
+ int aCoverID,
+ T aCoverVariable,
+ ICoverable aTileEntity,
+ EntityPlayer aPlayer,
+ float aX,
+ float aY,
+ float aZ) {
return aCoverVariable;
}
/**
* Called when someone shift-rightclicks this Cover with no tool. Doesn't call @onCoverRightclick in this Case.
*/
- protected boolean onCoverShiftRightClickImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer) {
+ protected boolean onCoverShiftRightClickImpl(
+ byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer) {
if (hasCoverGUI() && aPlayer instanceof EntityPlayerMP) {
lastPlayer = aPlayer;
- GT_Values.NW.sendToPlayer(new GT_Packet_TileEntityCoverGUI(aSide, aCoverID, aCoverVariable, aTileEntity, (EntityPlayerMP) aPlayer), (EntityPlayerMP) aPlayer);
+ GT_Values.NW.sendToPlayer(
+ new GT_Packet_TileEntityCoverGUI(
+ aSide, aCoverID, aCoverVariable, aTileEntity, (EntityPlayerMP) aPlayer),
+ (EntityPlayerMP) aPlayer);
return true;
}
return false;
}
- protected Object getClientGUIImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer, World aWorld) {
+ protected Object getClientGUIImpl(
+ byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer, World aWorld) {
return null;
}
@@ -387,7 +464,8 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* Removes the Cover if this returns true, or if aForced is true.
* Doesn't get called when the Machine Block is getting broken, only if you break the Cover away from the Machine.
*/
- protected boolean onCoverRemovalImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity, boolean aForced) {
+ protected boolean onCoverRemovalImpl(
+ byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity, boolean aForced) {
return true;
}
@@ -454,14 +532,16 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
/**
* If it lets Liquids into the Block, aFluid can be null meaning if this is generally allowing Fluids or not.
*/
- protected boolean letsFluidInImpl(byte aSide, int aCoverID, T aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidInImpl(
+ byte aSide, int aCoverID, T aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
return false;
}
/**
* If it lets Liquids out of the Block, aFluid can be null meaning if this is generally allowing Fluids or not.
*/
- protected boolean letsFluidOutImpl(byte aSide, int aCoverID, T aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidOutImpl(
+ byte aSide, int aCoverID, T aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
return false;
}
@@ -489,7 +569,8 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
/**
* Needs to return true for Covers, which have a Redstone Output on their Facing.
*/
- protected boolean manipulatesSidedRedstoneOutputImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity) {
+ protected boolean manipulatesSidedRedstoneOutputImpl(
+ byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity) {
return false;
}
@@ -505,7 +586,8 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* Returns the original Redstone per default.
* The Cover should @letsRedstoneGoIn or the aInputRedstone Parameter is always 0.
*/
- protected byte getRedstoneInputImpl(byte aSide, byte aInputRedstone, int aCoverID, T aCoverVariable, ICoverable aTileEntity) {
+ protected byte getRedstoneInputImpl(
+ byte aSide, byte aInputRedstone, int aCoverID, T aCoverVariable, ICoverable aTileEntity) {
return letsRedstoneGoIn(aSide, aCoverID, aCoverVariable, aTileEntity) ? aInputRedstone : 0;
}
@@ -518,7 +600,6 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
return 0;
}
-
/**
* The MC Color of this Lens. -1 for no Color (meaning this isn't a Lens then).
*/
@@ -533,7 +614,7 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
return GT_OreDictUnificator.get(true, aTileEntity.getCoverItemAtSide(aSide));
}
- //endregion
+ // endregion
// region no data
@@ -561,7 +642,8 @@ public abstract class GT_CoverBehaviorBase<T extends ISerializableObject> {
* <p/>
* return true, if something actually happens.
*/
- public boolean onCoverRightclickClient(byte aSide, ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
+ public boolean onCoverRightclickClient(
+ byte aSide, ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
return false;
}