Reduce scope of variables
This commit is contained in:
@@ -160,7 +160,6 @@ public class ItemSpatialStorageCell extends AEBaseItem implements ISpatialStorag
|
||||
int targetZ = max.z - min.z - 1;
|
||||
int maxSize = this.getMaxStoredDim( is );
|
||||
|
||||
int floorBuffer = 64;
|
||||
World destination = this.getWorld( is );
|
||||
|
||||
if( ( scale.x == 0 && scale.y == 0 && scale.z == 0 ) || ( scale.x == targetX && scale.y == targetY && scale.z == targetZ ) )
|
||||
@@ -172,6 +171,7 @@ public class ItemSpatialStorageCell extends AEBaseItem implements ISpatialStorag
|
||||
destination = this.createNewWorld( is );
|
||||
}
|
||||
|
||||
int floorBuffer = 64;
|
||||
StorageHelper.getInstance().swapRegions( w, destination, min.x + 1, min.y + 1, min.z + 1, 1, floorBuffer + 1, 1, targetX - 1, targetY - 1, targetZ - 1 );
|
||||
this.setStoredSize( is, targetX, targetY, targetZ );
|
||||
|
||||
|
||||
@@ -119,7 +119,6 @@ public class ToolColorApplicator extends AEBasePoweredItem implements IStorageCe
|
||||
public boolean onItemUse( ItemStack is, EntityPlayer p, World w, int x, int y, int z, int side, float hitX, float hitY, float hitZ )
|
||||
{
|
||||
Block blk = w.getBlock( x, y, z );
|
||||
double powerPerUse = 100;
|
||||
|
||||
ItemStack paintBall = this.getColor( is );
|
||||
|
||||
@@ -143,6 +142,7 @@ public class ToolColorApplicator extends AEBasePoweredItem implements IStorageCe
|
||||
return false;
|
||||
}
|
||||
|
||||
double powerPerUse = 100;
|
||||
if( paintBall != null && paintBall.getItem() instanceof ItemSnowball )
|
||||
{
|
||||
ForgeDirection orientation = ForgeDirection.getOrientation( side );
|
||||
|
||||
@@ -211,9 +211,8 @@ public class ToolMassCannon extends AEBasePoweredItem implements IStorageCell
|
||||
Entity entity = null;
|
||||
List list = w.getEntitiesWithinAABBExcludingEntity( p, bb );
|
||||
double closest = 9999999.0D;
|
||||
int l;
|
||||
|
||||
for( l = 0; l < list.size(); ++l )
|
||||
for( int l = 0; l < list.size(); ++l )
|
||||
{
|
||||
Entity entity1 = (Entity) list.get( l );
|
||||
|
||||
@@ -335,9 +334,8 @@ public class ToolMassCannon extends AEBasePoweredItem implements IStorageCell
|
||||
Entity entity = null;
|
||||
List list = w.getEntitiesWithinAABBExcludingEntity( p, bb );
|
||||
double closest = 9999999.0D;
|
||||
int l;
|
||||
|
||||
for( l = 0; l < list.size(); ++l )
|
||||
for( int l = 0; l < list.size(); ++l )
|
||||
{
|
||||
Entity entity1 = (Entity) list.get( l );
|
||||
|
||||
|
||||
Reference in New Issue
Block a user