Simplified return condition
This commit is contained in:
parent
a80728de01
commit
bfc8fac0dd
1 changed files with 2 additions and 5 deletions
|
@ -58,11 +58,8 @@ public class BlockCrank extends AEBaseBlock
|
||||||
private boolean isCrankable(World w, int x, int y, int z, ForgeDirection offset)
|
private boolean isCrankable(World w, int x, int y, int z, ForgeDirection offset)
|
||||||
{
|
{
|
||||||
TileEntity te = w.getTileEntity( x + offset.offsetX, y + offset.offsetY, z + offset.offsetZ );
|
TileEntity te = w.getTileEntity( x + offset.offsetX, y + offset.offsetY, z + offset.offsetZ );
|
||||||
if ( te instanceof ICrankable )
|
|
||||||
{
|
return te instanceof ICrankable && ( ( ICrankable ) te ).canCrankAttach( offset.getOpposite() );
|
||||||
return ((ICrankable) te).canCrankAttach( offset.getOpposite() );
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private ForgeDirection findCrankable(World w, int x, int y, int z)
|
private ForgeDirection findCrankable(World w, int x, int y, int z)
|
||||||
|
|
Loading…
Reference in a new issue