Package logisticspipes.pipes

Examples of logisticspipes.pipes.PipeItemsRemoteOrdererLogistics.useEnergy()


    if(pipe != null) {
      if(MainProxy.isServer(par3EntityPlayer.worldObj)) {
        int energyUse = 0;
        if(pipe.getWorld() != par3EntityPlayer.worldObj) energyUse += 2500;
        energyUse += Math.sqrt(Math.pow(pipe.getX() - par3EntityPlayer.posX, 2) + Math.pow(pipe.getY() - par3EntityPlayer.posY, 2) + Math.pow(pipe.getZ() - par3EntityPlayer.posZ, 2));
        if(pipe.useEnergy(energyUse)) {
          MainProxy.sendPacketToPlayer(PacketHandler.getPacket(RequestPipeDimension.class).setInteger(MainProxy.getDimensionForWorld(pipe.getWorld())), par3EntityPlayer);
          par3EntityPlayer.openGui(LogisticsPipes.instance, GuiIDs.GUI_Normal_Orderer_ID, pipe.getWorld(), pipe.getX(), pipe.getY(), pipe.getZ());
         
        }
      }
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.