Formatted code
This commit is contained in:
@@ -80,7 +80,7 @@ public class TileCraftingStorageTile extends TileCraftingTile
|
||||
return 0;
|
||||
}
|
||||
|
||||
final BlockCraftingUnit unit = (BlockCraftingUnit)this.worldObj.getBlockState( this.pos ).getBlock();
|
||||
final BlockCraftingUnit unit = (BlockCraftingUnit) this.worldObj.getBlockState( this.pos ).getBlock();
|
||||
switch( unit.type )
|
||||
{
|
||||
default:
|
||||
|
||||
@@ -25,7 +25,7 @@ public enum TileEventType
|
||||
* Requires IUpdatePlayerListBox, this makes the tile entity tick in 1.8
|
||||
*/
|
||||
TICK,
|
||||
|
||||
|
||||
WORLD_NBT_READ, WORLD_NBT_WRITE,
|
||||
|
||||
/**
|
||||
|
||||
@@ -164,7 +164,7 @@ public class TileCrank extends AEBaseTile implements ICustomCollision, IUpdatePl
|
||||
final double zOff = -0.15 * this.getUp().getFrontOffsetZ();
|
||||
return Collections.singletonList( AxisAlignedBB.fromBounds( xOff + 0.15, yOff + 0.15, zOff + 0.15, xOff + 0.85, yOff + 0.85, zOff + 0.85 ) );
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void addCollidingBlockToList(
|
||||
final World w,
|
||||
|
||||
@@ -277,14 +277,14 @@ public class AppEngInternalAEInventory implements IInventory, Iterable<ItemStack
|
||||
public void openInventory(
|
||||
final EntityPlayer player )
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void closeInventory(
|
||||
final EntityPlayer player )
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -299,7 +299,7 @@ public class AppEngInternalAEInventory implements IInventory, Iterable<ItemStack
|
||||
final int id,
|
||||
final int value )
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -113,14 +113,14 @@ public class AppEngNullInventory implements IInventory
|
||||
public void openInventory(
|
||||
final EntityPlayer player )
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void closeInventory(
|
||||
final EntityPlayer player )
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -135,7 +135,7 @@ public class AppEngNullInventory implements IInventory
|
||||
final int id,
|
||||
final int value )
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -147,6 +147,6 @@ public class AppEngNullInventory implements IInventory
|
||||
@Override
|
||||
public void clear()
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -96,7 +96,7 @@ public class TileCellWorkbench extends AEBaseTile implements IUpgradeableHost, I
|
||||
|
||||
if( this.cell.getStackInSlot( 0 ).getItem() instanceof ICellWorkbenchItem )
|
||||
{
|
||||
return ( (ICellWorkbenchItem) this.cell.getStackInSlot( 0 ).getItem() );
|
||||
return( (ICellWorkbenchItem) this.cell.getStackInSlot( 0 ).getItem() );
|
||||
}
|
||||
|
||||
return null;
|
||||
|
||||
@@ -57,7 +57,7 @@ public class TilePaint extends AEBaseTile
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@TileEvent( TileEventType.WORLD_NBT_WRITE )
|
||||
public void writeToNBT_TilePaint( final NBTTagCompound data )
|
||||
{
|
||||
@@ -234,8 +234,8 @@ public class TilePaint extends AEBaseTile
|
||||
public void addBlot( final ItemStack type, final EnumFacing side, final Vec3 hitVec )
|
||||
{
|
||||
final BlockPos p = this.pos.offset( side );
|
||||
|
||||
final IBlockState blk = this.worldObj.getBlockState( p );
|
||||
|
||||
final IBlockState blk = this.worldObj.getBlockState( p );
|
||||
if( blk.getBlock().isSideSolid( this.worldObj, p, side.getOpposite() ) )
|
||||
{
|
||||
final ItemPaintBall ipb = (ItemPaintBall) type.getItem();
|
||||
|
||||
@@ -113,7 +113,7 @@ public class TileSecurity extends AENetworkTile implements ITerminalHost, IAEApp
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void getDrops(
|
||||
final World w,
|
||||
|
||||
@@ -289,7 +289,7 @@ public class TileVibrationChamber extends AENetworkInvTile implements IGridTicka
|
||||
this.isOn = this.getBurnTime() > 0;
|
||||
this.markForUpdate();
|
||||
|
||||
if ( this.hasWorldObj() )
|
||||
if( this.hasWorldObj() )
|
||||
{
|
||||
Platform.notifyBlocksOfNeighbors( this.worldObj, this.pos );
|
||||
}
|
||||
|
||||
@@ -122,4 +122,4 @@ package appeng.tile.powersink;
|
||||
// this.removeFromENet();
|
||||
// this.addToENet();
|
||||
// }
|
||||
//}
|
||||
// }
|
||||
|
||||
@@ -62,4 +62,4 @@ package appeng.tile.powersink;
|
||||
// {
|
||||
// return this.getPowerSides().contains( from );
|
||||
// }
|
||||
//}
|
||||
// }
|
||||
|
||||
@@ -182,4 +182,4 @@ package appeng.tile.powersink;
|
||||
// messages.add( out );
|
||||
// return messages;
|
||||
// }
|
||||
//}
|
||||
// }
|
||||
|
||||
@@ -18,66 +18,57 @@
|
||||
|
||||
package appeng.tile.powersink;
|
||||
|
||||
|
||||
/*
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
import universalelectricity.core.block.IElectrical;
|
||||
import universalelectricity.core.electricity.ElectricityPack;
|
||||
import appeng.api.config.PowerUnits;
|
||||
|
||||
public abstract class UniversalElectricity extends ThermalExpansion implements IElectrical
|
||||
{
|
||||
|
||||
@Override
|
||||
public final boolean canConnect(AEPartLocation direction)
|
||||
{
|
||||
return internalCanAcceptPower && getPowerSides().contains( direction );
|
||||
}
|
||||
|
||||
@Override
|
||||
public final float receiveElectricity(AEPartLocation from, ElectricityPack receive, boolean doReceive)
|
||||
{
|
||||
float accepted = 0;
|
||||
double receivedPower = receive.getWatts();
|
||||
|
||||
if ( doReceive )
|
||||
{
|
||||
accepted = (float) (receivedPower - injectExternalPower( PowerUnits.KJ, receivedPower ));
|
||||
}
|
||||
else
|
||||
{
|
||||
double whatIWant = getExternalPowerDemand( PowerUnits.KJ );
|
||||
if ( whatIWant > receivedPower )
|
||||
accepted = (float) receivedPower;
|
||||
else
|
||||
accepted = (float) whatIWant;
|
||||
}
|
||||
|
||||
return accepted;
|
||||
}
|
||||
|
||||
@Override
|
||||
public final float getRequest(AEPartLocation direction)
|
||||
{
|
||||
return (float) getExternalPowerDemand( PowerUnits.KJ );
|
||||
}
|
||||
|
||||
@Override
|
||||
public final float getVoltage()
|
||||
{
|
||||
return 120;
|
||||
}
|
||||
|
||||
@Override
|
||||
public final ElectricityPack provideElectricity(AEPartLocation from, ElectricityPack request, boolean doProvide)
|
||||
{
|
||||
return null; // cannot be dis-charged
|
||||
}
|
||||
|
||||
@Override
|
||||
public final float getProvide(AEPartLocation direction)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
}
|
||||
*/
|
||||
* import net.minecraftforge.common.util.ForgeDirection;
|
||||
* import universalelectricity.core.block.IElectrical;
|
||||
* import universalelectricity.core.electricity.ElectricityPack;
|
||||
* import appeng.api.config.PowerUnits;
|
||||
* public abstract class UniversalElectricity extends ThermalExpansion implements IElectrical
|
||||
* {
|
||||
* @Override
|
||||
* public final boolean canConnect(AEPartLocation direction)
|
||||
* {
|
||||
* return internalCanAcceptPower && getPowerSides().contains( direction );
|
||||
* }
|
||||
* @Override
|
||||
* public final float receiveElectricity(AEPartLocation from, ElectricityPack receive, boolean doReceive)
|
||||
* {
|
||||
* float accepted = 0;
|
||||
* double receivedPower = receive.getWatts();
|
||||
* if ( doReceive )
|
||||
* {
|
||||
* accepted = (float) (receivedPower - injectExternalPower( PowerUnits.KJ, receivedPower ));
|
||||
* }
|
||||
* else
|
||||
* {
|
||||
* double whatIWant = getExternalPowerDemand( PowerUnits.KJ );
|
||||
* if ( whatIWant > receivedPower )
|
||||
* accepted = (float) receivedPower;
|
||||
* else
|
||||
* accepted = (float) whatIWant;
|
||||
* }
|
||||
* return accepted;
|
||||
* }
|
||||
* @Override
|
||||
* public final float getRequest(AEPartLocation direction)
|
||||
* {
|
||||
* return (float) getExternalPowerDemand( PowerUnits.KJ );
|
||||
* }
|
||||
* @Override
|
||||
* public final float getVoltage()
|
||||
* {
|
||||
* return 120;
|
||||
* }
|
||||
* @Override
|
||||
* public final ElectricityPack provideElectricity(AEPartLocation from, ElectricityPack request, boolean doProvide)
|
||||
* {
|
||||
* return null; // cannot be dis-charged
|
||||
* }
|
||||
* @Override
|
||||
* public final float getProvide(AEPartLocation direction)
|
||||
* {
|
||||
* return 0;
|
||||
* }
|
||||
* }
|
||||
*/
|
||||
Reference in New Issue
Block a user