Reduces visibility of internal fields/methods
Reduces the visibility of all fields to private and create setters/getters when necessary. Exceptions are fields with GuiSync as these need to be public. Reduces the visibility of internal methods to private/protected/default when possible.
This commit is contained in:
@@ -41,7 +41,7 @@ public abstract class AEBaseEntityItem extends EntityItem
|
||||
}
|
||||
|
||||
@SuppressWarnings( "unchecked" )
|
||||
public List<Entity> getCheckedEntitiesWithinAABBExcludingEntity( final AxisAlignedBB region )
|
||||
protected List<Entity> getCheckedEntitiesWithinAABBExcludingEntity( final AxisAlignedBB region )
|
||||
{
|
||||
return this.worldObj.getEntitiesWithinAABBExcludingEntity( this, region );
|
||||
}
|
||||
|
||||
@@ -43,8 +43,8 @@ import appeng.util.Platform;
|
||||
public final class EntityChargedQuartz extends AEBaseEntityItem
|
||||
{
|
||||
|
||||
int delay = 0;
|
||||
int transformTime = 0;
|
||||
private int delay = 0;
|
||||
private int transformTime = 0;
|
||||
|
||||
@Reflected
|
||||
public EntityChargedQuartz( final World w )
|
||||
@@ -96,7 +96,7 @@ public final class EntityChargedQuartz extends AEBaseEntityItem
|
||||
}
|
||||
}
|
||||
|
||||
public boolean transform()
|
||||
private boolean transform()
|
||||
{
|
||||
final ItemStack item = this.getEntityItem();
|
||||
final IMaterials materials = AEApi.instance().definitions().materials();
|
||||
|
||||
@@ -30,8 +30,8 @@ public final class EntityFloatingItem extends EntityItem
|
||||
|
||||
public static int ageStatic = 0;
|
||||
private final Entity parent;
|
||||
int superDeath = 0;
|
||||
float progress = 0;
|
||||
private int superDeath = 0;
|
||||
private float progress = 0;
|
||||
|
||||
public EntityFloatingItem( final Entity parent, final World world, final double x, final double y, final double z, final ItemStack stack )
|
||||
{
|
||||
@@ -69,4 +69,9 @@ public final class EntityFloatingItem extends EntityItem
|
||||
this.setDead();
|
||||
}
|
||||
}
|
||||
|
||||
float getProgress()
|
||||
{
|
||||
return this.progress;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -24,10 +24,10 @@ import net.minecraft.entity.Entity;
|
||||
|
||||
public final class EntityIds
|
||||
{
|
||||
public static final int TINY_TNT = 10;
|
||||
public static final int SINGULARITY = 11;
|
||||
public static final int CHARGED_QUARTZ = 12;
|
||||
public static final int GROWING_CRYSTAL = 13;
|
||||
private static final int TINY_TNT = 10;
|
||||
private static final int SINGULARITY = 11;
|
||||
private static final int CHARGED_QUARTZ = 12;
|
||||
private static final int GROWING_CRYSTAL = 13;
|
||||
|
||||
private EntityIds()
|
||||
{
|
||||
|
||||
@@ -67,7 +67,7 @@ public final class EntitySingularity extends AEBaseEntityItem
|
||||
return super.attackEntityFrom( src, dmg );
|
||||
}
|
||||
|
||||
public void doExplosion()
|
||||
private void doExplosion()
|
||||
{
|
||||
if( Platform.isClient() )
|
||||
{
|
||||
|
||||
@@ -19,9 +19,6 @@
|
||||
package appeng.entity;
|
||||
|
||||
|
||||
import java.nio.ByteBuffer;
|
||||
import java.nio.DoubleBuffer;
|
||||
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
import net.minecraft.client.renderer.entity.RenderItem;
|
||||
@@ -37,8 +34,6 @@ import cpw.mods.fml.relauncher.SideOnly;
|
||||
public class RenderFloatingItem extends RenderItem
|
||||
{
|
||||
|
||||
public static DoubleBuffer buffer = ByteBuffer.allocateDirect( 8 * 4 ).asDoubleBuffer();
|
||||
|
||||
public RenderFloatingItem()
|
||||
{
|
||||
this.shadowOpaque = 0.0F;
|
||||
@@ -51,7 +46,7 @@ public class RenderFloatingItem extends RenderItem
|
||||
if( entityItem instanceof EntityFloatingItem )
|
||||
{
|
||||
final EntityFloatingItem efi = (EntityFloatingItem) entityItem;
|
||||
if( efi.progress > 0.0 )
|
||||
if( efi.getProgress() > 0.0 )
|
||||
{
|
||||
GL11.glPushMatrix();
|
||||
|
||||
|
||||
@@ -51,7 +51,7 @@ public class RenderTinyTNTPrimed extends Render
|
||||
this.renderPrimedTNT( (EntityTinyTNTPrimed) tnt, x, y, z, life );
|
||||
}
|
||||
|
||||
public void renderPrimedTNT( final EntityTinyTNTPrimed tnt, final double x, final double y, final double z, final float life )
|
||||
private void renderPrimedTNT( final EntityTinyTNTPrimed tnt, final double x, final double y, final double z, final float life )
|
||||
{
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslatef( (float) x, (float) y - 0.25f, (float) z );
|
||||
|
||||
Reference in New Issue
Block a user