Use qualified access

This commit is contained in:
yueh 2016-01-01 01:50:28 +01:00
parent 7134e851e4
commit 98234f9935
7 changed files with 48 additions and 48 deletions

View file

@ -53,12 +53,12 @@ public class BlockLightDetector extends AEBaseTileBlock implements IOrientableBl
{ {
super( Material.circuits ); super( Material.circuits );
setLightOpacity( 0 ); this.setLightOpacity( 0 );
setFullSize( false ); this.setFullSize( false );
setOpaque( false ); this.setOpaque( false );
setTileEntity( TileLightDetector.class ); this.setTileEntity( TileLightDetector.class );
setFeature( EnumSet.of( AEFeature.LightDetector ) ); this.setFeature( EnumSet.of( AEFeature.LightDetector ) );
} }
@Override @Override
@ -72,7 +72,7 @@ public class BlockLightDetector extends AEBaseTileBlock implements IOrientableBl
public IBlockState getStateFromMeta( public IBlockState getStateFromMeta(
final int meta ) final int meta )
{ {
return getDefaultState(); return this.getDefaultState();
} }
@Override @Override
@ -134,7 +134,7 @@ public class BlockLightDetector extends AEBaseTileBlock implements IOrientableBl
final EnumFacing forward, final EnumFacing forward,
final EnumFacing up ) final EnumFacing up )
{ {
return canPlaceAt( w, pos, up.getOpposite() ); return this.canPlaceAt( w, pos, up.getOpposite() );
} }
private boolean canPlaceAt( private boolean canPlaceAt(
@ -152,7 +152,7 @@ public class BlockLightDetector extends AEBaseTileBlock implements IOrientableBl
final Entity thePlayer, final Entity thePlayer,
final boolean b ) final boolean b )
{ {
final EnumFacing up = getOrientable( w, pos ).getUp(); final EnumFacing up = this.getOrientable( w, pos ).getUp();
final double xOff = -0.3 * up.getFrontOffsetX(); final double xOff = -0.3 * up.getFrontOffsetX();
final double yOff = -0.3 * up.getFrontOffsetY(); final double yOff = -0.3 * up.getFrontOffsetY();
final double zOff = -0.3 * up.getFrontOffsetZ(); final double zOff = -0.3 * up.getFrontOffsetZ();
@ -182,10 +182,10 @@ public class BlockLightDetector extends AEBaseTileBlock implements IOrientableBl
final IBlockState state, final IBlockState state,
final Block neighborBlock ) final Block neighborBlock )
{ {
final EnumFacing up = getOrientable( w, pos ).getUp(); final EnumFacing up = this.getOrientable( w, pos ).getUp();
if( !canPlaceAt( w, pos, up.getOpposite() ) ) if( !this.canPlaceAt( w, pos, up.getOpposite() ) )
{ {
dropTorch( w, pos ); this.dropTorch( w, pos );
} }
} }
@ -204,7 +204,7 @@ public class BlockLightDetector extends AEBaseTileBlock implements IOrientableBl
{ {
for( final EnumFacing dir : EnumFacing.VALUES ) for( final EnumFacing dir : EnumFacing.VALUES )
{ {
if( canPlaceAt( w, pos, dir ) ) if( this.canPlaceAt( w, pos, dir ) )
{ {
return true; return true;
} }

View file

@ -94,13 +94,13 @@ public class BlockCableBus extends AEBaseTileBlock // implements
public BlockCableBus() public BlockCableBus()
{ {
super( AEGlassMaterial.INSTANCE ); super( AEGlassMaterial.INSTANCE );
setLightOpacity( 0 ); this.setLightOpacity( 0 );
setFullSize( setOpaque( false ) ); this.setFullSize( this.setOpaque( false ) );
// this will actually be overwritten later through setupTile and the // this will actually be overwritten later through setupTile and the
// combined layers // combined layers
setTileEntity( TileCableBus.class ); this.setTileEntity( TileCableBus.class );
setFeature( EnumSet.of( AEFeature.Core ) ); this.setFeature( EnumSet.of( AEFeature.Core ) );
} }
@Override @Override
@ -110,7 +110,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
final IBlockState state, final IBlockState state,
final Random rand ) final Random rand )
{ {
cb( worldIn, pos ).randomDisplayTick( worldIn, pos, rand ); this.cb( worldIn, pos ).randomDisplayTick( worldIn, pos, rand );
} }
@Override @Override
@ -119,7 +119,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
final BlockPos pos, final BlockPos pos,
final BlockPos neighbor ) final BlockPos neighbor )
{ {
cb( w, pos ).onNeighborChanged(); this.cb( w, pos ).onNeighborChanged();
} }
@Override @Override
@ -138,7 +138,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
final IBlockState state, final IBlockState state,
final EnumFacing side ) final EnumFacing side )
{ {
return cb( w, pos ).isProvidingWeakPower( side.getOpposite() ); // TODO: return this.cb( w, pos ).isProvidingWeakPower( side.getOpposite() ); // TODO:
// IS // IS
// OPPOSITE!? // OPPOSITE!?
} }
@ -156,7 +156,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
final IBlockState state, final IBlockState state,
final Entity entityIn ) final Entity entityIn )
{ {
cb( w, pos ).onEntityCollision( entityIn ); this.cb( w, pos ).onEntityCollision( entityIn );
} }
@Override @Override
@ -166,7 +166,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
final IBlockState state, final IBlockState state,
final EnumFacing side ) final EnumFacing side )
{ {
return cb( w, pos ).isProvidingStrongPower( side.getOpposite() ); // TODO: return this.cb( w, pos ).isProvidingStrongPower( side.getOpposite() ); // TODO:
// IS // IS
// OPPOSITE!? // OPPOSITE!?
} }
@ -185,7 +185,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
{ {
return 0; return 0;
} }
return cb( world, pos ).getLightValue(); return this.cb( world, pos ).getLightValue();
} }
@Override @Override
@ -194,7 +194,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
final BlockPos pos, final BlockPos pos,
final EntityLivingBase entity ) final EntityLivingBase entity )
{ {
return cb( world, pos ).isLadder( entity ); return this.cb( world, pos ).isLadder( entity );
} }
@Override @Override
@ -203,7 +203,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
final BlockPos pos, final BlockPos pos,
final EnumFacing side ) final EnumFacing side )
{ {
return cb( w, pos ).isSolidOnSide( side ); return this.cb( w, pos ).isSolidOnSide( side );
} }
@Override @Override
@ -211,7 +211,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
final World w, final World w,
final BlockPos pos ) final BlockPos pos )
{ {
return cb( w, pos ).isEmpty(); return this.cb( w, pos ).isEmpty();
} }
@Override @Override
@ -244,7 +244,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
side = EnumFacing.UP; side = EnumFacing.UP;
} }
return cb( w, pos ).canConnectRedstone( EnumSet.of( side ) ); return this.cb( w, pos ).canConnectRedstone( EnumSet.of( side ) );
} }
@Override @Override
@ -266,7 +266,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
final BlockPos pos ) final BlockPos pos )
{ {
final Vec3 v3 = target.hitVec.subtract( pos.getX(), pos.getY(), pos.getZ() ); final Vec3 v3 = target.hitVec.subtract( pos.getX(), pos.getY(), pos.getZ() );
final SelectedPart sp = cb( world, pos ).selectPart( v3 ); final SelectedPart sp = this.cb( world, pos ).selectPart( v3 );
if( sp.part != null ) if( sp.part != null )
{ {
@ -287,7 +287,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
final MovingObjectPosition target, final MovingObjectPosition target,
final EffectRenderer effectRenderer ) final EffectRenderer effectRenderer )
{ {
final Object object = cb( world, target.getBlockPos() ); final Object object = this.cb( world, target.getBlockPos() );
if( object instanceof IPartHost ) if( object instanceof IPartHost )
{ {
final IPartHost host = (IPartHost) object; final IPartHost host = (IPartHost) object;
@ -321,7 +321,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
final BlockPos pos, final BlockPos pos,
final EffectRenderer effectRenderer ) final EffectRenderer effectRenderer )
{ {
final Object object = cb( world, pos ); final Object object = this.cb( world, pos );
if( object instanceof IPartHost ) if( object instanceof IPartHost )
{ {
final IPartHost host = (IPartHost) object; final IPartHost host = (IPartHost) object;
@ -353,7 +353,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
{ {
if( Platform.isServer() ) if( Platform.isServer() )
{ {
cb( w, pos ).onNeighborChanged(); this.cb( w, pos ).onNeighborChanged();
} }
} }
@ -392,7 +392,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
final float hitY, final float hitY,
final float hitZ ) final float hitZ )
{ {
return cb( w, pos ).activate( player, new Vec3( hitX, hitY, hitZ ) ); return this.cb( w, pos ).activate( player, new Vec3( hitX, hitY, hitZ ) );
} }
@Override @Override
@ -414,7 +414,7 @@ public class BlockCableBus extends AEBaseTileBlock // implements
{ {
try try
{ {
return cb( world, pos ).recolourBlock( side, AEColor.values()[color.ordinal()], who ); return this.cb( world, pos ).recolourBlock( side, AEColor.values()[color.ordinal()], who );
} }
catch( final Throwable ignored ) catch( final Throwable ignored )
{ {
@ -456,14 +456,14 @@ public class BlockCableBus extends AEBaseTileBlock // implements
protected void setFeature( protected void setFeature(
final EnumSet<AEFeature> f ) final EnumSet<AEFeature> f )
{ {
final AECableBusFeatureHandler featureHandler = new AECableBusFeatureHandler( f, this, getFeatureSubName() ); final AECableBusFeatureHandler featureHandler = new AECableBusFeatureHandler( f, this, this.getFeatureSubName() );
setHandler( featureHandler ); this.setHandler( featureHandler );
} }
public void setupTile() public void setupTile()
{ {
noTesrTile = Api.INSTANCE.partHelper().getCombinedInstance( TileCableBus.class.getName() ); noTesrTile = Api.INSTANCE.partHelper().getCombinedInstance( TileCableBus.class.getName() );
setTileEntity( noTesrTile ); this.setTileEntity( noTesrTile );
GameRegistry.registerTileEntity( noTesrTile, "BlockCableBus" ); GameRegistry.registerTileEntity( noTesrTile, "BlockCableBus" );
if( Platform.isClient() ) if( Platform.isClient() )
{ {

View file

@ -34,7 +34,7 @@ public class SmartModel implements IBakedModel, ISmartBlockModel, ISmartItemMode
public SmartModel( public SmartModel(
final BlockRenderInfo rendererInstance ) final BlockRenderInfo rendererInstance )
{ {
aeRenderer = rendererInstance; this.aeRenderer = rendererInstance;
} }
@Override @Override
@ -71,7 +71,7 @@ public class SmartModel implements IBakedModel, ISmartBlockModel, ISmartItemMode
@Override @Override
public TextureAtlasSprite getParticleTexture() public TextureAtlasSprite getParticleTexture()
{ {
return aeRenderer != null ? aeRenderer.getTexture( AEPartLocation.UP ).getAtlas() : MissingIcon.getMissing(); return this.aeRenderer != null ? this.aeRenderer.getTexture( AEPartLocation.UP ).getAtlas() : MissingIcon.getMissing();
} }
@Override @Override
@ -87,7 +87,7 @@ public class SmartModel implements IBakedModel, ISmartBlockModel, ISmartItemMode
final ModelGenerator helper = new ModelGenerator(); final ModelGenerator helper = new ModelGenerator();
final Block blk = Block.getBlockFromItem( stack.getItem() ); final Block blk = Block.getBlockFromItem( stack.getItem() );
helper.setRenderBoundsFromBlock( blk ); helper.setRenderBoundsFromBlock( blk );
aeRenderer.getRendererInstance().renderInventory( blk instanceof AEBaseBlock ? (AEBaseBlock) blk : null, stack, helper, ItemRenderType.INVENTORY, null ); this.aeRenderer.getRendererInstance().renderInventory( blk instanceof AEBaseBlock ? (AEBaseBlock) blk : null, stack, helper, ItemRenderType.INVENTORY, null );
helper.finalizeModel( true ); helper.finalizeModel( true );
return helper.getOutput(); return helper.getOutput();
} }
@ -103,7 +103,7 @@ public class SmartModel implements IBakedModel, ISmartBlockModel, ISmartItemMode
helper.setTranslation( -pos.getX(), -pos.getY(), -pos.getZ() ); helper.setTranslation( -pos.getX(), -pos.getY(), -pos.getZ() );
helper.setRenderBoundsFromBlock( blk ); helper.setRenderBoundsFromBlock( blk );
helper.setBlockAccess( world ); helper.setBlockAccess( world );
aeRenderer.getRendererInstance().renderInWorld( blk instanceof AEBaseBlock ? (AEBaseBlock) blk : null, world, pos, helper ); this.aeRenderer.getRendererInstance().renderInWorld( blk instanceof AEBaseBlock ? (AEBaseBlock) blk : null, world, pos, helper );
helper.finalizeModel( false ); helper.finalizeModel( false );
return helper.getOutput(); return helper.getOutput();
} }

View file

@ -28,13 +28,13 @@ public class BusRenderer
public ModelGenerator getRenderer() public ModelGenerator getRenderer()
{ {
return mg; return this.mg;
} }
public void setRenderer( public void setRenderer(
ModelGenerator renderer ) ModelGenerator renderer )
{ {
mg = renderer; this.mg = renderer;
} }
} }

View file

@ -214,10 +214,10 @@ public class LightningFX extends EntityFX
{ {
if( this.hasData ) if( this.hasData )
{ {
tess.color( red, green, blue, particleAlpha ).pos( a[0], a[1], a[2] ).tex( f6, f8 ).endVertex(); tess.color( red, green, blue, this.particleAlpha ).pos( a[0], a[1], a[2] ).tex( f6, f8 ).endVertex();
tess.color( red, green, blue, particleAlpha ).pos( this.vertices[0], this.vertices[1], this.vertices[2] ).tex( f6, f8 ).endVertex(); tess.color( red, green, blue, this.particleAlpha ).pos( this.vertices[0], this.vertices[1], this.vertices[2] ).tex( f6, f8 ).endVertex();
tess.color( red, green, blue, particleAlpha ).pos( this.verticesWithUV[0], this.verticesWithUV[1], this.verticesWithUV[2] ).tex( f6, f8 ).endVertex(); tess.color( red, green, blue, this.particleAlpha ).pos( this.verticesWithUV[0], this.verticesWithUV[1], this.verticesWithUV[2] ).tex( f6, f8 ).endVertex();
tess.color( red, green, blue, particleAlpha ).pos( b[0], b[1], b[2] ).tex( f6, f8 ).endVertex(); tess.color( red, green, blue, this.particleAlpha ).pos( b[0], b[1], b[2] ).tex( f6, f8 ).endVertex();
} }
this.hasData = true; this.hasData = true;
for( int x = 0; x < 3; x++ ) for( int x = 0; x < 3; x++ )

View file

@ -411,7 +411,7 @@ public class AEBaseTile extends TileEntity implements IOrientable, ICommonTile,
@Override @Override
public EnumFacing getForward() public EnumFacing getForward()
{ {
if( forward == null ) if( this.forward == null )
{ {
return EnumFacing.NORTH; return EnumFacing.NORTH;
} }
@ -421,7 +421,7 @@ public class AEBaseTile extends TileEntity implements IOrientable, ICommonTile,
@Override @Override
public EnumFacing getUp() public EnumFacing getUp()
{ {
if( up == null ) if( this.up == null )
{ {
return EnumFacing.UP; return EnumFacing.UP;
} }

View file

@ -51,7 +51,7 @@ public abstract class AENetworkInvTile extends AEBaseInvTile implements IActionH
@Override @Override
public AENetworkProxy getProxy() public AENetworkProxy getProxy()
{ {
return gridProxy; return this.gridProxy;
} }
@Override @Override