Auto-Sync
This commit is contained in:
parent
bab12f761d
commit
a127f663ff
43 changed files with 57 additions and 137 deletions
|
@ -3,7 +3,7 @@ package dark.api.al;
|
|||
import net.minecraft.item.ItemStack;
|
||||
|
||||
/** Applied to TileEntities that can accept a filter.z
|
||||
*
|
||||
*
|
||||
* @author Calclavia */
|
||||
public interface IFilterable
|
||||
{
|
||||
|
|
|
@ -1,11 +1,10 @@
|
|||
package dark.api.al;
|
||||
|
||||
import universalelectricity.core.vector.Vector2;
|
||||
/**
|
||||
* Class used in the creation of servo based object
|
||||
* @author Rseifert
|
||||
*
|
||||
*/
|
||||
|
||||
/** Class used in the creation of servo based object
|
||||
*
|
||||
* @author Rseifert */
|
||||
public interface IServo
|
||||
{
|
||||
/** Gets the rotation as a Vector2 (X - Yaw, Y - pitch) */
|
||||
|
|
|
@ -2,9 +2,8 @@ package dark.api.al;
|
|||
|
||||
import java.util.HashMap;
|
||||
|
||||
|
||||
/** Container like class to handle several servos in an object.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IServoHandler
|
||||
{
|
||||
|
@ -13,7 +12,7 @@ public interface IServoHandler
|
|||
public HashMap<String, IServo> getServos();
|
||||
|
||||
/** Ask the handler to rotation the servo.
|
||||
*
|
||||
*
|
||||
* @return true if the handler will rotate the servo */
|
||||
public boolean updateRotation(String servo, float rotation);
|
||||
|
||||
|
|
|
@ -1,7 +1,5 @@
|
|||
package dark.api.al.coding;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import universalelectricity.core.vector.Vector2;
|
||||
|
||||
|
@ -18,24 +16,24 @@ public interface IArmbot extends Cloneable, IProgrammableMachine
|
|||
public void setRotation(float yaw, float pitch);
|
||||
|
||||
/** Ask the armbot to rotate to face the given direction. Some bots may not support all angles
|
||||
*
|
||||
*
|
||||
* @return true if the bot will comply. May return false if it can't */
|
||||
public boolean moveArmTo(float yaw, float pitch);
|
||||
|
||||
/** Ask the armbot to rotate to face the given direction. Some bots may not support up and down
|
||||
*
|
||||
*
|
||||
* @param direction - direction
|
||||
* @return true if the bot will comply. May return false if it can't */
|
||||
public boolean moveTo(ForgeDirection direction);
|
||||
|
||||
/** Adds an entity to the Armbot's grab list. Entity or ItemStack
|
||||
*
|
||||
*
|
||||
* @entity - object to grab, can be anything though is suggest to be an entity or itemstack
|
||||
* @return - true if the bot has grabbed the object */
|
||||
public boolean grab(Object entity);
|
||||
|
||||
/** Drops an object. Does except strings with "All" resulting in dropping everything.
|
||||
*
|
||||
*
|
||||
* @entity - can be anything though entity and itemstack are the main supported types
|
||||
* @return - true if the bot dropped the item */
|
||||
public boolean drop(Object object);
|
||||
|
|
|
@ -2,19 +2,18 @@ package dark.api.al.coding;
|
|||
|
||||
import java.util.HashMap;
|
||||
|
||||
|
||||
/** The IUseable inteface is used by the ArmBot so that it may interact with Tile Entities. onUse
|
||||
* will be called on the block an ArmBot is touching whenever the USE command is run on it.
|
||||
*
|
||||
*
|
||||
* @author Briman0094 */
|
||||
public interface IArmbotUseable
|
||||
{
|
||||
|
||||
/** Called when the ArmBot command "USE" is run. This is called on any IUseable the ArmBot is
|
||||
* touching.
|
||||
*
|
||||
*
|
||||
* @param armbot - The Armbot instance.
|
||||
*
|
||||
*
|
||||
* @return true if the use was completed correctly */
|
||||
public boolean onUse(IArmbot armbot, HashMap<String, Object> hashMap);
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@ package dark.api.al.coding;
|
|||
import net.minecraft.nbt.NBTTagCompound;
|
||||
|
||||
/** Used to ID that an item can support saving data to it NBT
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IDataItem
|
||||
{
|
||||
|
|
|
@ -4,7 +4,7 @@ package dark.api.al.coding;
|
|||
* the entry point, and exit points. As well handle anything in between. Examples are IF statements
|
||||
* and loops. Do your logic in the refresh method as it should be called each time a new task is
|
||||
* selected.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface ILogicTask extends ITask
|
||||
{
|
||||
|
|
|
@ -5,7 +5,7 @@ import java.util.HashMap;
|
|||
/** Used by task to tell the program it needs to remember a value outside the task. Should only be
|
||||
* used by task that really need to save values beyond there local values. Cases were this is used
|
||||
* should be is loops, items counts, and run conditions.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IMemorySlot
|
||||
{
|
||||
|
@ -22,6 +22,6 @@ public interface IMemorySlot
|
|||
/** Any memory location that needs to be saved to the machines hard disk. Should only do this for
|
||||
* information that must be saved. Treat this as real world memory to hard drive saving. As well
|
||||
* if the machine is running between world saves its active memory will be save. However, if it
|
||||
* turns off its active memory will clear. Called as the task is terminated. */
|
||||
* turns off its active memory will clear. Called as the task is terminated. */
|
||||
public HashMap<String, Object> getSavedData();
|
||||
}
|
||||
|
|
|
@ -1,24 +1,15 @@
|
|||
package dark.api.al.coding;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
import universalelectricity.core.vector.Vector2;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.world.World;
|
||||
import dan200.computer.api.IComputerAccess;
|
||||
import dan200.computer.api.ILuaContext;
|
||||
import dark.api.al.coding.args.ArgumentData;
|
||||
|
||||
/** Use to construct a basic task that can be used in any device that supports this interface.
|
||||
*
|
||||
*
|
||||
* @Note - there are several methods that look a like. GetArgs is used to get the programs arguments
|
||||
* that were set by the encoder. GetEncoderParms should be a constant set of arguments that the
|
||||
* device can support. GetMemory is a list of variables that the program needs to store outside of
|
||||
* the task. That way it can save values after the task has been refreshed or even deleted.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IProcessTask extends ITask
|
||||
{
|
||||
|
@ -28,7 +19,7 @@ public interface IProcessTask extends ITask
|
|||
|
||||
/** Called when the task is being run by the devices program manager. Used mainly to setup the
|
||||
* task before actually doing the task.
|
||||
*
|
||||
*
|
||||
* @param world - current world
|
||||
* @param location - current location
|
||||
* @param armbot - armbot instance
|
||||
|
|
|
@ -8,7 +8,7 @@ import universalelectricity.core.vector.Vector2;
|
|||
/** Flow chart style program. Each command in the program needs to have a stored location so it can
|
||||
* be saved and loaded with its correct connections. Though the location only need to be a simple
|
||||
* Column and row based system.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IProgram extends Cloneable
|
||||
{
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package dark.api.al.coding;
|
||||
|
||||
/** IDs that an item can load/save a program
|
||||
*
|
||||
*
|
||||
* @author Darkguardsman */
|
||||
public interface IProgramItem
|
||||
{
|
||||
|
|
|
@ -1,13 +1,12 @@
|
|||
package dark.api.al.coding;
|
||||
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
|
||||
import com.builtbroken.common.Pair;
|
||||
|
||||
/** Simple interface too say an object is programmable
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IProgrammableMachine
|
||||
{
|
||||
|
@ -18,7 +17,7 @@ public interface IProgrammableMachine
|
|||
public void setCurrentProgram(IProgram program);
|
||||
|
||||
/** Gets the machine location as a pair containing both the world and xyz vector.
|
||||
*
|
||||
*
|
||||
* @return try to avoid returning null as every object but a fake one has a location */
|
||||
public Pair<World, Vector3> getLocation();
|
||||
}
|
||||
|
|
|
@ -3,7 +3,7 @@ package dark.api.al.coding;
|
|||
/** Used to tell the program that this task is used to tell the program were to go next. Used by
|
||||
* things like LOOP, IF, and GOTO statement's end catches. Not actually used by the statement itself
|
||||
* other than to help control the flow of the program
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IRedirectTask extends ILogicTask
|
||||
{
|
||||
|
|
|
@ -3,11 +3,10 @@ package dark.api.al.coding;
|
|||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
import dark.api.al.coding.args.ArgumentData;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.vector.Vector2;
|
||||
import dark.api.al.coding.args.ArgumentData;
|
||||
|
||||
/** @author DarkGuardsman */
|
||||
public interface ITask extends Cloneable
|
||||
|
|
|
@ -2,17 +2,15 @@ package dark.api.al.coding;
|
|||
|
||||
import java.util.HashMap;
|
||||
|
||||
import dark.api.al.coding.IProcessTask.ProcessReturn;
|
||||
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
import dark.api.al.coding.IProcessTask.ProcessReturn;
|
||||
|
||||
/** Basic class to handle a machine like programs for any object that uses the IProgramable
|
||||
* interface. Doesn't actually do much then tell the program to function, and stores the programs
|
||||
* active run time memory.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class ProgramHelper
|
||||
{
|
||||
|
@ -35,7 +33,7 @@ public class ProgramHelper
|
|||
}
|
||||
|
||||
/** Needs to be called by the armbot per tick.
|
||||
*
|
||||
*
|
||||
* @return true if it is doing something */
|
||||
public ProcessReturn onUpdate(World world, Vector3 botLocation)
|
||||
{
|
||||
|
|
|
@ -2,18 +2,16 @@ package dark.api.al.coding;
|
|||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.HashSet;
|
||||
import java.util.List;
|
||||
import java.util.Map.Entry;
|
||||
import java.util.Set;
|
||||
|
||||
/** Used to both register task and fake machines for the encoder to use to create new programs.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class TaskRegistry
|
||||
{
|
||||
/** A class of all available commands.
|
||||
*
|
||||
*
|
||||
* String - Command name. Command - The actual command class. */
|
||||
private static final HashMap<String, IProcessTask> COMMANDS = new HashMap();
|
||||
|
||||
|
@ -74,7 +72,7 @@ public class TaskRegistry
|
|||
}
|
||||
|
||||
/** Do not edit the return or you will change the behavior of all machine that use this list
|
||||
*
|
||||
*
|
||||
* @return The list of registered sudo machines for the encoder to check against */
|
||||
public static HashMap<String, IArmbot> getSudoMachines()
|
||||
{
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package dark.api.al.coding.args;
|
||||
|
||||
/** Used to store arguments in a way that can be easier to read, limit, and understand
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class ArgumentData
|
||||
{
|
||||
|
@ -15,7 +15,7 @@ public class ArgumentData
|
|||
}
|
||||
|
||||
/** Sets the value
|
||||
*
|
||||
*
|
||||
* @return true if the value was accepted */
|
||||
public boolean setData(Object object)
|
||||
{
|
||||
|
|
|
@ -2,7 +2,7 @@ package dark.api.al.coding.args;
|
|||
|
||||
/** Used to create argument data for the encoder. Should only be used if the value needs to be
|
||||
* clearly limited inside the encoder display.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class ArgumentDoubleData extends ArgumentData
|
||||
{
|
||||
|
|
|
@ -2,7 +2,7 @@ package dark.api.al.coding.args;
|
|||
|
||||
import net.minecraft.entity.Entity;
|
||||
|
||||
public class ArgumentEntityList extends ArgumentListData<Class< ? extends Entity>>
|
||||
public class ArgumentEntityList extends ArgumentListData<Class<? extends Entity>>
|
||||
{
|
||||
|
||||
public ArgumentEntityList(String name, Object defaultvalue, Class<? extends Entity>... object)
|
||||
|
|
|
@ -2,7 +2,7 @@ package dark.api.al.coding.args;
|
|||
|
||||
/** Used to create argument data for the encoder. Should only be used if the value needs to be
|
||||
* clearly limited inside the encoder display.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class ArgumentFloatData extends ArgumentData
|
||||
{
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
package dark.api.al.coding.args;
|
||||
|
||||
/** Used to create argument data for the encoder. Should only be used if the value needs to be clearly
|
||||
* limited inside the encoder display.
|
||||
*
|
||||
/** Used to create argument data for the encoder. Should only be used if the value needs to be
|
||||
* clearly limited inside the encoder display.
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class ArgumentIntData extends ArgumentData
|
||||
{
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package dark.api.al.coding.args;
|
||||
|
||||
/** Used to store lists of data that the user can scroll threw to select one.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class ArgumentListData<O> extends ArgumentData
|
||||
{
|
||||
|
|
|
@ -54,7 +54,7 @@ public class RenderArmbot extends TileEntitySpecialRenderer
|
|||
GL11.glTranslatef((float) x + 0.5F, (float) y + 1.5F, (float) z + 0.5F);
|
||||
GL11.glScalef(1.0F, -1F, -1F);
|
||||
|
||||
MODEL.render(0.0625f, (float)((TileEntityArmbot) tileEntity).getRotation().x, (float)((TileEntityArmbot) tileEntity).getRotation().y);
|
||||
MODEL.render(0.0625f, (float) ((TileEntityArmbot) tileEntity).getRotation().x, (float) ((TileEntityArmbot) tileEntity).getRotation().y);
|
||||
|
||||
GL11.glPopMatrix();
|
||||
|
||||
|
|
|
@ -4,21 +4,6 @@ import java.util.ArrayList;
|
|||
import java.util.List;
|
||||
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.item.EntityBoat;
|
||||
import net.minecraft.entity.item.EntityItem;
|
||||
import net.minecraft.entity.item.EntityMinecart;
|
||||
import net.minecraft.entity.monster.EntityCreeper;
|
||||
import net.minecraft.entity.monster.EntityMob;
|
||||
import net.minecraft.entity.monster.EntitySkeleton;
|
||||
import net.minecraft.entity.monster.EntitySlime;
|
||||
import net.minecraft.entity.monster.EntitySpider;
|
||||
import net.minecraft.entity.monster.EntityZombie;
|
||||
import net.minecraft.entity.passive.EntityAnimal;
|
||||
import net.minecraft.entity.passive.EntityChicken;
|
||||
import net.minecraft.entity.passive.EntityCow;
|
||||
import net.minecraft.entity.passive.EntityPig;
|
||||
import net.minecraft.entity.passive.EntitySheep;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
|
||||
public class GrabDictionary
|
||||
{
|
||||
|
@ -66,7 +51,7 @@ public class GrabDictionary
|
|||
}
|
||||
|
||||
/** gets the name of the Entity
|
||||
*
|
||||
*
|
||||
* @return "" if null */
|
||||
public String getName()
|
||||
{
|
||||
|
@ -78,7 +63,7 @@ public class GrabDictionary
|
|||
}
|
||||
|
||||
/** gets the Entity Class
|
||||
*
|
||||
*
|
||||
* @return Entity.class if null */
|
||||
public Class<? extends Entity> getEntityClass()
|
||||
{
|
||||
|
@ -107,5 +92,4 @@ public class GrabDictionary
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -161,7 +161,7 @@ public class Program implements IProgram
|
|||
}
|
||||
|
||||
/** Move all tasks at the row and in the direction given.
|
||||
*
|
||||
*
|
||||
* @param row - row number or Y value of the position from the task
|
||||
* @param up - true will move all the tasks up one, false will move all the tasks down one */
|
||||
public void moveAll(int row, boolean up)
|
||||
|
|
|
@ -6,9 +6,7 @@ import java.util.List;
|
|||
import java.util.Map.Entry;
|
||||
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.vector.Vector2;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
import dark.api.al.coding.IMemorySlot;
|
||||
import dark.api.al.coding.IProgram;
|
||||
import dark.api.al.coding.IProgrammableMachine;
|
||||
|
|
|
@ -1,28 +1,12 @@
|
|||
package dark.assembly.common.armbot;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map.Entry;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.vector.Vector2;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
|
||||
import com.builtbroken.common.science.units.UnitHelper;
|
||||
|
||||
import dan200.computer.api.IComputerAccess;
|
||||
import dan200.computer.api.ILuaContext;
|
||||
import dark.api.al.coding.IArmbot;
|
||||
import dark.api.al.coding.IProcessTask;
|
||||
import dark.api.al.coding.IMemorySlot;
|
||||
import dark.api.al.coding.IProgram;
|
||||
import dark.api.al.coding.IProgrammableMachine;
|
||||
import dark.api.al.coding.IProcessTask.ProcessReturn;
|
||||
import dark.api.al.coding.args.ArgumentData;
|
||||
import dark.core.prefab.helpers.NBTFileHelper;
|
||||
|
||||
/** Basic command prefab used by machines like an armbot. You are not required to use this in order
|
||||
* to make armbot commands but it does help. Delete this if you don't plan to use it. */
|
||||
|
|
|
@ -2,15 +2,15 @@ package dark.assembly.common.armbot.command;
|
|||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import com.builtbroken.common.Pair;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.item.EntityItem;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
|
||||
import com.builtbroken.common.Pair;
|
||||
|
||||
import dark.api.al.coding.IArmbot;
|
||||
import dark.api.al.coding.ITask;
|
||||
import dark.assembly.common.armbot.TaskBaseArmbot;
|
||||
|
@ -18,7 +18,7 @@ import dark.assembly.common.armbot.TaskBaseProcess;
|
|||
import dark.core.prefab.helpers.ItemWorldHelper;
|
||||
|
||||
/** Used by arms to break a specific block in a position.
|
||||
*
|
||||
*
|
||||
* @author Calclavia */
|
||||
public class TaskBreak extends TaskBaseArmbot
|
||||
{
|
||||
|
|
|
@ -15,7 +15,6 @@ import com.builtbroken.common.Pair;
|
|||
import com.builtbroken.common.science.units.UnitHelper;
|
||||
|
||||
import dark.api.al.coding.IArmbot;
|
||||
import dark.api.al.coding.IProgrammableMachine;
|
||||
import dark.api.al.coding.args.ArgumentFloatData;
|
||||
import dark.assembly.common.armbot.TaskBaseArmbot;
|
||||
import dark.assembly.common.armbot.TaskBaseProcess;
|
||||
|
|
|
@ -7,7 +7,6 @@ import net.minecraft.block.Block;
|
|||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
|
||||
|
|
|
@ -8,10 +8,7 @@ import net.minecraft.entity.player.EntityPlayer;
|
|||
import net.minecraft.entity.projectile.EntityArrow;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
import dark.api.al.coding.IArmbot;
|
||||
import dark.api.al.coding.IProgrammableMachine;
|
||||
import dark.api.al.coding.args.ArgumentData;
|
||||
import dark.api.al.coding.args.ArgumentListData;
|
||||
import dark.assembly.common.armbot.GrabDictionary;
|
||||
|
|
|
@ -6,13 +6,10 @@ import net.minecraft.block.Block;
|
|||
import net.minecraft.entity.item.EntityItem;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.AxisAlignedBB;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
|
||||
import com.builtbroken.common.science.units.UnitHelper;
|
||||
|
||||
import dark.api.al.coding.IArmbot;
|
||||
import dark.api.al.coding.IProgrammableMachine;
|
||||
import dark.api.al.coding.args.ArgumentIntData;
|
||||
import dark.assembly.common.armbot.TaskBaseProcess;
|
||||
|
||||
|
|
|
@ -1,16 +1,14 @@
|
|||
package dark.assembly.common.armbot.command;
|
||||
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
import dark.api.al.IBelt;
|
||||
import dark.api.al.coding.IArmbot;
|
||||
import dark.api.al.coding.IProgrammableMachine;
|
||||
import dark.assembly.common.armbot.TaskBaseArmbot;
|
||||
|
||||
/** Prefab for grab based commands
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public abstract class TaskGrabPrefab extends TaskBaseArmbot
|
||||
{
|
||||
|
|
|
@ -1,8 +1,7 @@
|
|||
package dark.assembly.common.armbot.command;
|
||||
|
||||
|
||||
/** Used by arms to break a specific block in a position.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class TaskHarvest extends TaskBreak
|
||||
{
|
||||
|
|
|
@ -2,13 +2,10 @@ package dark.assembly.common.armbot.command;
|
|||
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import universalelectricity.core.vector.Vector2;
|
||||
import dark.api.al.coding.ILogicTask;
|
||||
import dark.api.al.coding.IProcessTask;
|
||||
import dark.api.al.coding.IProgrammableMachine;
|
||||
import dark.api.al.coding.ITask;
|
||||
import dark.api.al.coding.args.ArgumentData;
|
||||
import dark.assembly.common.armbot.TaskBaseLogic;
|
||||
import dark.assembly.common.armbot.TaskBaseProcess;
|
||||
|
||||
/** @author DarkGuardsman */
|
||||
public class TaskIF extends TaskBaseLogic
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
package dark.assembly.common.armbot.command;
|
||||
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
|
||||
import com.builtbroken.common.science.units.UnitHelper;
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@ import dark.assembly.common.armbot.TaskBaseArmbot;
|
|||
import dark.assembly.common.armbot.TaskBaseProcess;
|
||||
|
||||
/** Used by arms to break a specific block in a position.
|
||||
*
|
||||
*
|
||||
* @author Calclavia */
|
||||
public class TaskPlace extends TaskBaseArmbot
|
||||
{
|
||||
|
|
|
@ -1,20 +1,17 @@
|
|||
package dark.assembly.common.armbot.command;
|
||||
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
|
||||
import com.builtbroken.common.science.units.UnitHelper;
|
||||
|
||||
import dark.api.al.coding.IArmbot;
|
||||
import dark.api.al.coding.IProgrammableMachine;
|
||||
import dark.api.al.coding.args.ArgumentIntData;
|
||||
import dark.assembly.common.armbot.TaskBaseArmbot;
|
||||
import dark.assembly.common.armbot.TaskBaseProcess;
|
||||
import dark.core.prefab.helpers.MathHelper;
|
||||
|
||||
/** Rotates an armbot by a set amount
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class TaskRotateBy extends TaskBaseArmbot
|
||||
{
|
||||
|
|
|
@ -1,20 +1,17 @@
|
|||
package dark.assembly.common.armbot.command;
|
||||
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
|
||||
import com.builtbroken.common.science.units.UnitHelper;
|
||||
|
||||
import dark.api.al.coding.IArmbot;
|
||||
import dark.api.al.coding.IProgrammableMachine;
|
||||
import dark.api.al.coding.args.ArgumentIntData;
|
||||
import dark.assembly.common.armbot.TaskBaseArmbot;
|
||||
import dark.assembly.common.armbot.TaskBaseProcess;
|
||||
import dark.core.prefab.helpers.MathHelper;
|
||||
|
||||
/** Rotates the armbot to a specific direction. If not specified, it will turn right.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class TaskRotateTo extends TaskBaseArmbot
|
||||
{
|
||||
|
|
|
@ -7,14 +7,12 @@ import net.minecraft.block.Block;
|
|||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
|
||||
import com.builtbroken.common.science.units.UnitHelper;
|
||||
|
||||
import dark.api.al.coding.IArmbot;
|
||||
import dark.api.al.coding.IProgrammableMachine;
|
||||
import dark.api.al.coding.args.ArgumentIntData;
|
||||
import dark.assembly.common.armbot.TaskBaseArmbot;
|
||||
import dark.assembly.common.armbot.TaskBaseProcess;
|
||||
|
|
|
@ -3,15 +3,12 @@ package dark.assembly.common.armbot.command;
|
|||
import net.minecraft.block.Block;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
|
||||
import com.builtbroken.common.science.units.UnitHelper;
|
||||
|
||||
import dark.api.al.coding.IArmbot;
|
||||
import dark.api.al.coding.IArmbotUseable;
|
||||
import dark.api.al.coding.IProcessTask;
|
||||
import dark.api.al.coding.IProgrammableMachine;
|
||||
import dark.api.al.coding.args.ArgumentIntData;
|
||||
import dark.assembly.common.armbot.TaskBaseArmbot;
|
||||
import dark.assembly.common.armbot.TaskBaseProcess;
|
||||
|
|
|
@ -191,7 +191,7 @@ public class TileEntityImprinter extends TileEntityAdvanced implements ISidedInv
|
|||
}
|
||||
|
||||
/** Construct an InventoryCrafting Matrix on the fly.
|
||||
*
|
||||
*
|
||||
* @return */
|
||||
public InventoryCrafting getCraftingMatrix()
|
||||
{
|
||||
|
|
|
@ -141,6 +141,7 @@ public class TileEntityEncoder extends TileEntityMachine implements ISidedInvent
|
|||
}
|
||||
|
||||
/** Sends a gui packet only to the given player */
|
||||
@Override
|
||||
public void sendGUIPacket(EntityPlayer entity)
|
||||
{
|
||||
if (entity != null)
|
||||
|
|
Loading…
Reference in a new issue