diff --git a/src/main/java/appeng/client/gui/AEBaseGui.java b/src/main/java/appeng/client/gui/AEBaseGui.java index 7acbdacc..406a7507 100644 --- a/src/main/java/appeng/client/gui/AEBaseGui.java +++ b/src/main/java/appeng/client/gui/AEBaseGui.java @@ -335,7 +335,7 @@ public abstract class AEBaseGui extends GuiContainer return; } - if ( disableShiftClick == false && isShiftKeyDown() ) + if ( !disableShiftClick && isShiftKeyDown() ) { disableShiftClick = true; diff --git a/src/main/java/appeng/client/gui/implementations/GuiCraftConfirm.java b/src/main/java/appeng/client/gui/implementations/GuiCraftConfirm.java index e6a22df1..7a9befcf 100644 --- a/src/main/java/appeng/client/gui/implementations/GuiCraftConfirm.java +++ b/src/main/java/appeng/client/gui/implementations/GuiCraftConfirm.java @@ -307,8 +307,8 @@ public class GuiCraftConfirm extends AEBaseGui { updateCPUButtonText(); - start.enabled = ccc.noCPU || isSimulation() ? false : true; - selectCPU.enabled = isSimulation() ? false : true; + start.enabled = !(ccc.noCPU || isSimulation()); + selectCPU.enabled = !isSimulation(); int x = 0; int y = 0; diff --git a/src/main/java/appeng/client/render/BusRenderHelper.java b/src/main/java/appeng/client/render/BusRenderHelper.java index d00e8ede..45e04316 100644 --- a/src/main/java/appeng/client/render/BusRenderHelper.java +++ b/src/main/java/appeng/client/render/BusRenderHelper.java @@ -109,7 +109,7 @@ public class BusRenderHelper implements IPartRenderHelper int renderingForPass = 0; int currentPass = 0; int itemsRendered = 0; - final boolean noAlphaPass = AEConfig.instance.isFeatureEnabled( AEFeature.AlphaPass ) == false; + final boolean noAlphaPass = !AEConfig.instance.isFeatureEnabled( AEFeature.AlphaPass ); public int getItemsRendered() { diff --git a/src/main/java/appeng/client/render/items/ItemEncodedPatternRenderer.java b/src/main/java/appeng/client/render/items/ItemEncodedPatternRenderer.java index 3b066b80..f66935f8 100644 --- a/src/main/java/appeng/client/render/items/ItemEncodedPatternRenderer.java +++ b/src/main/java/appeng/client/render/items/ItemEncodedPatternRenderer.java @@ -22,7 +22,7 @@ public class ItemEncodedPatternRenderer implements IItemRenderer { boolean isShiftHeld = Keyboard.isKeyDown( Keyboard.KEY_LSHIFT ) || Keyboard.isKeyDown( Keyboard.KEY_RSHIFT ); - if ( recursive == false && type == IItemRenderer.ItemRenderType.INVENTORY && isShiftHeld ) + if ( !recursive && type == IItemRenderer.ItemRenderType.INVENTORY && isShiftHeld ) { ItemEncodedPattern iep = (ItemEncodedPattern) item.getItem(); if ( iep.getOutput( item ) != null ) diff --git a/src/main/java/appeng/container/implementations/ContainerCraftConfirm.java b/src/main/java/appeng/container/implementations/ContainerCraftConfirm.java index df975115..a40f2a5b 100644 --- a/src/main/java/appeng/container/implementations/ContainerCraftConfirm.java +++ b/src/main/java/appeng/container/implementations/ContainerCraftConfirm.java @@ -290,7 +290,7 @@ public class ContainerCraftConfirm extends AEBaseContainer if ( ah instanceof PartPatternTerminal ) OriginalGui = GuiBridge.GUI_PATTERN_TERMINAL; - if ( result != null && simulation == false ) + if ( result != null && !simulation ) { ICraftingGrid cc = getGrid().getCache( ICraftingGrid.class ); ICraftingLink g = cc.submitJob( result, null, selectedCpu == -1 ? null : cpus.get( selectedCpu ).cpu, true, getActionSrc() ); diff --git a/src/main/java/appeng/container/implementations/ContainerInscriber.java b/src/main/java/appeng/container/implementations/ContainerInscriber.java index 7618ecb0..c0e52879 100644 --- a/src/main/java/appeng/container/implementations/ContainerInscriber.java +++ b/src/main/java/appeng/container/implementations/ContainerInscriber.java @@ -107,7 +107,7 @@ public class ContainerInscriber extends ContainerUpgradeable implements IProgres } } - if ( matches && found == false ) + if ( matches && !found ) return false; } diff --git a/src/main/java/appeng/container/implementations/ContainerPatternTerm.java b/src/main/java/appeng/container/implementations/ContainerPatternTerm.java index 1c624e4a..59cdad2d 100644 --- a/src/main/java/appeng/container/implementations/ContainerPatternTerm.java +++ b/src/main/java/appeng/container/implementations/ContainerPatternTerm.java @@ -291,10 +291,11 @@ public class ContainerPatternTerm extends ContainerMEMonitorable implements IAEA public boolean isSlotEnabled(int idx) { if ( idx == 1 ) - return Platform.isServer() ? ct.isCraftingRecipe() == false : craftingMode == false; - if ( idx == 2 ) - return Platform.isServer() ? ct.isCraftingRecipe() == true : craftingMode == true; - return false; + return Platform.isServer() ? !ct.isCraftingRecipe() : !craftingMode; + else if ( idx == 2 ) + return Platform.isServer() ? ct.isCraftingRecipe() : craftingMode; + else + return false; } @Override diff --git a/src/main/java/appeng/crafting/CraftingLink.java b/src/main/java/appeng/crafting/CraftingLink.java index d0e385d9..2aca10bd 100644 --- a/src/main/java/appeng/crafting/CraftingLink.java +++ b/src/main/java/appeng/crafting/CraftingLink.java @@ -27,7 +27,7 @@ public class CraftingLink implements ICraftingLink done = data.getBoolean( "done" ); standalone = data.getBoolean( "standalone" ); - if ( !data.hasKey( "req" ) || data.getBoolean( "req" ) != true ) + if ( !data.hasKey( "req" ) || !data.getBoolean( "req" ) ) throw new RuntimeException( "Invalid Crafting Link for Object" ); this.req = req; @@ -40,7 +40,7 @@ public class CraftingLink implements ICraftingLink done = data.getBoolean( "done" ); standalone = data.getBoolean( "standalone" ); - if ( !data.hasKey( "req" ) || data.getBoolean( "req" ) == true ) + if ( !data.hasKey( "req" ) || data.getBoolean( "req" ) ) throw new RuntimeException( "Invalid Crafting Link for Object" ); this.cpu = cpu; diff --git a/src/main/java/appeng/entity/EntitySingularity.java b/src/main/java/appeng/entity/EntitySingularity.java index 28a3f5fc..2b0e9c57 100644 --- a/src/main/java/appeng/entity/EntitySingularity.java +++ b/src/main/java/appeng/entity/EntitySingularity.java @@ -73,7 +73,7 @@ final public class EntitySingularity extends EntityItem } // check... other name. - if ( matches == false ) + if ( !matches ) { for (ItemStack is : OreDictionary.getOres( "dustEnderPearl" )) { diff --git a/src/main/java/appeng/helpers/DualityInterface.java b/src/main/java/appeng/helpers/DualityInterface.java index 328f4406..e8d74be6 100644 --- a/src/main/java/appeng/helpers/DualityInterface.java +++ b/src/main/java/appeng/helpers/DualityInterface.java @@ -140,7 +140,7 @@ public class DualityInterface implements IGridTickable, IStorageMonitorable, IIn for (int x = 0; x < accountedFor.length; x++) { - if ( accountedFor[x] == false ) + if ( !accountedFor[x] ) addToCraftingList( patterns.getStackInSlot( x ) ); } diff --git a/src/main/java/appeng/helpers/MultiCraftingTracker.java b/src/main/java/appeng/helpers/MultiCraftingTracker.java index a2c4dd2b..e9f7a5ff 100644 --- a/src/main/java/appeng/helpers/MultiCraftingTracker.java +++ b/src/main/java/appeng/helpers/MultiCraftingTracker.java @@ -128,7 +128,7 @@ public class MultiCraftingTracker hasStuff = true; } - if ( hasStuff == false ) + if ( !hasStuff ) links = null; } @@ -156,7 +156,7 @@ public class MultiCraftingTracker } } - if ( hasStuff == false ) + if ( !hasStuff ) jobs = null; } diff --git a/src/main/java/appeng/helpers/PatternHelper.java b/src/main/java/appeng/helpers/PatternHelper.java index ea2f8465..0bebd863 100644 --- a/src/main/java/appeng/helpers/PatternHelper.java +++ b/src/main/java/appeng/helpers/PatternHelper.java @@ -212,7 +212,7 @@ public class PatternHelper implements ICraftingPatternDetails, Comparable 0 && somethingChanged == false ) + if ( remainingOperations > 0 && !somethingChanged ) waiting = true; } diff --git a/src/main/java/appeng/me/storage/MEMonitorIInventory.java b/src/main/java/appeng/me/storage/MEMonitorIInventory.java index 89b1834f..f879e293 100644 --- a/src/main/java/appeng/me/storage/MEMonitorIInventory.java +++ b/src/main/java/appeng/me/storage/MEMonitorIInventory.java @@ -175,7 +175,7 @@ public class MEMonitorIInventory implements IMEMonitor CachedItemStack old = memory.get( is.slot ); high = Math.max( high, is.slot ); - ItemStack newIS = is.isExtractable == false && mode == StorageFilter.EXTRACTABLE_ONLY ? null : is.getItemStack(); + ItemStack newIS = !is.isExtractable && mode == StorageFilter.EXTRACTABLE_ONLY ? null : is.getItemStack(); ItemStack oldIS = old == null ? null : old.itemStack; if ( isDifferent( newIS, oldIS ) ) diff --git a/src/main/java/appeng/parts/CableBusContainer.java b/src/main/java/appeng/parts/CableBusContainer.java index 334ad8d0..42bb1897 100644 --- a/src/main/java/appeng/parts/CableBusContainer.java +++ b/src/main/java/appeng/parts/CableBusContainer.java @@ -326,7 +326,7 @@ public class CableBusContainer extends CableBusStorage implements AEMultiTile, I public static boolean isLoading() { Boolean is = isLoading.get(); - return is != null && is == true; + return is != null && is; } public void addToWorld() diff --git a/src/main/java/appeng/parts/automation/PartFormationPlane.java b/src/main/java/appeng/parts/automation/PartFormationPlane.java index be214e18..8420a2a3 100644 --- a/src/main/java/appeng/parts/automation/PartFormationPlane.java +++ b/src/main/java/appeng/parts/automation/PartFormationPlane.java @@ -423,19 +423,19 @@ public class PartFormationPlane extends PartUpgradeable implements ICellContaine { boolean Worked = false; - if ( Worked == false && side.offsetX == 0 && side.offsetZ == 0 ) + if ( side.offsetX == 0 && side.offsetZ == 0 ) Worked = i.onItemUse( is, player, w, x + side.offsetX, y + side.offsetY, z + side.offsetZ, side.getOpposite().ordinal(), side.offsetX, side.offsetY, side.offsetZ ); - if ( Worked == false && side.offsetX == 0 && side.offsetZ == 0 ) + if ( !Worked && side.offsetX == 0 && side.offsetZ == 0 ) Worked = i.onItemUse( is, player, w, x - side.offsetX, y - side.offsetY, z - side.offsetZ, side.ordinal(), side.offsetX, side.offsetY, side.offsetZ ); - if ( Worked == false && side.offsetY == 0 ) + if ( !Worked && side.offsetY == 0 ) Worked = i.onItemUse( is, player, w, x, y - 1, z, ForgeDirection.UP.ordinal(), side.offsetX, side.offsetY, side.offsetZ ); - if ( Worked == false ) - Worked = i.onItemUse( is, player, w, x, y, z, side.getOpposite().ordinal(), side.offsetX, side.offsetY, side.offsetZ ); + if ( !Worked ) + i.onItemUse( is, player, w, x, y, z, side.getOpposite().ordinal(), side.offsetX, side.offsetY, side.offsetZ ); maxStorage = maxStorage - is.stackSize; } diff --git a/src/main/java/appeng/parts/networking/PartCable.java b/src/main/java/appeng/parts/networking/PartCable.java index 841f6f20..52a117f0 100644 --- a/src/main/java/appeng/parts/networking/PartCable.java +++ b/src/main/java/appeng/parts/networking/PartCable.java @@ -394,7 +394,6 @@ public class PartCable extends AEBasePart implements IPartCable bch.addBox( dist, 6.0, 6.0, 6.0, 10.0, 10.0 ); break; default: - continue; } } } @@ -423,7 +422,6 @@ public class PartCable extends AEBasePart implements IPartCable bch.addBox( 0.0, 6.0, 6.0, 6.0, 10.0, 10.0 ); break; default: - continue; } } } @@ -713,31 +711,28 @@ public class PartCable extends AEBasePart implements IPartCable } rh.renderBlock( x, y, z, renderer ); - if ( true ) + setSmartConnectionRotations( of, renderer ); + IIcon firstIcon = new TaughtIcon( getChannelTex( channels, false ).getIcon(), -0.2f ); + IIcon secondIcon = new TaughtIcon( getChannelTex( channels, true ).getIcon(), -0.2f ); + + if ( of == ForgeDirection.EAST || of == ForgeDirection.WEST ) { - setSmartConnectionRotations( of, renderer ); - IIcon firstIcon = new TaughtIcon( getChannelTex( channels, false ).getIcon(), -0.2f ); - IIcon secondIcon = new TaughtIcon( getChannelTex( channels, true ).getIcon(), -0.2f ); - - if ( of == ForgeDirection.EAST || of == ForgeDirection.WEST ) - { - AEBaseBlock blk = (AEBaseBlock) rh.getBlock(); - FlippableIcon ico = blk.getRendererInstance().getTexture( ForgeDirection.EAST ); - ico.setFlip( false, true ); - } - - Tessellator.instance.setBrightness( 15 << 20 | 15 << 4 ); - Tessellator.instance.setColorOpaque_I( myColor.blackVariant ); - rh.setTexture( firstIcon, firstIcon, firstIcon, firstIcon, firstIcon, firstIcon ); - renderAllFaces( (AEBaseBlock) rh.getBlock(), x, y, z, rh, renderer ); - - Tessellator.instance.setColorOpaque_I( myColor.whiteVariant ); - rh.setTexture( secondIcon, secondIcon, secondIcon, secondIcon, secondIcon, secondIcon ); - renderAllFaces( (AEBaseBlock) rh.getBlock(), x, y, z, rh, renderer ); - - renderer.uvRotateBottom = renderer.uvRotateEast = renderer.uvRotateNorth = renderer.uvRotateSouth = renderer.uvRotateTop = renderer.uvRotateWest = 0; + AEBaseBlock blk = (AEBaseBlock) rh.getBlock(); + FlippableIcon ico = blk.getRendererInstance().getTexture( ForgeDirection.EAST ); + ico.setFlip( false, true ); } + Tessellator.instance.setBrightness( 15 << 20 | 15 << 4 ); + Tessellator.instance.setColorOpaque_I( myColor.blackVariant ); + rh.setTexture( firstIcon, firstIcon, firstIcon, firstIcon, firstIcon, firstIcon ); + renderAllFaces( (AEBaseBlock) rh.getBlock(), x, y, z, rh, renderer ); + + Tessellator.instance.setColorOpaque_I( myColor.whiteVariant ); + rh.setTexture( secondIcon, secondIcon, secondIcon, secondIcon, secondIcon, secondIcon ); + renderAllFaces( (AEBaseBlock) rh.getBlock(), x, y, z, rh, renderer ); + + renderer.uvRotateBottom = renderer.uvRotateEast = renderer.uvRotateNorth = renderer.uvRotateSouth = renderer.uvRotateTop = renderer.uvRotateWest = 0; + rh.setTexture( getTexture( getCableColor() ) ); } @@ -965,7 +960,6 @@ public class PartCable extends AEBasePart implements IPartCable renderer.setRenderBounds( 6 / 16.0, 6 / 16.0, 0, 10 / 16.0, 10 / 16.0, 16 / 16.0 ); break; default: - continue; } } diff --git a/src/main/java/appeng/parts/networking/PartCableCovered.java b/src/main/java/appeng/parts/networking/PartCableCovered.java index 80678aec..85e0699b 100644 --- a/src/main/java/appeng/parts/networking/PartCableCovered.java +++ b/src/main/java/appeng/parts/networking/PartCableCovered.java @@ -97,7 +97,6 @@ public class PartCableCovered extends PartCable bch.addBox( 0.0, 5.0, 5.0, 5.0, 11.0, 11.0 ); break; default: - continue; } } } @@ -229,7 +228,6 @@ public class PartCableCovered extends PartCable renderer.setRenderBounds( 5 / 16.0, 5 / 16.0, 0, 11 / 16.0, 11 / 16.0, 16 / 16.0 ); break; default: - continue; } } diff --git a/src/main/java/appeng/parts/networking/PartCableSmart.java b/src/main/java/appeng/parts/networking/PartCableSmart.java index 0eca86ab..982e5788 100644 --- a/src/main/java/appeng/parts/networking/PartCableSmart.java +++ b/src/main/java/appeng/parts/networking/PartCableSmart.java @@ -151,7 +151,6 @@ public class PartCableSmart extends PartCable bch.addBox( 0.0, 5.0, 5.0, 5.0, 11.0, 11.0 ); break; default: - continue; } } } diff --git a/src/main/java/appeng/parts/networking/PartDenseCable.java b/src/main/java/appeng/parts/networking/PartDenseCable.java index 6e61431d..9fe8d1c9 100644 --- a/src/main/java/appeng/parts/networking/PartDenseCable.java +++ b/src/main/java/appeng/parts/networking/PartDenseCable.java @@ -169,7 +169,6 @@ public class PartDenseCable extends PartCable bch.addBox( 0.0, min, min, min, max, max ); break; default: - continue; } } else @@ -195,7 +194,6 @@ public class PartDenseCable extends PartCable bch.addBox( 0.0, 5.0, 5.0, 5.0, 11.0, 11.0 ); break; default: - continue; } } } diff --git a/src/main/java/appeng/parts/reporting/PartStorageMonitor.java b/src/main/java/appeng/parts/reporting/PartStorageMonitor.java index f6b94063..e282110f 100644 --- a/src/main/java/appeng/parts/reporting/PartStorageMonitor.java +++ b/src/main/java/appeng/parts/reporting/PartStorageMonitor.java @@ -79,7 +79,7 @@ public class PartStorageMonitor extends PartMonitor implements IPartStorageMonit data.writeByte( spin ); data.writeBoolean( isLocked ); - data.writeBoolean( configuredItem != null ? true : false ); + data.writeBoolean( configuredItem != null ); if ( configuredItem != null ) configuredItem.writeToPacket( data ); } diff --git a/src/main/java/appeng/spatial/CachedPlane.java b/src/main/java/appeng/spatial/CachedPlane.java index a0d8ae22..ad4cbc31 100644 --- a/src/main/java/appeng/spatial/CachedPlane.java +++ b/src/main/java/appeng/spatial/CachedPlane.java @@ -78,7 +78,7 @@ public class CachedPlane if ( reg.isBlacklisted( extendedblockstorage.getBlockByExtId( x, y & 15, z ) ) ) return false; - return skipThese == null ? true : !skipThese.contains( y ); + return skipThese == null || !skipThese.contains( y ); } public void setSkip(int yCoord) diff --git a/src/main/java/appeng/tile/AEBaseInvTile.java b/src/main/java/appeng/tile/AEBaseInvTile.java index ef40ce37..d8f9e2a8 100644 --- a/src/main/java/appeng/tile/AEBaseInvTile.java +++ b/src/main/java/appeng/tile/AEBaseInvTile.java @@ -92,7 +92,7 @@ public abstract class AEBaseInvTile extends AEBaseTile implements ISidedInventor @Override public boolean isUseableByPlayer(EntityPlayer p) { - return this.worldObj.getTileEntity( this.xCoord, this.yCoord, this.zCoord ) != this ? false : p.getDistanceSq( this.xCoord + 0.5D, + return this.worldObj.getTileEntity( this.xCoord, this.yCoord, this.zCoord ) == this && p.getDistanceSq( this.xCoord + 0.5D, this.yCoord + 0.5D, this.zCoord + 0.5D ) <= 32.0D; } diff --git a/src/main/java/appeng/tile/misc/TileCellWorkbench.java b/src/main/java/appeng/tile/misc/TileCellWorkbench.java index 3b4bf9dc..f423e634 100644 --- a/src/main/java/appeng/tile/misc/TileCellWorkbench.java +++ b/src/main/java/appeng/tile/misc/TileCellWorkbench.java @@ -118,7 +118,7 @@ public class TileCellWorkbench extends AEBaseTile implements IUpgradeableHost, I @Override public void onChangeInventory(IInventory inv, int slot, InvOperation mc, ItemStack removedStack, ItemStack newStack) { - if ( inv == cell && locked == false ) + if ( inv == cell && !locked ) { locked = true; @@ -161,7 +161,7 @@ public class TileCellWorkbench extends AEBaseTile implements IUpgradeableHost, I locked = false; } - else if ( inv == config && locked == false ) + else if ( inv == config && !locked ) { IInventory c = getCellConfigInventory(); if ( c != null ) diff --git a/src/main/java/appeng/tile/misc/TileInscriber.java b/src/main/java/appeng/tile/misc/TileInscriber.java index cf711535..48628479 100644 --- a/src/main/java/appeng/tile/misc/TileInscriber.java +++ b/src/main/java/appeng/tile/misc/TileInscriber.java @@ -317,7 +317,7 @@ public class TileInscriber extends AENetworkPowerTile implements IGridTickable, return true; processingTime = 0; - return false || smash; + return smash; } @Override diff --git a/src/main/java/appeng/tile/powersink/IC2.java b/src/main/java/appeng/tile/powersink/IC2.java index c50573ce..129a0e8b 100644 --- a/src/main/java/appeng/tile/powersink/IC2.java +++ b/src/main/java/appeng/tile/powersink/IC2.java @@ -22,7 +22,7 @@ public abstract class IC2 extends MinecraftJoules6 implements IEnergySink @Override final public boolean acceptsEnergyFrom(TileEntity emitter, ForgeDirection direction) { - return internalCanAcceptPower && getPowerSides().contains( direction ); + return getPowerSides().contains( direction ); } @Override diff --git a/src/main/java/appeng/tile/powersink/MinecraftJoules5.java b/src/main/java/appeng/tile/powersink/MinecraftJoules5.java index 13aa43cd..5677f182 100644 --- a/src/main/java/appeng/tile/powersink/MinecraftJoules5.java +++ b/src/main/java/appeng/tile/powersink/MinecraftJoules5.java @@ -57,7 +57,7 @@ public abstract class MinecraftJoules5 extends AERootPoweredTile implements IPow @Method(iname = "MJ5") final public PowerReceiver getPowerReceiver(ForgeDirection side) { - if ( internalCanAcceptPower && getPowerSides().contains( side ) && bcPowerWrapper != null ) + if ( getPowerSides().contains( side ) && bcPowerWrapper != null ) return bcPowerWrapper.getPowerReceiver(); return null; } diff --git a/src/main/java/appeng/tile/powersink/RedstoneFlux.java b/src/main/java/appeng/tile/powersink/RedstoneFlux.java index 943b9c37..c37155ad 100644 --- a/src/main/java/appeng/tile/powersink/RedstoneFlux.java +++ b/src/main/java/appeng/tile/powersink/RedstoneFlux.java @@ -48,7 +48,7 @@ public abstract class RedstoneFlux extends RotaryCraft implements IEnergyHandler @Override final public boolean canConnectEnergy(ForgeDirection from) { - return internalCanAcceptPower && getPowerSides().contains( from ); + return getPowerSides().contains( from ); } @Override diff --git a/src/main/java/appeng/tile/powersink/RotaryCraft.java b/src/main/java/appeng/tile/powersink/RotaryCraft.java index 8b100152..3eb61625 100644 --- a/src/main/java/appeng/tile/powersink/RotaryCraft.java +++ b/src/main/java/appeng/tile/powersink/RotaryCraft.java @@ -119,7 +119,7 @@ public abstract class RotaryCraft extends IC2 implements ShaftPowerReceiver else if ( y == yCoord + 1 ) side = ForgeDirection.UP; - return internalCanAcceptPower && getPowerSides().contains( side ); + return getPowerSides().contains( side ); } @Override @@ -139,7 +139,7 @@ public abstract class RotaryCraft extends IC2 implements ShaftPowerReceiver @Override final public boolean canReadFrom(ForgeDirection side) { - return internalCanAcceptPower && getPowerSides().contains( side ); + return getPowerSides().contains( side ); } @Override diff --git a/src/main/java/appeng/tile/spatial/TileSpatialIOPort.java b/src/main/java/appeng/tile/spatial/TileSpatialIOPort.java index 3a267ab4..2d83f1b2 100644 --- a/src/main/java/appeng/tile/spatial/TileSpatialIOPort.java +++ b/src/main/java/appeng/tile/spatial/TileSpatialIOPort.java @@ -141,7 +141,7 @@ public class TileSpatialIOPort extends AENetworkInvTile implements Callable @Override public boolean isItemValidForSlot(int i, ItemStack itemstack) { - return (i == 0 ? isSpatialCell( itemstack ) : false); + return (i == 0 && isSpatialCell( itemstack )); } private boolean isSpatialCell(ItemStack cell) diff --git a/src/main/java/appeng/util/Platform.java b/src/main/java/appeng/util/Platform.java index a9f2f734..9c3ef637 100644 --- a/src/main/java/appeng/util/Platform.java +++ b/src/main/java/appeng/util/Platform.java @@ -1267,7 +1267,7 @@ public class Platform { Entity entity1 = (Entity) list.get( l ); - if ( entity1.isDead == false && entity1 != p && !(entity1 instanceof EntityItem) ) + if ( !entity1.isDead && entity1 != p && !(entity1 instanceof EntityItem) ) { if ( entity1.isEntityAlive() ) {