Beispiel #1
0
 @Override
 @Method(modid = "appliedenergistics2")
 public AECableType getCableConnectionType(ForgeDirection dir) {
   IMEConduit cond = getConduit(IMEConduit.class);
   if (cond == null) {
     return AECableType.NONE;
   } else {
     return cond.isConnectedTo(dir) ? AECableType.SMART : AECableType.NONE;
   }
 }
Beispiel #2
0
 @Override
 @Method(modid = "appliedenergistics2")
 public IGridNode getGridNode(ForgeDirection dir) {
   if (dir == null || dir == ForgeDirection.UNKNOWN) {
     return (IGridNode) node;
   } else {
     IMEConduit cond = getConduit(IMEConduit.class);
     if (cond != null) {
       if (cond.getConnectionMode(dir.getOpposite()) == ConnectionMode.IN_OUT) {
         return (IGridNode) node;
       } else {
         return null;
       }
     }
   }
   return (IGridNode) node;
 }