Improved readability of variables

Hopefully improved semantics of variables

Fixed typos

Added hyphenations
This commit is contained in:
thatsIch
2014-09-28 11:47:17 +02:00
parent 6b60a0996b
commit 76b147fd5b
220 changed files with 1643 additions and 1662 deletions
@@ -58,7 +58,7 @@ import appeng.core.settings.TickRates;
import appeng.me.GridAccessException;
import appeng.me.helpers.AENetworkProxy;
import appeng.me.storage.MEMonitorIInventory;
import appeng.me.storage.MEMonitorPassthu;
import appeng.me.storage.MEMonitorPassThrough;
import appeng.me.storage.NullInventory;
import appeng.parts.automation.UpgradeInventory;
import appeng.tile.inventory.AppEngInternalAEInventory;
@@ -196,8 +196,8 @@ public class DualityInterface implements IGridTickable, ISegmentedInventory, ISt
}
}
public DualityInterface(AENetworkProxy prox, IInterfaceHost ih) {
gridProxy = prox;
public DualityInterface(AENetworkProxy networkProxy, IInterfaceHost ih) {
gridProxy = networkProxy;
gridProxy.setFlags( GridFlags.REQUIRE_CHANNEL );
upgrades = new UpgradeInventory( gridProxy.getMachineRepresentation(), this, 1 );
@@ -250,7 +250,7 @@ public class DualityInterface implements IGridTickable, ISegmentedInventory, ISt
}
}
notifyNeightbors();
notifyNeighbors();
}
public void writeToNBT(NBTTagCompound data)
@@ -513,8 +513,8 @@ public class DualityInterface implements IGridTickable, ISegmentedInventory, ISt
return patterns;
}
MEMonitorPassthu<IAEItemStack> items = new MEMonitorPassthu<IAEItemStack>( new NullInventory(), StorageChannel.ITEMS );
MEMonitorPassthu<IAEFluidStack> fluids = new MEMonitorPassthu<IAEFluidStack>( new NullInventory(), StorageChannel.FLUIDS );
MEMonitorPassThrough<IAEItemStack> items = new MEMonitorPassThrough<IAEItemStack>( new NullInventory(), StorageChannel.ITEMS );
MEMonitorPassThrough<IAEFluidStack> fluids = new MEMonitorPassThrough<IAEFluidStack>( new NullInventory(), StorageChannel.FLUIDS );
public void gridChanged()
{
@@ -529,7 +529,7 @@ public class DualityInterface implements IGridTickable, ISegmentedInventory, ISt
fluids.setInternal( new NullInventory() );
}
notifyNeightbors();
notifyNeighbors();
}
public AECableType getCableConnectionType(ForgeDirection dir)
@@ -936,7 +936,7 @@ public class DualityInterface implements IGridTickable, ISegmentedInventory, ISt
drops.add( is );
}
public void notifyNeightbors()
public void notifyNeighbors()
{
if ( gridProxy.isActive() )
{
@@ -3,11 +3,11 @@ package appeng.helpers;
public enum InventoryAction
{
// standard vanilla mechanics.
PICKUP_OR_SETDOWN, SPLIT_OR_PLACESINGLE, CREATIVE_DUPLICATE, SHIFT_CLICK,
PICKUP_OR_SET_DOWN, SPLIT_OR_PLACE_SINGLE, CREATIVE_DUPLICATE, SHIFT_CLICK,
// crafting term
CRAFT_STACK, CRAFT_ITEM, CRAFT_SHIFT,
// extra...
MOVE_REGION, PICKUP_SINGLE, UPDATE_HAND, ROLLUP, ROLLDOWN, AUTOCRAFT, PLACE_SINGLE
MOVE_REGION, PICKUP_SINGLE, UPDATE_HAND, ROLL_UP, ROLL_DOWN, AUTO_CRAFT, PLACE_SINGLE
}
@@ -30,7 +30,7 @@ public class MeteoritePlacer
private class Fallout
{
public int adjustCrator()
public int adjustCrater()
{
return 0;
}
@@ -111,7 +111,7 @@ public class MeteoritePlacer
super( w, x, y, z );
}
public int adjustCrator()
public int adjustCrater()
{
return 2;
}
@@ -131,7 +131,7 @@ public class MeteoritePlacer
super( w, x, y, z );
}
public int adjustCrator()
public int adjustCrater()
{
return 2;
}
@@ -381,10 +381,10 @@ public class MeteoritePlacer
Block skychest;
double real_sizeOfMeteorite = (Math.random() * 6.0) + 2;
double real_crator = real_sizeOfMeteorite * 2 + 5;
double realCrater = real_sizeOfMeteorite * 2 + 5;
double sizeOfMeteorite = real_sizeOfMeteorite * real_sizeOfMeteorite;
double crator = real_crator * real_crator;
double crater = realCrater * realCrater;
public MeteoritePlacer() {
@@ -431,9 +431,9 @@ public class MeteoritePlacer
int z = settings.getInteger( "z" );
real_sizeOfMeteorite = settings.getDouble( "real_sizeOfMeteorite" );
real_crator = settings.getDouble( "real_crator" );
realCrater = settings.getDouble( "realCrater" );
sizeOfMeteorite = settings.getDouble( "sizeOfMeteorite" );
crator = settings.getDouble( "crator" );
crater = settings.getDouble( "crater" );
Block blk = Block.getBlockById( settings.getInteger( "blk" ) );
@@ -448,7 +448,7 @@ public class MeteoritePlacer
// creator
if ( skyMode > 10 )
placeCrator( w, x, y, z );
placeCrater( w, x, y, z );
placeMeteorite( w, x, y, z );
@@ -486,9 +486,9 @@ public class MeteoritePlacer
settings.setInteger( "blk", Block.getIdFromBlock( blk ) );
settings.setDouble( "real_sizeOfMeteorite", real_sizeOfMeteorite );
settings.setDouble( "real_crator", real_crator );
settings.setDouble( "realCrater", realCrater );
settings.setDouble( "sizeOfMeteorite", sizeOfMeteorite );
settings.setDouble( "crator", crator );
settings.setDouble( "crater", crater );
settings.setBoolean( "lava", Math.random() > 0.9 );
@@ -547,7 +547,7 @@ public class MeteoritePlacer
// creator
if ( skyMode > 10 )
placeCrator( w, x, y, z );
placeCrater( w, x, y, z );
placeMeteorite( w, x, y, z );
@@ -564,7 +564,7 @@ public class MeteoritePlacer
return false;
}
private void placeCrator(IMeteoriteWorld w, int x, int y, int z)
private void placeCrater(IMeteoriteWorld w, int x, int y, int z)
{
boolean lava = settings.getBoolean( "lava" );
@@ -583,7 +583,7 @@ public class MeteoritePlacer
{
double dx = i - x;
double dz = k - z;
double h = y - real_sizeOfMeteorite + 1 + type.adjustCrator();
double h = y - real_sizeOfMeteorite + 1 + type.adjustCrater();
double distanceFrom = dx * dx + dz * dz;
@@ -610,15 +610,15 @@ public class MeteoritePlacer
private void placeMeteorite(IMeteoriteWorld w, int x, int y, int z)
{
int Xmeteor_l = w.minX( x - 8 );
int Xmeteor_h = w.maxX( x + 8 );
int Zmeteor_l = w.minZ( z - 8 );
int Zmeteor_h = w.maxZ( z + 8 );
int meteorXLength = w.minX( x - 8 );
int meteorXHeight = w.maxX( x + 8 );
int meteorZLength = w.minZ( z - 8 );
int meteorZHeight = w.maxZ( z + 8 );
// spawn metor
for (int i = Xmeteor_l; i < Xmeteor_h; i++)
// spawn meteor
for (int i = meteorXLength; i < meteorXHeight; i++)
for (int j = y - 8; j < y + 8; j++)
for (int k = Zmeteor_l; k < Zmeteor_h; k++)
for (int k = meteorZLength; k < meteorZHeight; k++)
{
double dx = i - x;
double dy = j - y;
@@ -724,13 +724,13 @@ public class MeteoritePlacer
{
double randomShit = 0;
int Xmeteor_l = w.minX( x - 30 );
int Xmeteor_h = w.maxX( x + 30 );
int Zmeteor_l = w.minZ( z - 30 );
int Zmeteor_h = w.maxZ( z + 30 );
int meteorXLength = w.minX( x - 30 );
int meteorXHeight = w.maxX( x + 30 );
int meteorZLength = w.minZ( z - 30 );
int meteorZHeight = w.maxZ( z + 30 );
for (int i = Xmeteor_l; i < Xmeteor_h; i++)
for (int k = Zmeteor_l; k < Zmeteor_h; k++)
for (int i = meteorXLength; i < meteorXHeight; i++)
for (int k = meteorZLength; k < meteorZHeight; k++)
for (int j = y - 9; j < y + 30; j++)
{
Block blk = w.getBlock( i, j, k );
@@ -749,7 +749,7 @@ public class MeteoritePlacer
w.setBlock( i, j, k, blk_b, meta_b, 3 );
w.setBlock( i, j + 1, k, blk );
}
else if ( randomShit < 100 * crator )
else if ( randomShit < 100 * crater )
{
double dx = i - x;
double dy = j - y;
@@ -759,8 +759,8 @@ public class MeteoritePlacer
Block xf = w.getBlock( i, j - 1, k );
if ( !xf.isReplaceable( w.getWorld(), i, j - 1, k ) )
{
double extrRange = Math.random() * 0.6;
double height = crator * (extrRange + 0.2) - Math.abs( dist - crator * 1.7 );
double extraRange = Math.random() * 0.6;
double height = crater * (extraRange + 0.2) - Math.abs( dist - crater * 1.7 );
if ( xf != blk && height > 0 && Math.random() > 0.6 )
{
@@ -782,7 +782,7 @@ public class MeteoritePlacer
double dy = j - y;
double dz = k - z;
if ( dx * dx + dy * dy + dz * dz < crator * 1.6 )
if ( dx * dx + dy * dy + dz * dz < crater * 1.6 )
{
type.getRandomInset( w, i, j, k );
}
@@ -62,19 +62,19 @@ public class MultiCraftingTracker
{
if ( ais != null && d.simulateAdd( ais.getItemStack() ) == null )
{
Future<ICraftingJob> cjob = getJob( x );
Future<ICraftingJob> craftingJob = getJob( x );
if ( getLink( x ) != null )
{
return false;
}
else if ( cjob != null )
else if ( craftingJob != null )
{
ICraftingJob job = null;
try
{
if ( cjob.isDone() )
job = cjob.get();
else if ( cjob.isCancelled() )
if ( craftingJob.isDone() )
job = craftingJob.get();
else if ( craftingJob.isCancelled() )
job = null;
if ( job != null )
@@ -25,7 +25,7 @@ public class PatternHelper implements ICraftingPatternDetails, Comparable<Patter
{
final ItemStack patternItem;
private IAEItemStack aepattern;
private IAEItemStack pattern;
final InventoryCrafting crafting = new InventoryCrafting( new ContainerNull(), 3, 3 );
final InventoryCrafting testFrame = new InventoryCrafting( new ContainerNull(), 3, 3 );
@@ -120,7 +120,7 @@ public class PatternHelper implements ICraftingPatternDetails, Comparable<Patter
NBTTagList outTag = encodedValue.getTagList( "out", 10 );
isCrafting = encodedValue.getBoolean( "crafting" );
patternItem = is;
aepattern = AEItemStack.create( is );
pattern = AEItemStack.create( is );
List<IAEItemStack> in = new ArrayList();
List<IAEItemStack> out = new ArrayList();
@@ -331,13 +331,13 @@ public class PatternHelper implements ICraftingPatternDetails, Comparable<Patter
@Override
public int hashCode()
{
return aepattern.hashCode();
return pattern.hashCode();
}
@Override
public boolean equals(Object obj)
{
return aepattern.equals( ((PatternHelper) obj).aepattern );
return pattern.equals( ((PatternHelper) obj).pattern );
}
@Override
@@ -5,10 +5,10 @@ import net.minecraft.util.Vec3;
import net.minecraftforge.common.util.ForgeDirection;
import appeng.api.util.AEColor;
public class Splot
public class Splotch
{
public Splot(AEColor col, boolean lit, ForgeDirection side, Vec3 Pos) {
public Splotch(AEColor col, boolean lit, ForgeDirection side, Vec3 Pos) {
color = col;
lumen = lit;
@@ -39,7 +39,7 @@ public class Splot
this.side = side;
}
public Splot(ByteBuf data) {
public Splotch(ByteBuf data) {
pos = data.readByte();
int val = data.readByte();