diff --git a/src/common/assemblyline/AssemblyLine.java b/src/common/assemblyline/AssemblyLine.java index ee959bc4..fc20bc53 100644 --- a/src/common/assemblyline/AssemblyLine.java +++ b/src/common/assemblyline/AssemblyLine.java @@ -73,7 +73,7 @@ public class AssemblyLine public void load(FMLInitializationEvent evt) { proxy.init(); - + GameRegistry.registerTileEntity(TileEntityConveyorBelt.class, "ConveyorBelt"); GameRegistry.registerTileEntity(TileEntityRejector.class, "Sorter"); GameRegistry.registerTileEntity(TileEntityManipulator.class, "Manipulator"); @@ -98,7 +98,7 @@ public class AssemblyLine // Retriever GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(blockInteraction, 1, MachineType.MANIPULATOR.metadata), new Object[] { Block.dispenser, "basicCircuit" })); - + UETab.setItemStack(new ItemStack(blockConveyorBelt)); } } \ No newline at end of file diff --git a/src/common/assemblyline/ai/Task.java b/src/common/assemblyline/ai/Task.java index ed972d86..9ea554f4 100644 --- a/src/common/assemblyline/ai/Task.java +++ b/src/common/assemblyline/ai/Task.java @@ -1,11 +1,9 @@ package assemblyline.ai; -import net.minecraft.src.TileEntity; import assemblyline.machines.crafter.TileEntityCraftingArm; /** - * An AI Task that is used by TileEntities with - * AI. + * An AI Task that is used by TileEntities with AI. * * @author Calclavia * @@ -14,18 +12,18 @@ public abstract class Task { protected int ticks; protected TileEntityCraftingArm tileEntity; + public Task(TileEntityCraftingArm arm) { - this.tileEntity = arm; + this.tileEntity = arm; } + /** * Called when a task is being done. * * @param ticks - * The amount of ticks this task - * has been elapsed for. - * @return Return true if the task is not - * finished and false if it is. + * The amount of ticks this task has been elapsed for. + * @return Return true if the task is not finished and false if it is. */ protected boolean doTask() { @@ -43,8 +41,7 @@ public abstract class Task } /** - * @return The tick interval of this task. - * Return 0 for no ticks. + * @return The tick interval of this task. Return 0 for no ticks. */ public int getTickInterval() { diff --git a/src/common/assemblyline/ai/TaskIdle.java b/src/common/assemblyline/ai/TaskIdle.java index a52000bd..da12f162 100644 --- a/src/common/assemblyline/ai/TaskIdle.java +++ b/src/common/assemblyline/ai/TaskIdle.java @@ -1,23 +1,21 @@ package assemblyline.ai; import assemblyline.machines.crafter.TileEntityCraftingArm; -import net.minecraft.src.TileEntity; public class TaskIdle extends Task { public TaskIdle(TileEntityCraftingArm arm) - { - super(arm); - } + { + super(arm); + } + protected boolean doTask() - { - /** - * randomly move the arm to - * similate life in the arm - * if the arm is powered - */ - return true; - + { + /** + * randomly move the arm to similate life in the arm if the arm is powered + */ + return true; + } } diff --git a/src/common/assemblyline/api/IBelt.java b/src/common/assemblyline/api/IBelt.java index 9c63f80d..9f9b7567 100644 --- a/src/common/assemblyline/api/IBelt.java +++ b/src/common/assemblyline/api/IBelt.java @@ -8,19 +8,16 @@ import net.minecraftforge.common.ForgeDirection; public interface IBelt { /** - * Gets the facing direction of the belt, used - * but other machines to know which direction - * to start an item at + * Gets the facing direction of the belt, used but other machines to know which direction to + * start an item at * * @return */ public ForgeDirection getFacing(); /** - * Causes the belt to ignore the entity for a - * few updates help in cases where another - * machine need to effect this entity without - * the belt doing so as well. + * Causes the belt to ignore the entity for a few updates help in cases where another machine + * need to effect this entity without the belt doing so as well. * * @param entity * - entity being ignored @@ -28,8 +25,7 @@ public interface IBelt public void ignoreEntity(Entity entity); /** - * Used to get a list of entities above this - * belt + * Used to get a list of entities above this belt * * @return list of entities */ diff --git a/src/common/assemblyline/api/IManipulator.java b/src/common/assemblyline/api/IManipulator.java index 7cb4b163..8233738b 100644 --- a/src/common/assemblyline/api/IManipulator.java +++ b/src/common/assemblyline/api/IManipulator.java @@ -6,8 +6,7 @@ import universalelectricity.core.vector.Vector3; public interface IManipulator { /** - * Throws the items from the manipulator into - * the world + * Throws the items from the manipulator into the world * * @param outputPosition * @param items diff --git a/src/common/assemblyline/machine/BlockArchitectTable.java b/src/common/assemblyline/machine/BlockArchitectTable.java index 0ce5fce3..6c5a19bc 100644 --- a/src/common/assemblyline/machine/BlockArchitectTable.java +++ b/src/common/assemblyline/machine/BlockArchitectTable.java @@ -17,8 +17,7 @@ public class BlockArchitectTable extends Block } /** - * Returns the block texture based on the side - * being looked at. Args: side + * Returns the block texture based on the side being looked at. Args: side */ public int getBlockTextureFromSide(int par1) { @@ -26,8 +25,7 @@ public class BlockArchitectTable extends Block } /** - * Called upon block activation (right click - * on the block.) + * Called upon block activation (right click on the block.) */ public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer, int par6, float par7, float par8, float par9) { diff --git a/src/common/assemblyline/machine/BlockMulti.java b/src/common/assemblyline/machine/BlockMulti.java index 4ce62bbd..7077f12b 100644 --- a/src/common/assemblyline/machine/BlockMulti.java +++ b/src/common/assemblyline/machine/BlockMulti.java @@ -19,8 +19,7 @@ import assemblyline.render.RenderHelper; import cpw.mods.fml.common.network.PacketDispatcher; /** - * A metadata block containing a bunch of machines - * with direction. + * A metadata block containing a bunch of machines with direction. * * @author Darkguardsman, Calclavia * @@ -55,8 +54,7 @@ public class BlockMulti extends BlockMachine } /** - * Gets the direction based on the - * metadata + * Gets the direction based on the metadata * * @return A direction value from 0 to 4. */ @@ -68,8 +66,7 @@ public class BlockMulti extends BlockMachine /** * @param currentDirection * - An integer from 0 to 4. - * @return The metadata this block should - * change into. + * @return The metadata this block should change into. */ public int getNextDirectionMeta(int currentDirection) { @@ -199,8 +196,7 @@ public class BlockMulti extends BlockMachine } /** - * Returns the bounding box of the wired - * rectangular prism to render. + * Returns the bounding box of the wired rectangular prism to render. */ @Override public AxisAlignedBB getSelectedBoundingBoxFromPool(World par1World, int x, int y, int z) @@ -209,10 +205,8 @@ public class BlockMulti extends BlockMachine } /** - * Returns a bounding box from the pool of - * bounding boxes (this means this box can - * change after the pool has been cleared to - * be reused) + * Returns a bounding box from the pool of bounding boxes (this means this box can change after + * the pool has been cleared to be reused) */ @Override public AxisAlignedBB getCollisionBoundingBoxFromPool(World par1World, int x, int y, int z) diff --git a/src/common/assemblyline/machine/ContainerSorter.java b/src/common/assemblyline/machine/ContainerSorter.java index 6b2d936c..1175c63d 100644 --- a/src/common/assemblyline/machine/ContainerSorter.java +++ b/src/common/assemblyline/machine/ContainerSorter.java @@ -41,9 +41,7 @@ public class ContainerSorter extends Container } /** - * Called to transfer a stack from one - * inventory to the other eg. when shift - * clicking. + * Called to transfer a stack from one inventory to the other eg. when shift clicking. */ @Override public ItemStack transferStackInSlot(EntityPlayer par1EntityPlayer, int par1) diff --git a/src/common/assemblyline/machine/TileEntityManipulator.java b/src/common/assemblyline/machine/TileEntityManipulator.java index fdd5d050..a189b730 100644 --- a/src/common/assemblyline/machine/TileEntityManipulator.java +++ b/src/common/assemblyline/machine/TileEntityManipulator.java @@ -40,8 +40,7 @@ public class TileEntityManipulator extends TileEntityElectricityReceiver impleme public double wattsReceived = 0; /** - * Is the manipulator wrenched to turn into - * output mode? + * Is the manipulator wrenched to turn into output mode? */ public boolean isOutput = false; @@ -65,9 +64,7 @@ public class TileEntityManipulator extends TileEntityElectricityReceiver impleme if (!this.isOutput) { /** - * Find items going into the - * manipulator and input them - * into an inventory behind + * Find items going into the manipulator and input them into an inventory behind * this manipulator. */ Vector3 inputPosition = Vector3.get(this); @@ -87,11 +84,8 @@ public class TileEntityManipulator extends TileEntityElectricityReceiver impleme for (EntityItem entity : itemsInBound) { /** - * Try top first, then - * bottom, then the sides - * to see if it is - * possible to insert the - * item into a inventory. + * Try top first, then bottom, then the sides to see if it is possible to + * insert the item into a inventory. */ ItemStack remainingStack = this.tryPlaceInPosition(entity.item.copy(), outputUp, ForgeDirection.DOWN); @@ -116,10 +110,7 @@ public class TileEntityManipulator extends TileEntityElectricityReceiver impleme else { /** - * Finds the connected - * inventory and outputs the - * items upon a redstone - * pulse. + * Finds the connected inventory and outputs the items upon a redstone pulse. */ if (this.isPowered) { @@ -165,8 +156,7 @@ public class TileEntityManipulator extends TileEntityElectricityReceiver impleme } /** - * Throws the items from the manipulator into - * the world. + * Throws the items from the manipulator into the world. * * @param outputPosition * @param items @@ -181,11 +171,9 @@ public class TileEntityManipulator extends TileEntityElectricityReceiver impleme } /** - * Tries to place an itemStack in a specific - * position if it is an inventory. + * Tries to place an itemStack in a specific position if it is an inventory. * - * @return The ItemStack remained after place - * attempt + * @return The ItemStack remained after place attempt */ private ItemStack tryPlaceInPosition(ItemStack itemStack, Vector3 position, ForgeDirection direction) { @@ -286,8 +274,7 @@ public class TileEntityManipulator extends TileEntityElectricityReceiver impleme } /** - * Tries to take a item from a inventory at a - * specific position. + * Tries to take a item from a inventory at a specific position. * * @param position * @return diff --git a/src/common/assemblyline/machine/TileEntityRejector.java b/src/common/assemblyline/machine/TileEntityRejector.java index 87efbd34..dd2bf0fe 100644 --- a/src/common/assemblyline/machine/TileEntityRejector.java +++ b/src/common/assemblyline/machine/TileEntityRejector.java @@ -72,8 +72,7 @@ public class TileEntityRejector extends TileEntityElectricityReceiver implements super.updateEntity(); /** - * Has to update a bit faster than a - * conveyer belt + * Has to update a bit faster than a conveyer belt */ if (this.ticks % 5 == 0 && !this.isDisabled()) { @@ -225,10 +224,8 @@ public class TileEntityRejector extends TileEntityElectricityReceiver implements } /** - * Used to change any one of the boolean value - * of on/off array After changing the value if - * it was changed client side it will send a - * packet server side with the changes + * Used to change any one of the boolean value of on/off array After changing the value if it + * was changed client side it will send a packet server side with the changes * * @param i */ diff --git a/src/common/assemblyline/machine/TileEntityRoboticSorter.java b/src/common/assemblyline/machine/TileEntityRoboticSorter.java index 7d53cfa8..cacabac9 100644 --- a/src/common/assemblyline/machine/TileEntityRoboticSorter.java +++ b/src/common/assemblyline/machine/TileEntityRoboticSorter.java @@ -7,7 +7,6 @@ import net.minecraft.src.ItemStack; import net.minecraft.src.NBTTagCompound; import net.minecraft.src.NBTTagList; import net.minecraft.src.Packet250CustomPayload; -import net.minecraft.src.TileEntity; import net.minecraftforge.common.ForgeDirection; import universalelectricity.prefab.network.IPacketReceiver; import universalelectricity.prefab.tile.TileEntityElectricityReceiver; diff --git a/src/common/assemblyline/machine/belt/TileEntityConveyorBelt.java b/src/common/assemblyline/machine/belt/TileEntityConveyorBelt.java index dbbcddbe..9a26475a 100644 --- a/src/common/assemblyline/machine/belt/TileEntityConveyorBelt.java +++ b/src/common/assemblyline/machine/belt/TileEntityConveyorBelt.java @@ -133,8 +133,7 @@ public class TileEntityConveyorBelt extends TileEntityElectricityReceiver implem } /** - * almost unneeded but is change for each - * different belt type + * almost unneeded but is change for each different belt type */ public void doBeltAction() { @@ -147,8 +146,7 @@ public class TileEntityConveyorBelt extends TileEntityElectricityReceiver implem * @param extendLife * - increases the items life * @param preventPickUp - * - prevent a player from picking - * the item up + * - prevent a player from picking the item up */ public void conveyItemsHorizontal(boolean extendLife, boolean preventPickUp) { @@ -159,6 +157,7 @@ public class TileEntityConveyorBelt extends TileEntityElectricityReceiver implem for (Entity entity : entityOnTop) { int direction = worldObj.getBlockMetadata(xCoord, yCoord, zCoord); + if (!this.entityIgnoreList.contains(entity)) { if (!(entity instanceof EntityPlayer && ((EntityPlayer) entity).isSneaking())) @@ -185,6 +184,7 @@ public class TileEntityConveyorBelt extends TileEntityElectricityReceiver implem } } } + if (this.clearCount++ >= 4) { // clear the temp ignore diff --git a/src/common/assemblyline/machine/belt/TileEntityCoveredBelt.java b/src/common/assemblyline/machine/belt/TileEntityCoveredBelt.java index 2c9ce86d..6ecfe26e 100644 --- a/src/common/assemblyline/machine/belt/TileEntityCoveredBelt.java +++ b/src/common/assemblyline/machine/belt/TileEntityCoveredBelt.java @@ -1,9 +1,8 @@ package assemblyline.machine.belt; /** - * For the moment this is just a render place - * holder, but will be convered to prevent item - * pickups from the belts. + * For the moment this is just a render place holder, but will be convered to prevent item pickups + * from the belts. * * @author Rseifert * diff --git a/src/common/assemblyline/machine/belt/TileEntityElevatorBelt.java b/src/common/assemblyline/machine/belt/TileEntityElevatorBelt.java index 12fbdaa1..7c68f0b8 100644 --- a/src/common/assemblyline/machine/belt/TileEntityElevatorBelt.java +++ b/src/common/assemblyline/machine/belt/TileEntityElevatorBelt.java @@ -20,8 +20,7 @@ public class TileEntityElevatorBelt extends TileEntityConveyorBelt } /** - * Used to detect belt bellow for rendering - * and to prevent items from falling + * Used to detect belt bellow for rendering and to prevent items from falling * * @return */ @@ -33,8 +32,7 @@ public class TileEntityElevatorBelt extends TileEntityConveyorBelt } /** - * Same as conveyItemHorizontal but will pull, - * or lower the items up/down the belt like an + * Same as conveyItemHorizontal but will pull, or lower the items up/down the belt like an * elevator * * @param extendLife diff --git a/src/common/assemblyline/machines/crafter/BlockCrafter.java b/src/common/assemblyline/machines/crafter/BlockCrafter.java index 38f5753a..ae437c12 100644 --- a/src/common/assemblyline/machines/crafter/BlockCrafter.java +++ b/src/common/assemblyline/machines/crafter/BlockCrafter.java @@ -46,8 +46,7 @@ public class BlockCrafter extends BlockMachine } /** - * Gets the direction based on the - * metadata + * Gets the direction based on the metadata * * @return A direction value from 0 to 4. */ @@ -59,8 +58,7 @@ public class BlockCrafter extends BlockMachine /** * @param currentDirection * - An integer from 0 to 4. - * @return The metadata this block should - * change into. + * @return The metadata this block should change into. */ public int getNextDirectionMeta(int currentDirection) { diff --git a/src/common/assemblyline/machines/crafter/ContainerCrafter.java b/src/common/assemblyline/machines/crafter/ContainerCrafter.java index f959d544..3f855378 100644 --- a/src/common/assemblyline/machines/crafter/ContainerCrafter.java +++ b/src/common/assemblyline/machines/crafter/ContainerCrafter.java @@ -8,8 +8,7 @@ import net.minecraft.src.ItemStack; import net.minecraft.src.Slot; /** - * I am planning to make the crafter not use a - * GUI. + * I am planning to make the crafter not use a GUI. * * @author Calclavia * @@ -54,9 +53,7 @@ public class ContainerCrafter extends Container } /** - * Called to transfer a stack from one - * inventory to the other eg. when shift - * clicking. + * Called to transfer a stack from one inventory to the other eg. when shift clicking. */ @Override public ItemStack transferStackInSlot(EntityPlayer par1EntityPlayer, int par1) diff --git a/src/common/assemblyline/machines/crafter/TaskArmCollect.java b/src/common/assemblyline/machines/crafter/TaskArmCollect.java index 1c7f5509..83fdd22f 100644 --- a/src/common/assemblyline/machines/crafter/TaskArmCollect.java +++ b/src/common/assemblyline/machines/crafter/TaskArmCollect.java @@ -1,28 +1,25 @@ package assemblyline.machines.crafter; import net.minecraft.src.EntityItem; -import net.minecraft.src.TileEntity; import assemblyline.ai.Task; /** - * Used by arms to collect items in a specific - * region. + * Used by arms to collect items in a specific region. * * @author Calclavia */ public class TaskArmCollect extends Task { - /** * The item to be collected. */ private EntityItem entityItem; - public TaskArmCollect(TileEntityCraftingArm arm,EntityItem entityItem) + public TaskArmCollect(TileEntityCraftingArm arm, EntityItem entityItem) { - super(arm); - this.entityItem = entityItem; + super(arm); + this.entityItem = entityItem; } @Override @@ -33,8 +30,7 @@ public class TaskArmCollect extends Task if (entityItem == null) { return false; } /** - * Slowly stretch down the arm's model and - * grab the item + * Slowly stretch down the arm's model and grab the item */ return true; diff --git a/src/common/assemblyline/machines/crafter/TaskArmSearch.java b/src/common/assemblyline/machines/crafter/TaskArmSearch.java index a3489b7b..11c303eb 100644 --- a/src/common/assemblyline/machines/crafter/TaskArmSearch.java +++ b/src/common/assemblyline/machines/crafter/TaskArmSearch.java @@ -2,8 +2,6 @@ package assemblyline.machines.crafter; import net.minecraft.src.AxisAlignedBB; import net.minecraft.src.Entity; -import net.minecraft.src.TileEntity; -import net.minecraft.src.World; import assemblyline.ai.Task; /** @@ -25,9 +23,9 @@ public class TaskArmSearch extends Task private Entity foundEntity; - public TaskArmSearch(TileEntityCraftingArm arm,Class entityToInclude, double radius, float searchSpeed) + public TaskArmSearch(TileEntityCraftingArm arm, Class entityToInclude, double radius, float searchSpeed) { - super(arm); + super(arm); this.entityToInclude = entityToInclude; this.radius = radius; this.searchSpeed = searchSpeed; @@ -47,9 +45,7 @@ public class TaskArmSearch extends Task if (this.entityToInclude == null || this.foundEntity == null) { return false; } /** - * Move the robotic arm around and emulate - * an item search. Then initiate a collect - * task. + * Move the robotic arm around and emulate an item search. Then initiate a collect task. */ return true; diff --git a/src/common/assemblyline/machines/crafter/TileEntityCraftingArm.java b/src/common/assemblyline/machines/crafter/TileEntityCraftingArm.java index 6e361d3c..a8e17cf0 100644 --- a/src/common/assemblyline/machines/crafter/TileEntityCraftingArm.java +++ b/src/common/assemblyline/machines/crafter/TileEntityCraftingArm.java @@ -7,7 +7,6 @@ import net.minecraft.src.ItemStack; import net.minecraft.src.NBTTagCompound; import net.minecraft.src.NBTTagList; import net.minecraft.src.Packet250CustomPayload; -import net.minecraft.src.TileEntity; import net.minecraftforge.common.ForgeDirection; import universalelectricity.prefab.network.IPacketReceiver; import universalelectricity.prefab.tile.TileEntityElectricityReceiver; @@ -25,8 +24,7 @@ public class TileEntityCraftingArm extends TileEntityElectricityReceiver impleme private TaskManager taskManager = new TaskManager(); /** - * Entity robotic arm to be used with this - * tileEntity + * Entity robotic arm to be used with this tileEntity */ public EntityCraftingArm EntityArm = null; @@ -56,8 +54,7 @@ public class TileEntityCraftingArm extends TileEntityElectricityReceiver impleme } /** - * controls the robotic arm into doing a set - * task + * controls the robotic arm into doing a set task */ public void doWork() { @@ -258,5 +255,4 @@ public class TileEntityCraftingArm extends TileEntityElectricityReceiver impleme nbt.setTag("Items", var2); } - } diff --git a/src/minecraft/assemblyline/gui/GuiAutoCrafting.java b/src/minecraft/assemblyline/gui/GuiAutoCrafting.java index 33e6f031..98232267 100644 --- a/src/minecraft/assemblyline/gui/GuiAutoCrafting.java +++ b/src/minecraft/assemblyline/gui/GuiAutoCrafting.java @@ -28,9 +28,7 @@ public class GuiAutoCrafting extends GuiContainer } /** - * Draw the foreground layer for the - * GuiContainer (everything in front of the - * items) + * Draw the foreground layer for the GuiContainer (everything in front of the items) */ protected void drawGuiContainerForegroundLayer() { @@ -39,8 +37,7 @@ public class GuiAutoCrafting extends GuiContainer } /** - * Draw the background layer for the - * GuiContainer (everything behind the items) + * Draw the background layer for the GuiContainer (everything behind the items) */ protected void drawGuiContainerBackgroundLayer(float par1, int par2, int par3) { diff --git a/src/minecraft/assemblyline/gui/GuiButtonImage.java b/src/minecraft/assemblyline/gui/GuiButtonImage.java index 17e800e1..7854433a 100644 --- a/src/minecraft/assemblyline/gui/GuiButtonImage.java +++ b/src/minecraft/assemblyline/gui/GuiButtonImage.java @@ -9,8 +9,7 @@ import cpw.mods.fml.common.Side; import cpw.mods.fml.common.asm.SideOnly; /** - * Copied from GSM lib and modified for this mod - * only + * Copied from GSM lib and modified for this mod only * * @author Rseifert * diff --git a/src/minecraft/assemblyline/gui/GuiSorter.java b/src/minecraft/assemblyline/gui/GuiSorter.java index 93df35cc..17924b72 100644 --- a/src/minecraft/assemblyline/gui/GuiSorter.java +++ b/src/minecraft/assemblyline/gui/GuiSorter.java @@ -45,10 +45,8 @@ public class GuiSorter extends GuiContainer } /** - * Fired when a control is clicked. This is - * the equivalent of - * ActionListener.actionPerformed(ActionEvent - * e). + * Fired when a control is clicked. This is the equivalent of + * ActionListener.actionPerformed(ActionEvent e). */ protected void actionPerformed(GuiButton button) { @@ -75,9 +73,7 @@ public class GuiSorter extends GuiContainer } /** - * Draw the foreground layer for the - * GuiContainer (everything in front of the - * items) + * Draw the foreground layer for the GuiContainer (everything in front of the items) */ @Override protected void drawGuiContainerForegroundLayer(int par1, int par2) @@ -88,8 +84,7 @@ public class GuiSorter extends GuiContainer } /** - * Draw the background layer for the - * GuiContainer (everything behind the items) + * Draw the background layer for the GuiContainer (everything behind the items) */ @Override protected void drawGuiContainerBackgroundLayer(float par1, int par2, int par3)