OSDN Git Service

修正・変更
[chemicraft/chemicraft.git] / common / pcc / chemicraft / tileentity / TileEntityElectrolysisTable.java
index a8850af..49e3dc8 100644 (file)
@@ -1,5 +1,8 @@
 package pcc.chemicraft.tileentity;
 
+import ic2.api.Direction;
+import ic2.api.energy.tile.IEnergySink;
+
 import java.io.DataOutputStream;
 import java.util.HashMap;
 import java.util.Iterator;
@@ -19,7 +22,7 @@ import pcc.chemicraft.system.PacketHandler;
 
 import com.google.common.io.ByteArrayDataInput;
 
-public class TileEntityElectrolysisTable extends TileEntity
+public class TileEntityElectrolysisTable extends TileEntity implements IEnergySink
 {
 
        private InventoryElectrolysisMaterial invm = new InventoryElectrolysisMaterial();
@@ -446,4 +449,34 @@ public class TileEntityElectrolysisTable extends TileEntity
                recipeList.put(material, result);
        }
 
+       @Override
+       public boolean acceptsEnergyFrom(TileEntity emitter, Direction direction)
+       {
+               return true;
+       }
+
+       @Override
+       public boolean isAddedToEnergyNet()
+       {
+               return true;
+       }
+
+       @Override
+       public int demandsEnergy()
+       {
+               return 0;
+       }
+
+       @Override
+       public int injectEnergy(Direction directionFrom, int amount)
+       {
+               return 0;
+       }
+
+       @Override
+       public int getMaxSafeInput()
+       {
+               return 32;
+       }
+
 }