diff --git a/minecraft/net/minecraft/src/eui/robotics/EntityRobot.java b/minecraft/net/minecraft/src/eui/robotics/EntityRobot.java index e772d681..ba7c1df1 100644 --- a/minecraft/net/minecraft/src/eui/robotics/EntityRobot.java +++ b/minecraft/net/minecraft/src/eui/robotics/EntityRobot.java @@ -27,6 +27,7 @@ public class EntityRobot extends EntityCreature { @Override public int getMaxHealth() { // TODO Auto-generated method stub - return 0; + return 1; } + } diff --git a/minecraft/net/minecraft/src/pipes/api/ILiquidConsumer.java b/minecraft/net/minecraft/src/pipes/api/ILiquidConsumer.java new file mode 100644 index 00000000..0f74db8d --- /dev/null +++ b/minecraft/net/minecraft/src/pipes/api/ILiquidConsumer.java @@ -0,0 +1,33 @@ +package net.minecraft.src.eui.pipes.api; + + +public interface ILiquidConsumer +{ + /** + * onRecieveLiquid + * @param vol - The amount this block received. + * @param side - The side of the block in which the liquid came from. + * @parm type - The type of liquid being received + * @return vol - The amount liquid that can't be recieved + */ + public int onReceiveLiquid(int type, int vol, byte side); + + /** + * You can use this to check if a pipe can connect to this liquid consumer to properly render the graphics + * @param side - The side in which the electricity is coming from. + * @parm type - The type of liquid + * @return Returns true or false if this consumer can receive electricity at this given tick or moment. + */ + public boolean canRecieveLiquid(int type, byte side); + + /** + * @return Return the stored liquid of type in this consumer. + */ + public int getStoredLiquid(int type); + + /** + * @return Return the maximum amount of stored liquid this consumer can get. + */ + public int getLiquidCapacity(int type); + +} diff --git a/minecraft/net/minecraft/src/pipes/api/ILiquidProducer.java b/minecraft/net/minecraft/src/pipes/api/ILiquidProducer.java new file mode 100644 index 00000000..64873561 --- /dev/null +++ b/minecraft/net/minecraft/src/pipes/api/ILiquidProducer.java @@ -0,0 +1,28 @@ +package net.minecraft.src.eui.pipes.api; + +/** + * The UEIProducer interface is an interface that must be applied to all tile entities that can produce electricity. + * @author Calclavia + * + */ +public interface ILiquidProducer +{ + /** + * onProduceLiquid + * block. + * @param type - the type of liquid + * @param maxvol - The maximum vol or requested volume + * @param side - The side + * @return vol - Return a vol of liquid type that is produced + */ + public int onProduceLiquid(int type, int maxVol, int side); + /** + * canProduceLiquid + * block. + * @param type - the type of liquid + * @param side - The side + * @return boolean - True if can, false if can't produce liquid of type or on that side + * Also used for connection rules of pipes' + */ + public boolean canProduceLiquid(int type, byte side); +} \ No newline at end of file