Examples of IPipeInformationProvider


Examples of logisticspipes.routing.pathfinder.IPipeInformationProvider

    return checkPipesConnections(from, to, way, false);
  }
 
  public static boolean checkPipesConnections(TileEntity from, TileEntity to, ForgeDirection way, boolean ignoreSystemDisconnection) {
    if(from == null || to == null) return false;
    IPipeInformationProvider fromInfo = SimpleServiceLocator.pipeInformaitonManager.getInformationProviderFor(from);
    IPipeInformationProvider toInfo = SimpleServiceLocator.pipeInformaitonManager.getInformationProviderFor(to);
    if(fromInfo == null && toInfo == null) return false;
    if(fromInfo != null) {
      if(!fromInfo.canConnect(to, way, ignoreSystemDisconnection)) return false;
    }
    if(toInfo != null) {
      if(!toInfo.canConnect(from, way.getOpposite(), ignoreSystemDisconnection)) return false;
    }
    return true;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.