Examples of preConditions()


Examples of buildcraft.api.power.IPowerProvider.preConditions()

        continue;
      }
     
      IPowerReceptor ipr = ((IPowerReceptor)te);
      IPowerProvider pp = ipr.getPowerProvider();
      if(pp != null && pp.preConditions(ipr) && pp.getMinEnergyReceived() <= mj)
      {
        int mjUsed = Math.min(Math.min(pp.getMaxEnergyReceived(), mj), pp.getMaxEnergyStored() - (int)Math.floor(pp.getEnergyStored()));
        pp.receiveEnergy(mjUsed, bp.orientation);
       
        mj -= mjUsed;
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.